cayenne-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nishant Neeraj <nishant.has.a.quest...@gmail.com>
Subject Upgrading 3.0 to 3.1
Date Sat, 12 Feb 2011 12:45:09 GMT
Hi,


I have been trying to upgrade Cayenne from v3.0 to v3.1. I have read the
changes in Upgrade.txt bundled with the modeler download.

I have used DataContext pretty extensively. In fact, I have a singleton for
creating DataContext. Now, with new changes, it seems to me that DataContext
has been eliminated and advised to use ObjectContext using
ServerRuntime.getContext(...) instead. So, now I have thousands of places
where I have done MySingleton.getDataContext().commitChanges() needed to be
changed. (which I will do)

I wanted to confirm that going forward, I will need to replace

      DataContext.createDataContext()

with

      ServerRuntime cayenneRuntime = new
ServerRuntime("cayenne-edushare.xml");
      cayenneRuntime.getContext()

Or, am I missing something?

Thanks
Nishant

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