T
tmaus
hi there .. im running into a strange problem while deploying an
entity bean ..
these are my xdoclet tags:
* @ejb.finder
* query = "SELECT object(o) FROM User o WHERE o.login=?1 AND
o.password=?2"
* signature = "com.ikatomi.im.user.ejb.UserLocal
findByUsernameAndPassword(java.lang.String login,java.lang.String
password)"
*
* @jboss.query
* query = "SELECT object(o) FROM User o WHERE o.login=?1 AND
o.password=?2"
* signature = "com.ikatomi.im.user.ejb.UserLocal
findByUsernameAndPassword(java.lang.String login,java.lang.String
password)"
*/
and this is the error jboss is throwing ..
17:35:48,147 ERROR [EntityContainer] Starting failed
jboss.j2ee:jndiName=UserLocal,service=EJB
org.jboss.deployment.DeploymentException: Query method not found:
findByUsernameAndPassword(java.lang.String,java.lang.String)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCQueryMetaDataFactory.getQueryMethods(JDBCQueryMetaDataFactory.java:322)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCQueryMetaDataFactory.getQueryMethods(JDBCQueryMetaDataFactory.java:243)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCQueryMetaDataFactory.createJDBCQueryMetaData(JDBCQueryMetaDataFactory.java:65)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCEntityMetaData.<init>(JDBCEntityMetaData.java:862)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCApplicationMetaData.<init>(JDBCApplicationMetaData.java:363)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCXmlFileLoader.load(JDBCXmlFileLoader.java:75)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.loadJDBCEntityMetaData(JDBCStoreManager.java:705)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.initStoreManager(JDBCStoreManager.java:417)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.start(JDBCStoreManager.java:365)
at org.jboss.ejb.plugins.CMPPersistenceManager.start(CMPPersistenceManager.java:147)
at org.jboss.ejb.EntityContainer.startService(EntityContainer.java:337)
at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:271)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:221)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
i have to add that i can use the findByPrimaryKey method without any
probems which means that i made a mistake in my finder method ...
but i dont know why it throws a NullPointerException
greetings from berlin
entity bean ..
these are my xdoclet tags:
* @ejb.finder
* query = "SELECT object(o) FROM User o WHERE o.login=?1 AND
o.password=?2"
* signature = "com.ikatomi.im.user.ejb.UserLocal
findByUsernameAndPassword(java.lang.String login,java.lang.String
password)"
*
* @jboss.query
* query = "SELECT object(o) FROM User o WHERE o.login=?1 AND
o.password=?2"
* signature = "com.ikatomi.im.user.ejb.UserLocal
findByUsernameAndPassword(java.lang.String login,java.lang.String
password)"
*/
and this is the error jboss is throwing ..
17:35:48,147 ERROR [EntityContainer] Starting failed
jboss.j2ee:jndiName=UserLocal,service=EJB
org.jboss.deployment.DeploymentException: Query method not found:
findByUsernameAndPassword(java.lang.String,java.lang.String)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCQueryMetaDataFactory.getQueryMethods(JDBCQueryMetaDataFactory.java:322)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCQueryMetaDataFactory.getQueryMethods(JDBCQueryMetaDataFactory.java:243)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCQueryMetaDataFactory.createJDBCQueryMetaData(JDBCQueryMetaDataFactory.java:65)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCEntityMetaData.<init>(JDBCEntityMetaData.java:862)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCApplicationMetaData.<init>(JDBCApplicationMetaData.java:363)
at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCXmlFileLoader.load(JDBCXmlFileLoader.java:75)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.loadJDBCEntityMetaData(JDBCStoreManager.java:705)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.initStoreManager(JDBCStoreManager.java:417)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.start(JDBCStoreManager.java:365)
at org.jboss.ejb.plugins.CMPPersistenceManager.start(CMPPersistenceManager.java:147)
at org.jboss.ejb.EntityContainer.startService(EntityContainer.java:337)
at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:271)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:221)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
i have to add that i can use the findByPrimaryKey method without any
probems which means that i made a mistake in my finder method ...
but i dont know why it throws a NullPointerException
greetings from berlin