[JNDI/Naming/Network] - Connecting to legacy JBoss 3.0.3
by whafrog
I've converted a web-app from running on Weblogic/EJB2 to Jboss 4.2.0/EJB3. The app needs to connect to a message queue hosted by a legacy app running on JBoss (3.0.3). The old Weblogic version used the jbossall-client.jar from 3.0.3, however, the new version shouldn't need that, correct?
However, when I try to connect to the 3.0.3 legacy server from JBoss 4.2.0, I get the following error:
javax.naming.CommunicationException [Root exception is java.rmi.ServerException: RemoteException occurred in server thread; nested exception is:
| java.rmi.UnmarshalException: error unmarshalling arguments; nested exception is:
| java.lang.ClassNotFoundException: org.jnp.interfaces.FastNamingProperties (no security manager: RMI class loader disabled)
If I include the jbossall-client.jar from 4.2.0 in the web app, I get the following error:
13:48:30,562 ERROR Exception sending context initialized event to listener instance of class
| org.jboss.web.jsf.integration.config.JBossJSFConfigureListener
| java.lang.IncompatibleClassChangeError
I found this jira issue: http://jira.jboss.org/jira/browse/JBAS-5048
...which suggests that the process is attempting to serialize the FastNamingProperties class to the remote client (which does not exist in JBoss 3.0.3). The suggested workaround is to break the lookup into two. However, I'm not sure how to work around it in my case:
Hashtable p = new Hashtable();
| p.put(Context.INITIAL_CONTEXT_FACTORY, "org.jnp.interfaces.NamingContextFactory");
| p.put(Context.PROVIDER_URL, "jnp://legacyserver:1099");
| p.put(Context.URL_PKG_PREFIXES, "org.jboss.naming:org.jnp.interfaces");
| Context context = new InitialContext(p);
| QueueConnectionFactory factory = (QueueConnectionFactory)initial.lookup("ConnectionFactory");
| Queue queue = (Queue)initial.lookup("queue/testQueue");
Any workaround advice? TIA...
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4146314#4146314
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4146314
18 years
[JBoss jBPM] - Decision Node
by simply smart1
hi,
i'm using a decision node via a DefinitionHandler and this is the code
| package com.sample.action;
|
| import org.jbpm.context.exe.ContextInstance;
| import org.jbpm.graph.exe.ExecutionContext;
| import org.jbpm.graph.node.DecisionHandler;
|
| public class Istrue implements DecisionHandler {
|
|
| public String decide(ExecutionContext executionContext) throws Exception {
| String message= null;
| executionContext.getContextInstance().setVariable("message", message);
| Object object=new Object();
| object=executionContext.getVariable("Avis_DJ_hypo");
| //Nom it s a context variable
| if(object.toString().equals("yes"))
| return "Oui";
| else
| return "Non";
|
| }
| }
and on my XML file this is what i wrote concerning this node:
| <decision name="decision1">
| <handler class= "com.sample.action.Istrue"/>
| <transition name="Non" to="Rejet du dossier par DJ"></transition>
| <transition name="Oui" to="Montage du dossier et mettre sous GED (Ag)"></transition>
| </decision>
"Avis_DJ_hypo" is a variable on my process which an actor put it in a task form via a task node before this decision node , the problem is that when i put a value to this variable and want to save and go to the next transition i got this Error message on the web console and i'cant continue the execution and i stay blocked, this is the message:
| Error completing task: An exception of type "org.jbpm.graph.def.DelegationException" was thrown.
so what's the problem, need help.
thanks for all
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4146312#4146312
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4146312
18 years