[jBPM Users] - JBPM4 (with Spring beans) deployment into JBOSS
by krajesh_7
Had referred the JBPM UserGuide/DevGuide and write a workflow application using JBPM4 and Spring (for workflow action classes).
This application works in a standalone manner. Now I wanted to deploy the JBPM4 workflow application into JBOSS.
The Dev Guide had given some information about running a script to setup the standard jboss-jbpm integraion.
But I would like to know how the various configuration files of JBPM are configured for Spring integration when deployed into JBOSS.
Also, how the bean definitions for the jpdl application are to be configured in the deployment environment?
If the JBPM is deployed separately into JBOSS during startup, and at runtime many other workflows can be deployed (bar files). How will the JBPM's SpringConfiguration class that is used as loading the spring beans for the action class will load them succcessfully. Are all these beans stored in the same application context?
Kindly inform me about how to configure the files for the JBPM4 workflow (with Spring for workflow actions) deployment into JBOSS.
Thanks,
Rajesh.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4256376#4256376
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4256376
16 years, 7 months
[JBoss Cache Users] - Invalidation-only cache
by adamw
Hello,
here's my scenario: I want to keep some objects in cache, which are calculated basing on some persistent state (DB lets say). Rarely, the persistent state changes, and the objects have to be re-calculated (lazily). So, on a change, I want to invalidate all items. Additionally, this happens in a cluster, so the invalidation must be cluster-wide, although the change notification is received only in one node. The calculated objects aren't serializable so each node must calculate them independently.
I was trying to solve this with a cache in the INVALIDATION_SYNC mode and a cache loader. The cache loader is responsible for calculating the objects (I also get the laziness here) in each node. When a change happens, I simple call remove(), which invalidates entries in all nodes (because of the mode). When a get() is later called, the objects are read using the cache loader.
Now this works fine as along as I don't use transactions. When I start to use transactions, the get() call after a remove() call (in the same TX) doesn't call the cache loader, but returns null. This is quite logical and ok in the normal cases, but not in mine. Do you have any other suggestions on how to achieve the above functionality with transactions?
Thanks,
Adam
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4256360#4256360
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4256360
16 years, 7 months
[JBoss Messaging Users] - Re: long live consumer stops working
by PoonamAgarwal
Hi bodrin,
I am facing a similar issue of connection getting invalidated.
I am using JBM 1.4.0 SP3 and Jboss 4.20GA.
I have a consumer(client) created for a queue(on server).
I am successful in creating a connection and my consumer does receive messages. However, If I leave my server and consumer for sometime may be some(2-4) hours, I see a log trace in my client:
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (ConnectionValidator.java:674) - ConnectionValidator[SocketClientInvoker[1017ca1, bisocket://myserver:4457], pingPeriod=2000 ms]'s connections is invalid
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (InvokerRegistry.java:628) - removed SocketClientInvoker[1017ca1, bisocket://myserver:4457] from registry
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (MicroSocketClientInvoker.java:384) - SocketClientInvoker[1017ca1, bisocket://myserver:4457] disconnecting ...
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (SocketWrapper.java:127) - ClientSocketWrapper[Socket[addr=/myserver,port=4457,localport=4198].7f6b72] closing socket
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (SocketWrapper.java:129) - ClientSocketWrapper[Socket[addr=/myserver,port=4457,localport=4198].7f6b72] closed socket
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (SocketWrapper.java:127) - ClientSocketWrapper[Socket[addr=/myserver,port=4446,localport=4197].1673ef7] closing socket
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (SocketWrapper.java:129) - ClientSocketWrapper[Socket[addr=/myserver,port=4446,localport=4197].1673ef7] closed socket
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (SocketWrapper.java:127) - ClientSocketWrapper[Socket[addr=/myserver,port=4457,localport=4199].156cce6] closing socket
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (SocketWrapper.java:129) - ClientSocketWrapper[Socket[addr=/myserver,port=4457,localport=4199].156cce6] closed socket
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (ConnectionValidator.java:616) - ConnectionValidator[SocketClientInvoker[1017ca1, bisocket://myserver:4457], pingPeriod=2000 ms] stopped, returning true
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (ConnectionValidator.java:680) - org.jboss.remoting.ConnectionValidator$WaitOnConnectionCheckTimerTask@1a62f80 detected connection failure: stopping LeasePinger
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (LeasePinger.java:285) - LeasePinger[SocketClientInvoker[4bb369, bisocket://myserver:4457](4ss82w-n3gywx-fzvb4aaz-1-fzvb4cgo-c)] setting disconnect timeout to: -1
| [21 Sep 2009 15:24:02] DEBUG [Timer-3] (ConnectionValidator.java:686) - ConnectionValidator[SocketClientInvoker[1017ca1, bisocket://myserver:4457], pingPeriod=2000 ms] shut down lease pinger
| [21 Sep 2009 15:24:07] DEBUG [Thread-11] (ClientSocketWrapper.java:164) - reset timeout: 0
|
This kills my consumer which will no longer receive any messages from the server. How do I solve this problem?
1. How do I create a long live consumer in first place? I could not visit the examples sent by bodrin.
2. Should I listen for such disconnects and try to re-establish the connection on such disconnect? Where should I catch the disconnect exception?
3. What am I missing here?
Can somebody please help.
-Poonam.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4256352#4256352
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4256352
16 years, 7 months
[EJB 3.0 Users] - Returning EJB's from EJB's and transactions
by gerbrand
Hello,
I'm wondering about design of my application. We a lot of EJB (EJB3) using the @Stateless and @EJB tags. All EJB's are now local, but we're considering changing a few in remote interface.
Quite a few EJB's return EJB's also and I wonder if that is correct in the first place, and secondly if this still works (and is correct) if the beans would become remote EJB's:
| @Stateless
| @Local
| class BeanABean implements BeanA
| {
| ..
| }
|
| @Stateless
| @Local
| class BeanBBean implements BeanB
| {
| @EJB
| BeanA beanA;
|
| BeanA getBeanA() { return beanA; }
| }
|
Is the above code correct with regard to any JEE spec (I know from experience the code works). Secondly, if I use a BeanA that is returned from by the method of BeanB, is each operation done at BeanA done in a new transaction? Thirdly, what if both BeanA and BeanB become a remote interface (so getBeanA returns a remote interface), is the code still correct?
All of the above might be somewhere in an article, but unfortunately I couldn't find anything that exactly answered my questions.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4256340#4256340
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4256340
16 years, 7 months
[Beginner's Corner] - excel data into a drl
by simscarlet
Hi,
I currently have a function in a rule which is an array of arrays that hold rating data. The issue I have is this is quite large and I want to hold this data in an external file and ie csv or excel and import it into the rule as a table. Is there a way I could store these values in excel and import ?
Here is an example of the function:
function double getValues(int row,int col)
{
double[][] values =
{
{10.00, 15.00, 10.00, 12.50, 10.00, 12.50, 7.50, 12.50, 10.00, 12.50, 10.00, 15.00, 14.00, 12.50, 12.50, 12.75, 15.00, 12.00, 11.00, 13.50, 14.60, 15.00, 12.50, 7.00, 15.00, 16.00, 15.00, 10.00, 7.00, 12.50, 12.75, 10.00, 15.00, 15.00}, // 0 - 99.99
{10.00, 15.00, 10.00, 12.50, 10.00, 12.50, 7.50, 12.50, 10.00, 12.50, 10.00, 15.00, 14.00, 12.50, 12.50, 12.75, 15.00, 12.00, 11.00, 13.50, 14.60, 15.00, 12.50, 7.00, 15.00, 16.00, 15.00, 10.00, 7.00, 12.50, 12.75, 10.00, 15.00, 15.00}, // 100 - 199.99
{10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 7.50, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 7.00, 10.00, 10.00, 10.00, 10.00, 7.00, 10.00, 10.00, 10.00, 10.00, 10.00}, // 200 - 299.99
{10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 7.50, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 7.00, 10.00, 10.00, 10.00, 10.00, 7.00, 10.00, 10.00, 10.00, 10.00, 10.00}, // 300 - 399.99
{10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 7.50, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 7.00, 10.00, 10.00, 10.00, 10.00, 7.00, 10.00, 10.00, 10.00, 10.00, 10.00}, // 400 - 499.99
{10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 7.50, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 7.00, 10.00, 10.00, 10.00, 10.00, 7.00, 10.00, 10.00, 10.00, 10.00, 10.00}, // 500 - 599.99
{10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 7.50, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 10.00, 7.00, 10.00, 10.00, 10.00, 10.00, 7.00, 10.00, 10.00, 10.00, 10.00, 10.00}, // 600 - 699.99
{2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00}, // 700 - 799.99
{2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00}, // 800 - 899.99
{2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00}, // 900 - 999.99
{2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00}, //1000 - 1099.99
{2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00}, //1100 - 1199.99
{2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00}, //1200 - 1299.99
{2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00}, //1300 - 1399.99
{2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00}, //1400 - 1499.99
{2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00}, //1500 - 1599.99
{2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00, 2.00}, //1600 -
};
return values[row][col];
}
Thanks,
Simon.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4256337#4256337
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4256337
16 years, 7 months