Beginner |
|
Joined: Fri Jan 07, 2005 2:47 pm Posts: 45
|
Salut,
J'obtiens l'erreur suivante du serveur websphere lorsque j'essaie de me logger à l'application: TRAS0014I: The following exception was logged net.sf.hibernate.MappingException: Resource: SSS\Utility\Increments.hbm.xml not found at ....
Le fichier Increments.hbm.xml est dans le même pakage que le fichier Increments.java. J'ai trouvé et essayé quelques tutoriels faisant état de ce problème sans succès. Je fais malheureusement une erreur quelque part mais je n'arrive pas à trouver où. Est-ce que quelqu'un pourait m'aider ou aurait une idée.
Merci beaucoup
Hibernate version:
hibernate 2.1.6
Mapping documents:
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-2.0.dtd">
<hibernate-configuration>
<session-factory>
<property name="show_sql">true</property>
<property name="hibernate.dialect">net.sf.hibernate.dialect.Oracle9Dialect</property>
<property name="hibernate.connection.driver_class">oracle.jdbc.driver.OracleDriver</property>
<property name="hibernate.connection.url">jdbc:oracle:thin:@oraclename:1111:host1</property>
<property name="hibernate.connection.username">personname</property>
<property name="hibernate.connection.password">xxxxxx</property>
<mapping resource="SAP\Utility\Increments.hbm.xml" />
</session-factory>
</hibernate-configuration>
Code between sessionFactory.openSession() and session.close():
public static Session getSession() throws InfrastructureException {
Session s= (Session) threadSession.get();
try {
if (s == null) {
log.debug("Opening new Session for this thread.");
if (getInterceptor() != null) {
log.debug("Using interceptor: " + getInterceptor().getClass());
s= getSessionFactory().openSession(getInterceptor());
} else {
s= getSessionFactory().openSession();
}
threadSession.set(s);
}
} catch (HibernateException ex) {
throw new InfrastructureException(ex);
}
return s;
}
Full stack trace of any exception that occurs:
Name and version of the database you are using:
Oracle 9i
The generated SQL (show_sql=true):
Debug level Hibernate log excerpt:
TRAS0014I: The following exception was logged net.sf.hibernate.MappingException: Resource: SSS\Utility\Increments.hbm.xml not found at net.sf.hibernate.cfg.Configuration.addResource(Configuration.java:334) at net.sf.hibernate.cfg.Configuration.doConfigure(Configuration.java:1013) at net.sf.hibernate.cfg.Configuration.doConfigure(Configuration.java:969) at net.sf.hibernate.cfg.Configuration.configure(Configuration.java:897) at net.sf.hibernate.cfg.Configuration.configure(Configuration.java:883) at SAP.Utility.HibernateUtil.<clinit>(HibernateUtil.java:48) at SAP.DAOObjects.UserDAO.findByUsername(UserDAO.java:129) at SAP.BusinessObjects.User.getUserProfile(User.java:266) at SAP.BusinessObjects.User.validateUserAuthenticity(User.java:118) at SAP.BusinessObjects.User.login(User.java:66) at SAP.actions.LogonAction.executeLogon(LogonAction.java:46) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAc -- <truncated> --.
|
|