-
1. Re: JPAPlaceholderResolverStrategy issue
swiderski.maciej Mar 25, 2015 12:48 PM (in response to cristian.blanaru)how do you configure that marshaling strategy and entity manager factory?
Could it be that marshaling is done after JPA provider has already processed it's beforeCompletion phases? That is the only idea that comes to my mind which might be causing entries not persisted even though they were properly added to persistence context.
HTH
-
2. Re: JPAPlaceholderResolverStrategy issue
cristian.blanaru Mar 25, 2015 1:45 PM (in response to swiderski.maciej)The marshalling strategy is configured in the kmodule's deployment descriptor
...
<marshalling-strategies>
<marshalling-strategy>
<resolver>reflection</resolver>
<identifier>com.myejb.JPAPlaceholderResolverStrategy</identifier>
<parameters>
<parameter xsi:type="xs:string" xmlns:xs="http://www.w3.org/2001/XMLSchema">entityManagerFactory</parameter>
</parameters>
</marshalling-strategy>
</marshalling-strategies>
....
Attached is the persistence.xml
-
persistence.xml.zip 1.2 KB
-
-
3. Re: JPAPlaceholderResolverStrategy issue
swiderski.maciej Mar 25, 2015 2:08 PM (in response to cristian.blanaru)all looks ok, so the only explanation I can see here is that the pa provider processes all entities from persistence context before the marshaling is invoked. If you could create jira and add a test cases into jbpm-services-ejb-impl (as pull request) with your case that would be great. Feel free to add the fix into JPAPlaceholderResolverStrategy
HTH
-
4. Re: JPAPlaceholderResolverStrategy issue
clp207 May 14, 2015 11:24 AM (in response to swiderski.maciej)Maciej,
How would I add the the default SerializablePlaceholderResolverStrategy into the deployment descriptor after the JPAPlaceholderResolverStrategy?
I've tried this, but it doesn't work
<marshalling-strategy>
<resolver>reflection</resolver>
<identifier>org.drools.core.marshalling.impl.SerializablePlaceholderResolverStrategy</identifier>
<parameters>
<parameter xsi:type="xs:string" xmlns:xs="http://www.w3.org/2001/XMLSchema">objectMarshallingStrategyAcceptor</parameter>
</parameters>
</marshalling-strategy>
Thanks!
-
5. Re: JPAPlaceholderResolverStrategy issue
swiderski.maciej May 20, 2015 2:56 AM (in response to clp207)Chris,
it's there by default added at the end of all possible strategies so there is no need to add it manually
HTH