openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Matthieu Riou" <matthieu.r...@gmail.com>
Subject No tx commit when providing ManagedRuntime
Date Mon, 15 Jan 2007 18:35:27 GMT
Hi,

I now have a working setup (at least something that starts) using a
programmaticaly provided datasource and transaction manager. Here is the
code now:

        HashMap propMap = new HashMap();
        propMap.put("openjpa.jdbc.DBDictionary", "
org.apache.openjpa.jdbc.sql.DerbyDictionary");
        propMap.put("openjpa.ManagedRuntime", new TxMgrProvider());
        propMap.put("openjpa.ConnectionFactory", _datasource);
        propMap.put("openjpa.Log", "DefaultLevel=TRACE");
        EntityManagerFactory emf =
Persistence.createEntityManagerFactory("ode-dao",
propMap);
        HashMap propMap2 = new HashMap();
        propMap2.put("openjpa.TransactionMode", "managed");
        EntityManager em = emf.createEntityManager(propMap2);
        _daoCF = new BPELDAOConnectionFactoryImpl(em);

I've tried both with and without the propMap2, in both cases I never get
OpenJPA to commit (and therefore no insert/update/delete) when I commit the
transaction.

Any idea of what could be wrong?

Thanks!

Matthieu

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message