can you paste here the full stack trace of your problem? along with the version of jbpm and drools that you are using.<br><br>Greetings.<br><br><div class="gmail_quote">On Wed, Mar 16, 2011 at 7:38 AM, Odelya Holiday <span dir="ltr">&lt;<a href="mailto:odelyay@sintecmedia.com">odelyay@sintecmedia.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi!<br>
<br>
I posted my previous message from the web client and it was corrupted. So here is the full one:<br>
<br>
get InvocationTargetException  after the following:<br>
<br>
 return constructor.newInstance( kbase,  conf, env );<br>
<br>
in KnowledgeStoreServiceImpl.<br>
<br>
I see that in return (T) constructorAccessor.newInstance(initargs) of Constructor class it throws the InvocationTargetException.<br>
<br>
The exception is null so I can&#39;t see what it the problem!<br>
<br>
I call the code from this:<br>
<br>
EntityManagerFactory emf = Persistence.createEntityManagerFactory(&quot;org.drools.persistence.jpa&quot;);<br>
                Environment env = KnowledgeBaseFactory.newEnvironment();<br>
                env.set(EnvironmentName.ENTITY_MANAGER_FACTORY, emf);<br>
                env.set(EnvironmentName.GLOBALS, new MapGlobalResolver());<br>
                env.set(EnvironmentName.TRANSACTION_MANAGER, TransactionManagerServices.getTransactionManager());<br>
                ksession = JPAKnowledgeService.newStatefulKnowledgeSession(kbase, null, env);<br>
<br>
I define the transaction manager in my spring beans like this:<br>
&lt;!--  Bitronix Transaction Manager embedded configuration --&gt;<br>
        &lt;bean id=&quot;xaDataSource&quot; class=&quot;bitronix.tm.resource.jdbc.PoolingDataSource&quot;<br>
                init-method=&quot;init&quot; destroy-method=&quot;close&quot;&gt;<br>
                &lt;property name=&quot;className&quot; value=&quot;bitronix.tm.resource.jdbc.lrc.LrcXADataSource&quot; /&gt;<br>
                &lt;property name=&quot;uniqueName&quot; value=&quot;java/DS1&quot; /&gt;<br>
                &lt;property name=&quot;maxPoolSize&quot; value=&quot;5&quot; /&gt;<br>
                &lt;property name=&quot;minPoolSize&quot; value=&quot;0&quot; /&gt;<br>
                &lt;property name=&quot;allowLocalTransactions&quot; value=&quot;false&quot; /&gt;<br>
                &lt;property name=&quot;testQuery&quot; value=&quot;SELECT 1 FROM DUAL&quot; /&gt;<br>
                &lt;property name=&quot;driverProperties&quot;&gt;<br>
                        &lt;props&gt;<br>
                                &lt;prop key=&quot;user&quot;&gt;username&lt;/prop&gt;<br>
                                &lt;prop key=&quot;password&quot;&gt;username&lt;/prop&gt;<br>
                                &lt;prop key=&quot;url&quot;&gt;url&lt;/prop&gt;<br>
                                &lt;prop key=&quot;driverClassName&quot;&gt;oracle.jdbc.OracleDriver&lt;/prop&gt;<br>
                        &lt;/props&gt;<br>
                &lt;/property&gt;<br>
        &lt;/bean&gt;<br>
<br>
<br>
        &lt;bean id=&quot;btmConfig&quot; factory-method=&quot;getConfiguration&quot;<br>
                class=&quot;bitronix.tm.TransactionManagerServices&quot;&gt;<br>
                &lt;property name=&quot;serverId&quot; value=&quot;spring-btm&quot; /&gt;<br>
        &lt;/bean&gt;<br>
<br>
<br>
        &lt;bean id=&quot;bitronixTransactionManager&quot; factory-method=&quot;getTransactionManager&quot;<br>
                class=&quot;bitronix.tm.TransactionManagerServices&quot; depends-on=&quot;btmConfig,xaDataSource&quot;<br>
                destroy-method=&quot;shutdown&quot; /&gt;<br>
