Let me know if it's possible to use @CreateProcess in @Stateless Bean which persist an Entity.
I'm little bit confused about that.
I found solution :
It's definitly possible to @CreateProcess and persist Object with same transaction in a Stateless bean.
What I did :
Add in components.xml
Get entityManager this way in you Stateless Bean :
@PersistenceContext EntityManager entityManager;
I supposed problem was about EJB transaction. Please if someone (Gavin ;) ?) can explain me more...
To persist it works but if in the same bean I would like to request database, I always get no result...
For the first post this is my exception received in my callback :
... java.lang.IllegalStateException Transaction begin not detected try installing transaction ejb-transaction in components.xml ...
in components.xml and
@In EntityManager entityManager;
it's works pretty well calling by WebRemote.