Looks like it is related to bitronix transaction. during Environment initiation, if I comment out the transaction manager setting statement as below, there will be no NPE. But I not sure if there is transaction control anymore.
EntityManagerFactory emf = Persistence.createEntityManagerFactory( "org.drools.persistence.jpa" );
Environment env = KnowledgeBaseFactory.newEnvironment();
This might be a really stupid idea, but I'm wondering if this isn't an issue with the H2 database -- considering that's it's an in-memory database and not fully 2 phase compliant (I think?).
If you wouldn't mind posting your code, I would actually like to look at this as well! I'm very interested in how transactions/persistence works in jBPM 5.