-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Weird problem with QueryTranslatorFactory [SOLVED]
PostPosted: Fri Oct 23, 2009 3:04 am 
Newbie

Joined: Thu Oct 22, 2009 6:47 am
Posts: 1
Location: Helsinki, Finland
Hi

I'm using combination of jetty+oracle 10g XE+hibernate.

In jetty.xml I have
Code:
<New id="HibernateDS" class="org.mortbay.jetty.plus.naming.Resource">
      <Arg>jdbc/HibernateDS</Arg>
      <Arg>
        <New class="oracle.jdbc.pool.OracleConnectionPoolDataSource">
          <Set name="URL">jdbc:oracle:thin:@localhost:1521:XE</Set>
          <Set name="User">username</Set>
          <Set name="Password">password</Set>
        </New>
      </Arg>
    </New>


and in Hibernate.cfg.xml
Code:
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
<session-factory>
      <property name="hibernate.cglib.use_reflection_optimizer">true</property>
      <property name="hibernate.hbm2ddl.auto">update</property>
      <property name="connection.datasource">jdbc/HibernateDS</property>
      <property name="dialect">org.hibernate.dialect.Oracle10gDialect</property>
     
      *mappings*
</session-factory>
</hibernate-configuration>


With these I get this error
Code:
org.hibernate.HibernateException(could not instantiate QueryTranslatorFactory: org.hibernate.hql.ast.ASTQueryTranslatorFactory) at org.hibernate.cfg.SettingsFactory.createQueryTranslatorFactory(SettingsFactory.java:391)


Do you have any ideas why I get this error? I try to find anything related to this from google but found nothing useful.

Weirdest thing is that it was working beginning of this week and suddenly stopped working.

Edit.
So the reason for this was that there were duplicated jar files of hibernate in classpath.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.