-
1. Oracle Integration with JBPM5
bpmn2user May 18, 2011 5:20 PM (in response to 2sharma.vishal)Here are the steps if you are trying to use Oracle with jbpm console:
http://community.jboss.org/people/bpmn2user/blog/2011/02/26/orcale-integration-with-jbpm5
If you are using a stand alone example and persisting using API you can follow the following example. You can uncomment the Oracle configurations in persistence.xml etc and use your host details.
http://community.jboss.org/people/bpmn2user/blog/2011/02/26/orcale-integration-with-jbpm5
-
2. Oracle Integration with JBPM5
2sharma.vishal May 19, 2011 7:55 AM (in response to bpmn2user)I have tried to configure all the files according to the link that <ou have mentioned but it soesn't work.
I am attaching my all the configuration files. I hope that you will be able to help me afterwards.
hibernate.cfg.xml
#################
<?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>
<!-- Database connection settings
<property name="connection.driver_class">org.h2.Driver</property>
<property name="connection.url">jdbc:h2:tcp://localhost/~/test</property>
property name="connection.url">jdbc:h2:file:/NotBackedUp/data/mydb</property
<property name="connection.username">sa</property>
<property name="connection.password"></property>
-->
<!-- Database connection settings -->
<property name="connection.driver_class">oracle.jdbc.OracleDriver</property>
<property name="connection.url">jdbc:oracle:thin:@localhost:8087:test</property>
<property name="connection.username">SYSTEM</property>
<property name="connection.password">p@zzw0rd</property>
<!-- JDBC connection pool (use the built-in) -->
<property name="connection.pool_size">1</property>
<!-- SQL dialect -->
<property name="dialect">org.hibernate.dialect.Oracle10gDialect</property>
<!-- JDBC connection pool (use the built-in) -->
<property name="connection.pool_size">1</property>
<!-- SQL dialect
<property name="dialect">org.hibernate.dialect.H2Dialect</property>-->
<!-- Enable Hibernate's automatic session context management -->
<property name="current_session_context_class">thread</property>
<!-- Disable the second-level cache -->
<property name="cache.provider_class">org.hibernate.cache.NoCacheProvider</property>
<!-- Echo all executed SQL to stdout -->
<property name="show_sql">false</property>
<!-- Drop and re-create the database schema on startup? -->
<property name="hbm2ddl.auto">create</property>
<mapping resource="AuditLog.hbm.xml"/>
</session-factory>
</hibernate-configuration>
persistance.xml
########################
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<persistence version="1.0"
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd
http://java.sun.com/xml/ns/persistence/orm
http://java.sun.com/xml/ns/persistence/orm_1_0.xsd"
xmlns:orm="http://java.sun.com/xml/ns/persistence/orm"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://java.sun.com/xml/ns/persistence">
<persistence-unit name="org.drools.persistence.jpa" transaction-type="JTA">
<provider>org.hibernate.ejb.HibernatePersistence</provider>
<jta-data-source>java:jdbc/testDS1</jta-data-source>
<class>org.jbpm.persistence.processinstance.ProcessInstanceInfo</class>
<class>org.drools.persistence.info.SessionInfo</class>
<class>org.drools.persistence.info.WorkItemInfo</class>
<properties>
<property name="hibernate.dialect" value="org.hibernate.dialect.10gDialect"/>
<property name="hibernate.max_fetch_depth" value="3"/>
<property name="hibernate.hbm2ddl.auto" value="create" />
<property name="hibernate.show_sql" value="true" />
<property name="hibernate.transaction.manager_lookup_class" value="org.hibernate.transaction.JBossTransactionManagerLookup" />
</properties>
</persistence-unit>
</persistence>
testDS1-ds.xml
####################
<?xml version="1.0" encoding="UTF-8"?>
<datasources>
<local-tx-datasource>
<jndi-name>jdbc/testDS1</jndi-name>
<connection-url>jdbc:oracle:thin:@localhost:8087:test</connection-url>
<!--connection-url>jdbc:h2:mem:mydb</connection-url-->
<driver-class>org.h2.jdbcx.JdbcDataSource</driver-class>
<user-name>SYSTEM</user-name>
<password>p@zzw0rd</password>
</local-tx-datasource>
</datasources>
-
3. Re: Oracle Integration with JBPM5
frankee787 May 25, 2011 4:13 AM (in response to 2sharma.vishal)Can you post the error shown so probably we can provide a hint?
-
4. Re: Oracle Integration with JBPM5
2sharma.vishal Jun 6, 2011 7:42 AM (in response to frankee787)Hello,
I am only getting the error in the JBPM console, but on the other hand I cannot find any default entries in Oracle. I can only see the error in the reporting template. If I check in the settings of the jbpm console it shows me a cross mark on the process engine plugin. And in the reporting tool it gives an error with http 500 and the error in the console.And moreover I am not able to export anything from eclipse to drools guvnor, or to import anything from the guvnor to eclipse.I hope you will be able to help me.
Thanks and Regards
Vishal
##########error in the jbpm console###############
2011-06-12 13:13:59,410 [DEBUG] GET: http://localhost:8080/gwt-console-server/rs/report/config
<li>Action: 'org.jboss.bpm.console.client.report.UpdateReportConfigAction'
<li>Exception: 'class com.google.gwt.http.client.RequestException'</ul>
org.jboss.resteasy.core.SynchronousDispatcher.handleApplicationException(SynchronousDispatcher.java:319)
org.jboss.resteasy.core.SynchronousDispatcher.handleException(SynchronousDispatcher.java:230)
org.jboss.resteasy.core.SynchronousDispatcher.handleInvokerException(SynchronousDispatcher.java:206)
org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:360)
org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:173)
org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:93)
org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:68)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.jboss.bpm.console.server.util.GWTJsonFilter.doFilter(GWTJsonFilter.java:59)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
</pre></p><p><b>root cause</b> <pre>java.lang.IllegalStateException: Report server not initialized. Please check the server logs for further details.
org.jboss.bpm.report.ReportFacade.assertBirtAvailability(ReportFacade.java:195)
org.jboss.bpm.report.ReportFacade.getReportConfig(ReportFacade.java:328)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:597)
org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:117)
org.jboss.resteasy.core.ResourceMethod.invokeOnTarget(ResourceMethod.java:260)
org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:232)
org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:166)
org.jboss.resteasy.core.DispatcherUtilities.getJaxrsResponse(DispatcherUtilities.java:142)
org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:356)
org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:173)
org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:93)
org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:68)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.jboss.bpm.console.server.util.GWTJsonFilter.doFilter(GWTJsonFilter.java:59)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
</pre></p><p><b>note</b> <u>The full stack trace of the root cause is available in the JBoss Web/2.1.3.GA logs.</u></p><HR size="1" noshade="noshade"><h3>JBoss Web/2.1.3.GA</h3></body></html>
com.google.gwt.http.client.RequestException:
HTTP 500:HTTP Status 500 -
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
org.jboss.resteasy.spi.UnhandledException: java.lang.IllegalStateException: Report server not initialized. Please check the server logs for further details.
org.jboss.resteasy.core.SynchronousDispatcher.handleApplicationException(SynchronousDispatcher.java:319)
org.jboss.resteasy.core.SynchronousDispatcher.handleException(SynchronousDispatcher.java:230)
org.jboss.resteasy.core.SynchronousDispatcher.handleInvokerException(SynchronousDispatcher.java:206)
org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:360)
org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:173)
org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:93)
org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:68)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.jboss.bpm.console.server.util.GWTJsonFilter.doFilter(GWTJsonFilter.java:59)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)root cause
java.lang.IllegalStateException: Report server not initialized. Please check the server logs for further details.
org.jboss.bpm.report.ReportFacade.assertBirtAvailability(ReportFacade.java:195)
org.jboss.bpm.report.ReportFacade.getReportConfig(ReportFacade.java:328)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:597)
org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.jav -
5. Re: Oracle Integration with JBPM5
2sharma.vishal Jun 6, 2011 7:56 AM (in response to 2sharma.vishal)I have checked the server log and there it shows that
(javax.resource.ResourceException: Unable to get managed connection for jdbc/testDS1)
I hope it will help you to monitor the problem.
-
6. Re: Oracle Integration with JBPM5
frankee787 Jun 6, 2011 8:20 AM (in response to 2sharma.vishal)Try adding this before you start your KnowledgeBase
PoolingDataSource ds1 = new PoolingDataSource();
ds1.setUniqueName( "jdbc/testDS2" );
ds1.setClassName( "com.mysql.jdbc.jdbc2.optional.MysqlXADataSource" );
ds1.setMaxPoolSize( 10 );
ds1.setAllowLocalTransactions( true );
ds1.getDriverProperties().put( "user","root" );
ds1.getDriverProperties().put( "password","password" );
ds1.getDriverProperties().put( "URL","jdbc:mysql://DTL-HO-RND02.datelservices.com:3306/myjbpm5db" );
ds1.init();