These are chat archives for effektif/effektif
Nice talking to you earlier today!
Hope you can help me with this:
Until now I have been creating flows in the following way, like described in the Tutorial/docs.
`private static Configuration mongoConfiguration = new MongoConfiguration()
private static Configuration configuration = mongoConfiguration;
private static WorkflowEngine engine = configuration.getWorkflowEngine();
Workflow workflow = new Workflow()
<zip define workflow here in Java>
workflow.sourceWorkflowId = "A unique workflow Id";
TriggerInstance trigger = new TriggerInstance().sourceWorkflowId("A unique workflow Id");
On the trigger object I set data that was used in the workflow.
Now I understood the preferred way to deploy/execute flows was via the REST api (ie http://localhost:9999/deploy & /start & /message)
Now I want to convert my Java Workflow into a JSON object that I can post to the rest api /deploy url.
Simply serializing the workflow object to json and posting it to /deploy endpoint does not work, here a bpmn-style json object is expected.
Question 1: Is there a simple way to convert the Workflow object to json? I looked at the com.effektif.server.test.ServerTest.java 'example'. But here the com.effektif.workflow.impl.json.JsonStreamMapper and the com.effektif.server.EffektifJsonProvider are used in a way specific for the Jersey implementation (I prefer using jboss rest-easy) and both these classes are not in the API module but in the effektif-workflow-impl and effektif-server modules.
Question 2: Do you have a document describing the rest api? (and preferably an example)
Question 3: What is the /message api endpoint used for / how is it used? (havent looked too deep into this yet but I'm asking questions now anyway :-))