Issue with deploying a Singleton in Payara

I have a jar with a class annotaded like this:

@Startup
@Singleton
public class MessageStore {
.
.
.
}

I get an error :

022-11-16T09:04:55.852+0100] [#Payara #5.#36.0] [INFO] [org.glassfish.admingui] [tid: _ThreadID=1836 _ThreadName=admin-thread-pool::admin-listener(5)] [timeMillis: 1668585895852] [levelValue: 800] [[
Exception Occurred :Error occurred during deployment: Exception while deploying the app [MessageAnalyzer-1.0-SNAPSHOT] : Invalid ejb jar [MessageAnalyzer-1.0-SNAPSHOT]: it contains zero ejb.
Note:

  1. A valid ejb jar requires at least one session, entity (1.x/2.x style), or message-driven bean.
  2. EJB3+ entity beans (@Entity) are POJOs and please package them as library jar.
  3. If the jar file contains valid EJBs which are annotated with EJB component level annotations (@Stateless, @Stateful, @MessageDriven, @Singleton), please check server.log to see whether the annotations were processed properly… Please see server.log for more details.]]

What am I missing?

Please not that the above log message is the very last in server.log, so there are no more details.

Some thoughts about it:

  1. Are you importing the right „javax/jakarta.ejb.Singleton?
  2. Do you have a valid beans.xml in your module?