<br>
<br>
        &lt;bean id=&quot;jtaTransactionManager&quot;<br>
                class=&quot;org.springframework.transaction.jta.JtaTransactionManager&quot;&gt;<br>
                &lt;property name=&quot;transactionManager&quot; ref=&quot;bitronixTransactionManager&quot; /&gt;<br>
                &lt;property name=&quot;userTransaction&quot; ref=&quot;bitronixTransactionManager&quot; /&gt;<br>
        &lt;/bean&gt;<br>
        &lt;!--  end of Bitronix Transaction Manager embedded configuration --&gt;<br>
<br>
        &lt;bean id=&quot;transactionManager&quot;<br>
                class=&quot;org.springframework.orm.hibernate3.HibernateTransactionManager&quot;&gt;<br>
                &lt;property name=&quot;sessionFactory&quot; ref=&quot;OnMediaSessionFactory&quot; /&gt;<br>
        &lt;/bean&gt;<br>
<br>
I see that bitronix is up via the debugging messages. (2011-03-16 12:14:53,399 DEBUG (        PoolingDataSource.java:84)     - building XA pool for java/DS1 with 0 connection(s) etc..)<br>
<br>
in persistence.xml I have:<br>
<br>
&lt;persistence-unit name=&quot;org.drools.persistence.jpa&quot; transaction-type=&quot;JTA&quot;&gt;<br>
                    &lt;provider&gt;org.hibernate.ejb.HibernatePersistence&lt;/provider&gt;<br>
                    &lt;jta-data-source&gt;java/DS1&lt;/jta-data-source&gt;<br>
                    &lt;mapping-file&gt;persistenceorm.xml&lt;/mapping-file&gt;<br>
                    &lt;class&gt;org.drools.persistence.info.SessionInfo&lt;/class&gt;<br>
                    &lt;class&gt;org.jbpm.persistence.processinstance.ProcessInstanceInfo&lt;/class&gt;<br>
                    &lt;class&gt;org.drools.persistence.info.WorkItemInfo&lt;/class&gt;<br>
                    &lt;exclude-unlisted-classes&gt;true&lt;/exclude-unlisted-classes&gt;<br>
                    &lt;properties&gt;<br>
                              &lt;property name=&quot;hibernate.dialect&quot; value=&quot;org.hibernate.dialect.Oracle10gDialect&quot; /&gt;<br>
                              &lt;property name=&quot;hibernate.connection.autocommit&quot; value=&quot;false&quot; /&gt;<br>
                              &lt;property name=&quot;hibernate.max_fetch_depth&quot; value=&quot;3&quot; /&gt;<br>
                              &lt;property name=&quot;hibernate.show_sql&quot; value=&quot;true&quot; /&gt;<br>
                              &lt;property name=&quot;hibernate.connection.driver_class&quot; value=&quot;oracle.jdbc.driver.OracleDriver&quot; /&gt;<br>
                               &lt;property name=&quot;hibernate.jndi.class&quot; value=&quot;bitronix.tm.jndi.BitronixInitialContextFactory&quot;/&gt;<br>
                              &lt;property name=&quot;hibernate.transaction.manager_lookup_class&quot;<br>
                                        value=&quot;org.hibernate.transaction.BTMTransactionManagerLookup&quot; /&gt;<br>
                    &lt;/properties&gt;<br>
          &lt;/persistence-unit&gt;<br>
<br>
What could cause the problem?<br>
<br>
When I defined the btm with tomcat and not with spring - it worked fine. (but I had context reloading problems). when I define it only with spring - it get this weird exception.<br>
<br>
Thanks!<br>
<br>
Odelya<br>
<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</blockquote></div><br><br clear="all"><br>-- <br> - CTO @ <a href="http://www.plugtree.com">http://www.plugtree.com</a>  <br> - MyJourney @ <a href="http://salaboy.wordpress.com">http://salaboy.wordpress.com</a><br> - Co-Founder @ <a href="http://www.jbug.com.ar">http://www.jbug.com.ar</a><br>
 <br> - Salatino &quot;Salaboy&quot; Mauricio -<br>