The way you create messages is correct, though you could just use
printMessage(kind, msg, element);
if you don't want to display messages on annotations or annotation values. When overriding the processor's init
method, make sure to call super.init(processingEnv)
so it is set up correctly.
It sounds like the processor fails due some error in the execution. The processor will fail silently if there is an uncatched exception and then it won't display any messages. To debug an annotation processor activate the error log view:
Show View > Error Log">
In this view you should see every message by the messager as well as any uncatched exceptions thrown by the processor. The stack trace should help you to locate the error.