[jBPM Users] - Re: [jBPM4] final state when async node is used
by ouaibsky
The pb is not on getting a reference on processinstance.
The pb is the final state value is not "complete".
It's a pb because depending of continue mode, you do not have the same final result, and it means you'll have to know the worlflow containe to make some test.
ex: just add the last assertEquals on provides AsynActivityTest:
public void testEndStateCompleted() throws Exception {
| ProcessInstance processInstance = executionService
| .startProcessInstanceByKey("helloworld");
| String pid = processInstance.getId();
| System.out.println(processInstance.getState());
| Thread.sleep(500);
|
| Job job = managementService.createJobQuery()
| .processInstanceId(pid)
| .uniqueResult();
| managementService.executeJob(job.getId());
|
| //processInstance = executionService.signalExecutionById(pid, "toHello3");
| Thread.sleep(500);
| assertEquals("completed", processInstance.getState());
| assertTrue(processInstance.isEnded());
| }
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4254798#4254798
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4254798
15 years, 4 months
[JBoss Remoting Users] - Disable Weak Ciphers for PCI-DSS
by sunilbabu
We have to disable the weak ciphers in Jboss-4.2.3.GA (ejb3 application) for pci compliance. Can someone help me with the configuration or point me to a document that explain how to disable ciphers.
Following is current connector
<mbean code="org.jboss.remoting.transport.Connector"
| name="jboss.remoting:type=Connector,transport=socket3843,handler=ejb3">
| <depends>jboss.aop:service=AspectDeployer</depends>
| <attribute name="Configuration">
|
| <config>
|
| <invoker transport="sslsocket">
| <attribute name="serverSocketFactory">
| jboss.remoting:service=ServerSocketFactory,type=SSL
| </attribute>
| <attribute name="serverBindAddress">${jboss.bind.address}</attribute>
| <attribute name="serverBindPort">3843</attribute>
| <attribute name="timeout">120000</attribute>
| </invoker>
|
| <handlers>
| <handler subsystem="AOP">org.jboss.aspects.remoting.AOPRemotingInvocationHandler</handler>
| </handlers>
|
| </config>
| </attribute>
| </mbean>
I also tried with org.jboss.security.ssl.DomainServerSocketFactory and CipherSuites but it did not disable any ciphers.
<mbean code="org.jboss.remoting.transport.Connector"
| name="jboss.remoting:type=Connector,transport=socket3843,handler=ejb3">
| <depends>jboss.aop:service=AspectDeployer</depends>
| <attribute name="Configuration">
|
| <config>
|
| <invoker transport="sslsocket">
| <attribute name="serverSocketFactoryBean"
| | attributeClass="org.jboss.security.ssl.DomainServerSocketFactory"
| | serialDataType="javaBean">
| | <property name="CipherSuites">TLS_DHE_DSS_WITH_AES_128_CBC_SHA</property>
| | </attribute>
| <attribute name="serverBindAddress">${jboss.bind.address}</attribute>
| <attribute name="serverBindPort">3843</attribute>
| <attribute name="timeout">120000</attribute>
| </invoker>
|
| <handlers>
| <handler subsystem="AOP">org.jboss.aspects.remoting.AOPRemotingInvocationHandler</handler>
| </handlers>
|
| </config>
| </attribute>
| <!--property name="ciphers">TLS_DHE_DSS_WITH_AES_128_CBC_SHA</property-->
| </mbean>
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4254795#4254795
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4254795
15 years, 4 months
[jBPM Users] - Re: workflow design about wait states
by mmusaji
This was my original problem... in real world I wont know how long to sleep for. I need to read the objects back but only once they have all been updated after a certain amount of time (which could be 2 seconds or 20 seconds).
When I use take("join"), I get org.jbpm.api.JbpmException: there is no transition join in activity(validate red request). But there is.
I use takeDefaultTransition() (no sleep in my unit test) I get StaleObjectStateException because my unit test and my workflow are out of sync. This was pointed out my JBarrez in one of my previous posts. The sleep in my unit test solved this problem.
If I don't use continue="exclusive" in the join, then my workflow doesn't continue past the join... just stops.
Do you know how the waitForSignal() and takeDefaultTransition() methods are affected (if at all) when used async? Using them normally like in the examples they work fine.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4254794#4254794
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4254794
15 years, 4 months
[JBoss Microcontainer Users] - Using JBoss Microcontainer for JUnit Tests
by tbar0711
Hello,
I'd like to use the JBoss Microcontainer for JUnit Tests of Session Beans without a running JBoss 4.2.3. I read a lot about this. But I still don't know what exactly I have to download and where. There are different projects:
⢠aop-mc-int - the aop integration
⢠classloader - new classloader model, prepared to handle OSGi CL style
⢠container - general metadata utilities, and virtual file system usuable across projects
⢠dependency - a generic dependency state machine
⢠deployers - the virtual deployment framework (VDF) spi and abstractions.
⢠guice-int - guice integration
⢠kernel - the microcontainer adding xml deployment and "javabeans" to the above two projects
⢠managed
⢠metatype
⢠osgi-int - osgi integration
⢠reliance-identity - define identity as a MC POJO service
⢠reliance-rules - define your dependencies with Drools
⢠reliance-jbpm - define your dependencies with jBPM
⢠spring-int - spring integration
But what of them do I need and how I have to configure it?
Here is an example for one of my Testclasses:
| package de.myapplication.business.SomethingDaoImplTest;
|
| import junit.framework.*;ork.TestCase;
|
| import org.apache.log4j.Level;
| import org.apache.log4j.Logger;
|
| import de.myapplication.exception.PersistenceException;
| import de.myapplication.persistence.Something;
| import de.myapplication.persistence.SomethingPK;
| import de.myapplication.session.persistence.dao.LocalStatelessAccessor;
| import de.myapplication.session.persistence.dao.interfaces.SomethingDAO;
|
| public class SomethingDaoImplTest extends TestCase {
|
| private static final Logger LOGGER = Logger
| .getLogger(SomethingDaoImplTest.class.getName());
|
|
| public void testLoad() throws PersistenceException {
|
| // Testdaten
| String somethingnr = "12345566";
| String sap_system = "asdf2";
| String sap_mandant = "000";
| String sprache = "DE";
|
| Something something = null;
|
| LOGGER
| .log(Level.INFO,
| "***** SomethingDaoImplTest: testLoad() *****");
|
| SomethingDAO somethingDAO = LocalStatelessAccessor
| .provideBean(SomethingDAO.class);
| something = somethingDAO.load(new SomethingPK(somethingnr, sap_system,
| sap_mandant), sprache);
|
| LOGGER.log(Level.INFO, "S_nr: "
| + something.getId().getSomethingnr());
|
| if (something.getId().equals(
| new SomethingPK(somethingnr, sap_system, sap_mandant))) {
| assertTrue("Object gleich", true);
| } else {
| assertTrue("Object nicht gleich", false);
| }
| }
|
| public void testLoadSomethingTexte() throws PersistenceException {
|
| String somethingnr = "12345566";
| String sap_system = "asdf44";
| String sap_mandant = "000";
| String sprache = "DE";
|
| Something something = null;
|
| LOGGER.log(Level.INFO,
| "***** SomethingDaoImplTest: testLoadSomethingTexte() *****");
|
| SomethingDAO somethingDAO = LocalStatelessAccessor
| .provideBean(SomethingDAO.class);
| something = SomethingDAO.load(new SomethingPK(somethingnr, sap_system,
| sap_mandant), sprache);
|
| LOGGER.log(Level.INFO, "S_nr: "
| + something.getId().getSomethingnr());
|
| assertEquals(sprache, something.getSomethingText().getId().getSprache());
|
| }
|
| }
SomethingDaoImpl is a Session Bean which implements the interface SomethingDAO. The LocalStatelessAccessor handles the JNDI Lookup.
Thanks in advance.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4254793#4254793
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4254793
15 years, 4 months