Where do you run this - in an application server?the null pointers are probably caused by transaction synchronization that disconnects process instance from the the session. What you could try it to manage your transaction in the async thread, meaning that you control start and commit of the transaction so all the work done by jbpm will join that single transaction.
Would be good if you could provide some tests/simple app that illustrates this so I could give a try to look into what is going on there. I believe this is kind of continuation of the other threads about multiple sessions managements, right?
HTH