Well, I still don't understand what you are trying to achieve? What do you want to query?
To create a Query using JPA, you must create an EntityManager from one of the persistence units you have in persistence.xml.
EntityManagerFactory emf = Persistence.createEntityManagerFactory("org.jbpm.persistence.jpa");
and then create an entity manager that will let you create a query.
But again, it would be good to know what you are trying to do in order to help you.
Thanks
Demian