-
1. Re: Identify variables, create triples and store them through a custom marshaling strategy
jocelyn.duc Mar 20, 2014 6:23 AM (in response to jocelyn.duc)For example,
If I output objects passing through the acceptor, I have this:
value: krisv type: String value: My comment type: String value: Input type: String value: HR type: String ...
How does the system may know that HR is the actor group, save it and then read it as the actor group? I need a short course about jBPM marshalling and persistence...
-
2. Re: Identify variables, create triples and store them through a custom marshaling strategy
swiderski.maciej Mar 24, 2014 2:57 AM (in response to jocelyn.duc)currently identification is based on types so it's rather difficult to do so on simple types like string. One way you could do is to actually store everything using that strategy which ultimately makes it default one.Other than that you need to use custom types to encapsulate the value so the strategy will have all required information to make a decision on what to do with given variable.
HTH
-
3. Re: Identify variables, create triples and store them through a custom marshaling strategy
jocelyn.duc Mar 24, 2014 3:44 AM (in response to swiderski.maciej)Yes, for now, custom type method works well. Based on your Document example, I have implemented a generic solution for all my custom types. I use RDFBeans, which translate a java object to RDF tree for my external database. To give you more explanations, my boss want me to use only primitive types to make my solution usable by lambda users. It means that if the user want to design a BPM about specific things, he doesn't need to create custom types... IMHO, if you offer the possibility to use custom types, to create them through a user-friendly data modeler, we have to use it and take advantage of all the capacities of the system!
As you say, I think the solution is to encapsulate my outputs in a generic object containing data and descriptions, in an additional step, to be able to clearly identify what is inside. In this case, the end-user will design a user task with primitives strings firstname and lastname variable and tells the system thoses fields are a Person (how? where?) then the RDF marshaller will know this is a Person and will be able to create a correct Person graph. But, once more, someone will have to write how the marshaller should save a Person and any other entity. In all case, an experimented user will have to describe how the RDF marshaller should works.
-
4. Re: Identify variables, create triples and store them through a custom marshaling strategy
jocelyn.duc Mar 24, 2014 7:19 AM (in response to jocelyn.duc)We have just had a meeting. We decided to encapsulate the data to add it the metadata we need for the RDF serialization.
Knowing that we wish to use only the jbpm-console, is it possible to extend it to get form values on submit and put them into an EncapsluatedData object? Where to find the human tasks action controllers?
-
5. Re: Identify variables, create triples and store them through a custom marshaling strategy
swiderski.maciej Mar 25, 2014 2:59 AM (in response to jocelyn.duc)that looks like a perfect fit for transformation of data input and output that was added post 6.0.1 and is currently available in master. That allows you to use various script languages to transform incoming data to different formats. Either by using one of existing one that are based on javax.scripting or creating and registering your own. You might want to look at few examples we have in code base to see if that would fit your need.
- default scripting lang from java 6
Note: tooling support is still missing for it, so manual editing of bpmn2 is required.
HTH
-
6. Re: Identify variables, create triples and store them through a custom marshaling strategy
jocelyn.duc Mar 25, 2014 5:16 AM (in response to swiderski.maciej)Thank you for the tip. I didn't know transformations. But for now, I have to work with 6.0.1.
Working with CustomFieldTypes is possible too, right? I would like to create an EncapsulatedDataCustomFieldType, for my user to be able to set the EncapsulatedData value thank to a standard input field. From what I read, this is a good alternative. Is it a nice way to register a new CustomFieldType? The online documentation describe the implementation (file example) and the usage, but not the installation.
-
7. Re: Re: Identify variables, create triples and store them through a custom marshaling strategy
jocelyn.duc Mar 27, 2014 9:12 AM (in response to jocelyn.duc)Basically a Custom Field Type is a Java class that implements the org.jbpm.formModeler.core.fieldTypes.CustomFieldType interface and is packaged inside inside a jar file that is placed on the Application Server classpath or inside the application War.
Implementing CustomFieldType, done.
But for the installation, is it possible to add it into JBoss AS classpath? With AS 7.1.1, I have to use the modules system, isn't it? I don't know if I do it correctly, but I can't get it working. How to be sure my module is loaded? By the way, I can't see the File Input field (example) in my modeler...