[jBPM] - Design advice: multi-day scenario
by Jonathan L
Jonathan L [https://community.jboss.org/people/jhl] created the discussion
"Design advice: multi-day scenario"
To view the discussion, visit: https://community.jboss.org/message/795260#795260
--------------------------------------------------------------
Hi,
I've been trying to think of the best process design workflow for my use case, and need some guidance.
Here's the scenario (simplified for the sake of discussion):
We have a list of customers that we want to send emails to, but after certain days after their account has been activated.
When an account is created, kick off the workflow
@ 10 days after activation, send email A
@ 20 days after activation, send email B
@ 30 days after activation, send email C
@ 45 days after activation, send email D
@ 60 days after activation, remove from workflow
The number of days after activation increments daily
There are a few events that would remove the customer from the workflow, (i.e. "unsubscribe") - these events can come from a 3rd party system.
//
My question is what is the best way to model this behavior ? I thought that jBPM would be the best solution because the progression of each step is fairly linear. The exception is the ability to take in an event that removes the customer from the workflow.
Any advice would be greatly appreciated. Thank you.
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/795260#795260]
Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
11 years, 10 months
[Beginner's Corner] - Jboss 6 - Linkage Error
by powerpuff
powerpuff [https://community.jboss.org/people/powerpuff] created the discussion
"Jboss 6 - Linkage Error"
To view the discussion, visit: https://community.jboss.org/message/795289#795289
--------------------------------------------------------------
I am trying to migrate my application from Jboss 4 to Jboss 6.
Its a web service application, which is using Axis2 implementation.
Below jars are reffered by Axis2
<fileset id="axis.runtime.fileset" dir="${common.lib.dir}/axis2/1_4_1">
<include name="axis2-kernel-1.4.1.jar"/>
<include name="axiom-api-1.2.7.jar"/>
<include name="axiom-impl-1.2.7.jar"/>
<include name="neethi-2.0.4.jar"/>
<include name="woden-api-1.0M8.jar"/>
<include name="woden-impl-dom-1.0M8.jar"/>
<include name="wsdl4j-1.6.2.jar"/>
<include name="xmlbeans-2.3.0.jar"/>
<include name="axis2-adb-1.4.1.jar"/>
<include name="XmlSchema-1.4.2.jar"/>
<include name="axis2-spring-1.4.1.jar"/>
<!--include name="stax-1.2.0.jar"/-->
</fileset>
If i include stax-api jar in project build, it is failing during deployment. If i remove stax api jar from application build, i am able to deploy the application successfully but when i try to access the web services i get below linage error:
[org.apache.axis2.transport.http.AxisServlet] loader constraint violation in interface itable initialization: when resolving method "org.apache.axiom.om.impl.llom.OMStAXWrapper.getName()Ljavax/xml/namespace/QName;" the class loader (instance of org/jboss/classloader/spi/base/BaseClassLoader) of the current class, org/apache/axiom/om/impl/llom/OMStAXWrapper, and the class loader (instance of <bootloader>) for interface javax/xml/stream/XMLStreamReader have different Class objects for the type javax/xml/namespace/QName used in the signature: java.lang.LinkageError: loader constraint violation in interface itable initialization: when resolving method "org.apache.axiom.om.impl.llom.OMStAXWrapper.getName()Ljavax/xml/namespace/QName;" the class loader (instance of org/jboss/classloader/spi/base/BaseClassLoader) of the current class, org/apache/axiom/om/impl/llom/OMStAXWrapper, and the class loader (instance of <bootloader>) for interface javax/xml/stream/XMLStreamReader have different Class objects for the type javax/xml/namespace/QName used in the signature
at org.apache.axiom.om.impl.llom.OMElementImpl.getXMLStreamReader(OMElementImpl.java:752) [:]
at org.apache.axiom.om.impl.llom.OMElementImpl.getXMLStreamReaderWithoutCaching(OMElementImpl.java:726) [:]
at com.fdc.valuelink.endpoint.ValueLinkTransactionMessageReceiverInOut.fromOM(Unknown Source) [:]
at com.fdc.valuelink.endpoint.ValueLinkTransactionMessageReceiverInOut.invokeBusinessLogic(Unknown Source) [:]
at org.apache.axis2.receivers.AbstractInOutMessageReceiver.invokeBusinessLogic(AbstractInOutMessageReceiver.java:40) [:]
at org.apache.axis2.receivers.AbstractMessageReceiver.receive(AbstractMessageReceiver.java:100) [:]
at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:176) [:]
at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:275) [:]
at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:133) [:]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:754) [:1.0.0.Final]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:847) [:1.0.0.Final]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:324) [:6.0.0.Final]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:242) [:6.0.0.Final]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:275) [:6.0.0.Final]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) [:6.0.0.Final]
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:181) [:6.0.0.Final]
at org.jboss.modcluster.catalina.CatalinaContext$RequestListenerValve.event(CatalinaContext.java:285) [:1.1.0.Final]
at org.jboss.modcluster.catalina.CatalinaContext$RequestListenerValve.invoke(CatalinaContext.java:261) [:1.1.0.Final]
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:88) [:6.0.0.Final]
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:100) [:6.0.0.Final]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) [:6.0.0.Final]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) [:6.0.0.Final]
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158) [:6.0.0.Final]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) [:6.0.0.Final]
at org.jboss.web.tomcat.service.request.ActiveRequestResponseCacheValve.invoke(ActiveRequestResponseCacheValve.java:53) [:6.0.0.Final]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:362) [:6.0.0.Final]
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:877) [:6.0.0.Final]
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:654) [:6.0.0.Final]
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:951) [:6.0.0.Final]
at java.lang.Thread.run(Thread.java:662) [:1.6.0_31]
I have read in many posts that including stax api in application lib causes linkage error, here i dont have stax api jar in my application lib folder still its giving linkage error. i am using Java 6 on my server.
Can anyone please help in resolving this error?
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/795289#795289]
Start a new discussion in Beginner's Corner at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
11 years, 10 months
[jBPM] - jBPM 5.4 : Signal Event and VariableName
by wishmaster7
wishmaster7 [https://community.jboss.org/people/wishmaster7] created the discussion
"jBPM 5.4 : Signal Event and VariableName"
To view the discussion, visit: https://community.jboss.org/message/795177#795177
--------------------------------------------------------------
Hi all,
I am a beginner with jBPM and I need some help with the signal event; all I have found in the documentation (and in the web chat) is something like :
VariableName: The name of the variable that will contain the data associated with this event (if any) when this event occurs.
And this doesn't help much...
So I have created a basic example with a start node, then a AND gateway which waits for the signal event. I'm working with jBPM REST webservices; first I call :
POST: http://localhost:8080/gwt-console-server/rs/process/definition/myProcess/...
and in the json return, I get the process instance id (in this example: 57). Then I call :
POST: http://localhost:8080/gwt-console-server/rs/process/tokens/57/transition?...
and this pefectly triggers the signal event. But I want to pass parameters, and I think the "VariableName" of the signal event is suitable for that. So I have the "woId" variable, but its value is always null.
Here is, in my Java application, the code I use to call the POST webservice:
private String requestPostService() throws Exception {
String url =
"http://localhost:8080/gwt-console-server/rs/process/tokens/57/transition?...";
// here is my map with the parameter I want to pass to the jBPM process
List<NameValuePair> formparams = new ArrayList<NameValuePair>();
formparams.add(new BasicNameValuePair("woId", "testValue"));
HttpPost httpPost = new HttpPost(url);
UrlEncodedFormEntity entity = new UrlEncodedFormEntity(formparams, "UTF-8");
httpPost.setEntity(entity);
HttpClient httpClient = new DefaultHttpClient();
HttpResponse response = httpClient.execute(httpPost);
// the getRequestString() method is parsing the response
return this.getRequestString(response);
}
And in attachement, the process BPMN file.
I don't know what is missing; in the console, it's printing:
Init data...
null
"Init data" is the string called in "Init Data" task; null is the value of my variable.
Someone has an idea?
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/795177#795177]
Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
11 years, 10 months
[EJB3] - Obtaining an EJB proxy from a CDI Interceptor
by Paul Robinson
Paul Robinson [https://community.jboss.org/people/paul.robinson] created the discussion
"Obtaining an EJB proxy from a CDI Interceptor"
To view the discussion, visit: https://community.jboss.org/message/795148#795148
--------------------------------------------------------------
Hello,
I have a CDI interceptor that when placed on an EJB method (of a SLSB) enlists the EJB in a protocol for which it will later receive callbacks that enable it to participate in the protocol.
Here's a simplified version of the code:
@ServiceRequest
@Interceptor
public class ServiceRequestInterceptor {
@AroundInvoke
public Object intercept(InvocationContext ic) throws Throwable {
Object targetInstance = ic.getTarget();
//register targetInstance in the protcol
}
}
Reflection is then used to make invocations on 'targetInstance' as the protocol progresses. The problem is that 'targetInstance' is the actual java instance, so invocations bypass the whole EJB stack. I imagine causes problems for instance management as I'm accessing the bean without the EJB container knowing. But, the more immediate problem I'm seeing is that this approach prevents EJB features like CMT from working.
I think the solution to my problem is to somehow lookup the right EJB proxy in the interceptor. However, I'm unsure how to do this as I won't know the details such as the appName or moduleName. The interceptor does have access to the .class of the bean implementation, if this helps?
Any ideas would be much appreciated.
Paul.
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/795148#795148]
Start a new discussion in EJB3 at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
11 years, 10 months
[jBPM] - Re: LDAP UserGroupCallback with bind credentials
by Hung Phan
Hung Phan [https://community.jboss.org/people/phan] created the discussion
"Re: LDAP UserGroupCallback with bind credentials"
To view the discussion, visit: https://community.jboss.org/message/795126#795126
--------------------------------------------------------------
Have you tried using the 'java.naming.security.principal' and 'java.naming.security.credentials' in your properties file? They worked for me (thank you for the hints).
Also, what is the correct configurations to get just the CN for a user's groups (e.g. just 'user', or 'admin') into the task.OrganizationalEntity table? Below is a section of my current configuration, which results ininserting the entire string 'CN=admin,CN=Users,DC=...' as the 'Group' id. Thanks in advance.
-------------
# Filter that will be used to search for user information,
# usually will contain substitution keys {0} to be replaced with parameters
# (mandatory)
ldap.user.filter=(sAMAccountName\={0})
# Attribute name of the user id in Active Directory
ldap.user.attr.id=sAMAccountName
# Filter that will be used to search for group/role information,
# usually will contain substitution keys {0} to be replaced with parameters
# (mandatory)
ldap.role.filter=(sAMAccountName\={0})
# Filter that will be used to search for user group/role membership information,
# usually will contain substitution keys {0} to be replaced with parameters
# (mandatory)
ldap.user.roles.filter=(sAMAccountName\={0})
# Attribute name of the group/role id in Active Directory
# (optional, if not given 'cn' will be used)
ldap.roles.attr.id=memberOf
# User id a DN, instructs the callback to query for user DN
# before searching for roles (optional, default false)
ldap.user.id.dn=true
-------------------
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/795126#795126]
Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
11 years, 10 months