FactoryBean threw exception on object creation; nested exception is java.lang.IllegalArgumentException: can't parse argument number: interface com.google.code.morphia.annotations.Id=@com.google.code.morphia.annotations.Id():
java.lang.IllegalArgumentException: can't parse argument number: interface com.google.code.morphia.annotations.Id=@com.google.code.morphia.annotations.Id()
at java.text.MessageFormat.makeFormat(MessageFormat.java:1356)
at java.text.MessageFormat.applyPattern(MessageFormat.java:475)
at java.text.MessageFormat.<init>(MessageFormat.java:367)
at java.text.MessageFormat.format(MessageFormat.java:828)
at org.slf4j.bridge.SLF4JBridgeHandler.getMessageI18N(SLF4JBridgeHandler.java:233)
at org.slf4j.bridge.SLF4JBridgeHandler.callLocationAwareLogger(SLF4JBridgeHandler.java:191)
at org.slf4j.bridge.SLF4JBridgeHandler.publish(SLF4JBridgeHandler.java:267)
at java.util.logging.Logger.log(Logger.java:498)
at java.util.logging.Logger.doLog(Logger.java:520)
at java.util.logging.Logger.logp(Logger.java:689)
at com.google.code.morphia.logging.jdk.JDKLogger.log(JDKLogger.java:107)
at com.google.code.morphia.logging.jdk.JDKLogger.debug(JDKLogger.java:38)
at com.google.code.morphia.mapping.MappedClass.<init>(MappedClass.java:113)
at com.google.code.morphia.mapping.Mapper.addMappedClass(Mapper.java:141)
at com.google.code.morphia.Morphia.map(Morphia.java:55)
at com.google.code.morphia.Morphia$map.call(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
at com.bakersoftware.providerIntegrator.domain.DbFactoryBean.getObject(DbFactoryBean.groovy:22)
Comment 1 by br

@nesbot.com, Nov 26, 2011
I saw
this error occur as well. I am using Scala but the same error occured at the same location. I see you have included the slf4j library in your classpath.
Did you take a look at http:
//code.google.com/p/morphia/wiki/SLF4JExtension ?
You need to include the extension in your classpath and then ensure you call the following code at start-up to register the logger extension and the error disappears. You can put it in a
static {} block
if you prefer.