[jBPM] - How to make console reload process instances after a recycle
by jjfutt
jjfutt [http://community.jboss.org/people/jjfutt] created the discussion
"How to make console reload process instances after a recycle"
To view the discussion, visit: http://community.jboss.org/message/619789#619789
--------------------------------------------------------------
Hello All:
I am trying to understand how to make the console show instances that are were in process when the server was restarted, as well as how to load instances (for visibility purposes) that might have been initiated by different java processes with different sessions. To further explain my questions, let me describe what I have done so far.
(1) Installed the JBPM 5 demo
(2) Used the instructions provided by Kris Verlaenen in a different thread ( http://community.jboss.org/message/577830#577830 http://community.jboss.org/message/577830) to configure the demo with a different database. In my case, I configured it with an Oracle database.
(3) Re ran the "ant install.demo" task to make the database chagne effective. (Note: I also changed hibernate hibernate.hbm2ddl.auto policy to validate to avoid recreating the tables again and again).
(4) Ran the demo.
At this point, everything works well. I can start process instances of the "Evaluation" process from the demo using the console. I see the tasks for user kris, john, and mary. And I see the rows getting created and updated in the database tables as expected. However what I also see is that:
Observation: If I recycle the server, all database info is wiped out. I set the hibernate.hbm2ddl.auto to validate to avoid this. However, now when I recycle the server, the data from previous instances of the running processes (that were waiting on the completion of the human task) and the session is still there after the restart. However, the Console DOES NOT show these instances. Also, the pending human tasks do not show up in the 'Tasks' section within the console.
Question 1: How can I force the console the reload the instances (And hence allow us to check the status ) of process instances that are still active but were initiated before the server recycle?
Question 2: When the console is started, in which condition it creates a 'new' session in the database and in which condition does it load the previous session. Before I changed the hibernate.hbm2ddl.auto policy to validate, the entire set of tables were being recreated upon recycle. Now that hibernate.hbm2ddl.auto is set to validate, each time I start the server, the console apparantely uses the same session id that it created the very first time. However, it doesn't automatically load the previous process instances that were created using that session.
Question 3: If we initiate process instations from other java components running as independent applications outside of the console, they may have different session ids. Is the console supposed to show all active process instances across all sessions, or does it only show process instances from its own session? Is it possible to make the console show instances from a specific session?
Question 4: the "Evaluation" process part of the demo, does not get reloaded into the console when I restart the server. Also the pending human tasks (for john and mary for example) don't show up in the tasks section either. How can I force the console to reload and resume the processes after the recycle?
Thank you all in advance.
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/619789#619789]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 6 months
[jBPM] - Can JBPM Console be used for visibility into processes being initiated from a different container
by jjfutt
jjfutt [http://community.jboss.org/people/jjfutt] created the discussion
"Can JBPM Console be used for visibility into processes being initiated from a different container"
To view the discussion, visit: http://community.jboss.org/message/619719#619719
--------------------------------------------------------------
Hello Everybody,
I'd appreciate if somebody could provide the guidance on the level of integration between CONSOLE and processes initiated from different containers. Here's our scenario:
(1) I'd like to deploy a JBPM process in a Web Container (Jboss or Tomcat), and I am going to use the instructions provided in the JBPM 5.1 Documentaiton to enable 'PERSISTENCE' on it.
However, the instructions provided for enabling persistence on JBPM don't highlight how persistence can be enabled for the console itself. I do get the impression that CONSOLE can be persistence enabled, and can be used to track, view and manage JBPM process instsances that might have been initiated from different containers, but can't find any instructions or information to implement the same. Can somebody please answer these two questions:
Q1: How do we enable persistence for JBPM Console. Right now, if I initiate an exmaple JBPM process deployed within console itself, it's lose after the Jboss server is recycled.
Q2: The instructions for enabling persistence specify how our Java Programs should initiate a process to make them persistence capable. But I couldn't find information if the console itself will use the similar steps when initiating instances from the console?
Q3: Is integration between console and other containers, supported ? (Using console for graphical visibility into processes initiated from other containers). Or is this not a typical scenario and requires creative soution?
Thanks in advance.
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/619719#619719]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 6 months
[Datasource Configuration] - driver-class ignored?
by Hubert Lyczek
Hubert Lyczek [http://community.jboss.org/people/lysy78] created the discussion
"driver-class ignored?"
To view the discussion, visit: http://community.jboss.org/message/619933#619933
--------------------------------------------------------------
Hello,
My environment is:
1. Java: jdk1.6.0_23
2. AS: jboss-6.0.0.Final
3. Database: MySQL 5.1
In order to connect to database it is needed to configure data source.
I created file mysql-ds.xml, and everything was ok.
But lately decided to use third party driver (different from original: com.mysql.jdbc.Driver), so I changed xml element driver-class. But nothing expected happened. So i decided to get the original environment and change value of driver-class element to something completely stupid: foo.bar.bla.bla.NotExistingDriver. And do you know what? - my data source was still ok. I didn't believe that.
Then I removed mysql connector jar, and i received exception:
> java.lang.ClassNotFoundException: foo.bar.bla.bla.NotExistingDriver
Jboss did not find this class, becouse this class did and still does not exist. But after adding mysql connector jar to lib directory again, everything was ok again. Did it mean that this class was found in mysql connector jar? Strange.
This is my mysql-ds.xml:
<datasources>
<local-tx-datasource>
<jndi-name>TestDS</jndi-name>
<connection-url>jdbc:mysql://localhost:3306/test</connection-url>
<driver-class>foo.bar.bla.bla.NotExistingDriver</driver-class>
<user-name>test</user-name>
<password>test</password>
<exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.MySQLExceptionSorter</exception-sorter-class-name>
<valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.MySQLValidConnectionChecker</valid-connection-checker-class-name>
<!--
<new-connection-sql>select * from test</new-connection-sql>
-->
<!-- sql to call on an existing pooled connection when it is obtained from pool - MySQLValidConnectionChecker is preferred for newer drivers
<check-valid-connection-sql>some arbitrary sql</check-valid-connection-sql>
-->
<!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
<metadata>
<type-mapping>mySQL</type-mapping>
</metadata>
</local-tx-datasource>
</datasources>
So... the question is:
Is the element driver-class ignored by jboss?
Could anyone explain it to me, please?
Thanks in advance
Hubert
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/619933#619933]
Start a new discussion in Datasource Configuration at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 6 months