-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"Couldn't find process instance" while using async communication #51
Comments
ashulinskiy
changed the title
"Couldn't find process instance" whe using async communication
"Couldn't find process instance" while using async communication
Apr 26, 2019
May I know the versions of camel, camunda, spring you are using. I am using current versions of all the dependencies, facing issue while server starts up. Please help!!! |
It's been a while but I believe I have found the branch where that investigation happened. Here's the POM with the versions we used back then, has the versions. We ended up not using this approach so no further insight sorry. `
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi folks,
Another issue I could use some assistance with please.
I have a BPMN which uses the Camunda-Camel library to communicate to a third party service through Kafka, i.e.:
That task is the fist one in the BPMN process which may be important.
The BPMN Process Instance ID is used for the correlation.
The routing sometime breaks with the following error:
The BPMN:
<?xml version="1.0" encoding="UTF-8"?> <bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" id="Definitions_0wxf2ek" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="2.2.4"> <bpmn:message id="Message_1buba0w" name="camel.answer" /> <bpmn:message id="Message_19viyxu" name="camel.answer" /> <bpmn:process id="camel_asynch" name="Camel async" isExecutable="true"> <bpmn:endEvent id="EndEvent_1egevrf"> <bpmn:incoming>SequenceFlow_0aodgcz</bpmn:incoming> </bpmn:endEvent> <bpmn:sendTask id="SendTask_1ouqvcf" name="Call async service" camunda:expression="#{camel.sendTo('direct:asyncService')}" camunda:resultVariable="aggregateData"> <bpmn:incoming>SequenceFlow_1yw1ho6</bpmn:incoming> <bpmn:outgoing>SequenceFlow_1i1ujc8</bpmn:outgoing> </bpmn:sendTask> <bpmn:sequenceFlow id="SequenceFlow_0aodgcz" sourceRef="IntermediateCatchEvent_133vikc" targetRef="EndEvent_1egevrf" /> <bpmn:sequenceFlow id="SequenceFlow_1yw1ho6" sourceRef="StartEvent_1cmiw6j" targetRef="SendTask_1ouqvcf" /> <bpmn:intermediateCatchEvent id="IntermediateCatchEvent_133vikc" name="message 'answer' received"> <bpmn:incoming>SequenceFlow_1i1ujc8</bpmn:incoming> <bpmn:outgoing>SequenceFlow_0aodgcz</bpmn:outgoing> <bpmn:messageEventDefinition id="MessageEventDefinition_0anjhqa" messageRef="Message_0u86xqd" /> </bpmn:intermediateCatchEvent> <bpmn:sequenceFlow id="SequenceFlow_1i1ujc8" sourceRef="SendTask_1ouqvcf" targetRef="IntermediateCatchEvent_133vikc" /> <bpmn:startEvent id="StartEvent_1cmiw6j"> <bpmn:outgoing>SequenceFlow_1yw1ho6</bpmn:outgoing> </bpmn:startEvent> </bpmn:process> <bpmn:message id="Message_0u86xqd" name="camel.answer" /> <bpmndi:BPMNDiagram id="BPMNDiagram_1"> <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="camel_asynch"> <bpmndi:BPMNShape id="EndEvent_1egevrf_di" bpmnElement="EndEvent_1egevrf"> <dc:Bounds x="848" y="88" width="36" height="36" /> </bpmndi:BPMNShape> <bpmndi:BPMNShape id="SendTask_1ouqvcf_di" bpmnElement="SendTask_1ouqvcf"> <dc:Bounds x="380" y="66" width="100" height="80" /> </bpmndi:BPMNShape> <bpmndi:BPMNEdge id="SequenceFlow_0aodgcz_di" bpmnElement="SequenceFlow_0aodgcz"> <di:waypoint x="748" y="106" /> <di:waypoint x="848" y="106" /> </bpmndi:BPMNEdge> <bpmndi:BPMNEdge id="SequenceFlow_1yw1ho6_di" bpmnElement="SequenceFlow_1yw1ho6"> <di:waypoint x="101" y="106" /> <di:waypoint x="380" y="106" /> </bpmndi:BPMNEdge> <bpmndi:BPMNShape id="IntermediateCatchEvent_133vikc_di" bpmnElement="IntermediateCatchEvent_133vikc"> <dc:Bounds x="712" y="88" width="36" height="36" /> <bpmndi:BPMNLabel> <dc:Bounds x="687" y="131" width="88" height="27" /> </bpmndi:BPMNLabel> </bpmndi:BPMNShape> <bpmndi:BPMNEdge id="SequenceFlow_1i1ujc8_di" bpmnElement="SequenceFlow_1i1ujc8"> <di:waypoint x="480" y="106" /> <di:waypoint x="712" y="106" /> </bpmndi:BPMNEdge> <bpmndi:BPMNShape id="StartEvent_1cmiw6j_di" bpmnElement="StartEvent_1cmiw6j"> <dc:Bounds x="65" y="88" width="36" height="36" /> </bpmndi:BPMNShape> </bpmndi:BPMNPlane> </bpmndi:BPMNDiagram> </bpmn:definitions>
The Camel routes:
As far as I understand there's a race condition between the thread in the Camunda process that sends the outgoing Kafka message and the thread that reads the Kafka message and uses the Process Instance ID to find the process to forward the message to.
I.e. when the correlation is done in the second thread the process hasn'd been committed to the DB in the first thread.
Does this theory sound right?
If it doesn't what else could be the problem
Any advice how to fix the issue?
Any help is greatly appreciated!
Thanks,
Andrey.
The text was updated successfully, but these errors were encountered: