11:36:14,666DEBUG SecurityAssociation:143 - Using ThreadLocal: false
11:36:14,715DEBUG Client:514 - invoke called, but our invoker is disconnected, discarding and fetching another fresh invoker for: InvokerLocator [socket://127.0.0.2:3873/]
11:36:14,715DEBUG SocketClientInvoker:275 - connect called for: org.jboss.remoting.transport.socket.SocketClientInvoker@15d56d5
javax.ejb.EJBException: java.lang.IllegalArgumentException: org.hibernate.hql.ast.QuerySyntaxException: USR is not mapped [SELECT DISTINCT OBJECT(k) FROM USR k WHERE k.username = ?1]
...
Caused by: org.hibernate.hql.ast.QuerySyntaxException: USR is not mapped [SELECT DISTINCT OBJECT(k) FROM USR k WHERE k.username = ?1]
at org.hibernate.hql.ast.util.SessionFactoryHelper.requireClassPersister(SessionFactoryHelper.java:158)
trying to decode a woman mind....
trying to decode a woman mind....
11:18:12,103 INFO [JmxKernelAbstraction] installing MBean: persistence.units:jar=Users-EJBModule.jar,unitName=Users-EJBModulePU with dependencies:
11:18:12,104 INFO [JmxKernelAbstraction] jboss.jca:name=MySqlDS,service=DataSourceBinding
11:18:12,154 INFO [Version] Hibernate EntityManager 3.2.0.GA
11:18:12,184 INFO [Version] Hibernate Annotations 3.2.0.GA
11:18:12,199 INFO [Environment] Hibernate 3.2.0.ga
11:18:12,209 INFO [Environment] hibernate.properties not found
11:18:12,212 INFO [Environment] Bytecode provider name : javassist
11:18:12,219 INFO [Environment] using JDK 1.4 java.sql.Timestamp handling
11:18:12,376 WARN [Ejb3Configuration] Persistence provider caller does not implements the EJB3 spec correctly. PersistenceUnitInfo.getNewTempClassLoader() is null.
11:18:12,471 INFO [Configuration] Reading mappings from resource: META-INF/orm.xml
11:18:12,475 INFO [Ejb3Configuration] [PersistenceUnit: Users-EJBModulePU] no META-INF/orm.xml found
11:18:12,585 INFO [AnnotationBinder] Binding entity from annotated class: eu.virtualLab.users.model.Usr
11:18:12,663 INFO [EntityBinder] Bind entity eu.virtualLab.users.model.Usr on table USR
11:18:13,132 INFO [ConnectionProviderFactory] Initializing connection provider: org.hibernate.ejb.connection.InjectedDataSourceConnectionProvider
11:18:13,141 INFO [InjectedDataSourceConnectionProvider] Using provided datasource
11:18:13,338 INFO [SettingsFactory] RDBMS: MySQL, version: 5.0.18
11:18:13,339 INFO [SettingsFactory] JDBC driver: MySQL-AB JDBC Driver, version: mysql-connector-java-3.0.11-stable ( $Date: 2004/02/04 02:47:36 $, $Revision: 1.27.2.34 $ )
11:18:13,376 INFO [Dialect] Using dialect: org.hibernate.dialect.MySQL5Dialect
11:18:13,387 INFO [TransactionFactoryFactory] Transaction strategy: org.hibernate.ejb.transaction.JoinableCMTTransactionFactory
11:18:13,394 INFO [TransactionManagerLookupFactory] instantiating TransactionManagerLookup: org.hibernate.transaction.JBossTransactionManagerLookup
11:18:13,400 INFO [TransactionManagerLookupFactory] instantiated TransactionManagerLookup
11:18:13,401 INFO [SettingsFactory] Automatic flush during beforeCompletion(): disabled
11:18:13,401 INFO [SettingsFactory] Automatic session close at end of transaction: disabled
11:18:13,401 INFO [SettingsFactory] JDBC batch size: 15
11:18:13,401 INFO [SettingsFactory] JDBC batch updates for versioned data: disabled
11:18:13,403 INFO [SettingsFactory] Scrollable result sets: enabled
11:18:13,403 INFO [SettingsFactory] JDBC3 getGeneratedKeys(): enabled
11:18:13,403 INFO [SettingsFactory] Connection release mode: auto
11:18:13,407 INFO [SettingsFactory] Maximum outer join fetch depth: 2
11:18:13,407 INFO [SettingsFactory] Default batch fetch size: 1
11:18:13,407 INFO [SettingsFactory] Generate SQL with comments: disabled
11:18:13,408 INFO [SettingsFactory] Order SQL updates by primary key: disabled
11:18:13,408 INFO [SettingsFactory] Query translator: org.hibernate.hql.ast.ASTQueryTranslatorFactory
11:18:13,415 INFO [ASTQueryTranslatorFactory] Using ASTQueryTranslatorFactory
11:18:13,416 INFO [SettingsFactory] Query language substitutions: {}
11:18:13,416 INFO [SettingsFactory] JPA-QL strict compliance: enabled
11:18:13,416 INFO [SettingsFactory] Second-level cache: enabled
11:18:13,416 INFO [SettingsFactory] Query cache: disabled
11:18:13,418 INFO [SettingsFactory] Cache provider: org.hibernate.cache.HashtableCacheProvider
11:18:13,423 INFO [SettingsFactory] Optimize cache for minimal puts: disabled
11:18:13,424 INFO [SettingsFactory] Structured second-level cache entries: disabled
11:18:13,442 INFO [SettingsFactory] Echoing all SQL to stdout
11:18:13,443 INFO [SettingsFactory] Statistics: disabled
11:18:13,443 INFO [SettingsFactory] Deleted entity synthetic identifier rollback: disabled
11:18:13,447 INFO [SettingsFactory] Default entity-mode: pojo
11:18:13,512 INFO [SessionFactoryImpl] building session factory
11:18:14,652 INFO [SessionFactoryObjectFactory] Not binding factory to JNDI, no JNDI name configured
11:18:14,723 INFO [SchemaExport] Running hbm2ddl schema export
11:18:14,728 INFO [SchemaExport] exporting generated schema to database
11:18:14,885 INFO [SchemaExport] schema export complete
11:18:14,954 INFO [NamingHelper] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory, java.naming.factory.url.pkgs=org.jboss.naming rg.jnp.interfaces}
11:18:15,176 INFO [JmxKernelAbstraction] installing MBean: jboss.j2ee:jar=Users-EJBModule.jar,name=UsrSessionBean,service=EJB3 with dependencies:
11:18:15,177 INFO [JmxKernelAbstraction] persistence.units:jar=Users-EJBModule.jar,unitName=Users-EJBModulePU
11:18:16,282 INFO [EJBContainer] STARTED EJB: eu.virtualLab.users.UsrSessionBean ejbName: UsrSessionBean
11:18:16,390 INFO [EJB3Deployer] Deployed: file:/etc/jboss-4.0.5.GA/server/default/deploy/Users-EJBModule.jar
javax.ejb.EJBException: javax.persistence.PersistenceException: org.hibernate.PropertyValueException:
not-null property references a null or transient value: eu.virtualLab.users.model.Usr.password
//add user to database
logger.info("[addUsr] password value? -> "+password);
Usr user = new Usr(username,password,_role,_name,surname,companyName,vat,
address,city,postcode,country,email,phone,false);
em.persist(user);
@Column(name="password", nullable=false)
private String password;
public String getPassword() {
return password;
}
public void setPassword(String password) {
this.password = password;
}
trying to decode a woman mind....
trying to decode a woman mind....
Originally posted by Alessandro Ilardo:
Mark, you were write, I didn't notice that the parameter name didn't match the other param sent to the setPassword method.
It's a such of small mistake, but quite frequent, so I guess I need to pay more attention. But thank you anyway, you probably avoid me to spend half day trying to figure it out.
Have a good day.
Thank you again.
what if we put solar panels on top of the semi truck trailer? That could power this tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
|