openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pinaki Poddar <ppod...@apache.org>
Subject Re: Lazy initialisation questions
Date Tue, 16 Dec 2008 18:16:43 GMT

Hi,
  1. What is the detachment configuration settings? 
     <property name="openjpa.DetachState" value="?"/>

  2. Does the entities have version field defined?

  3. I do not work on multi-tier/multi-language application development and
hence my statements can be fairly inaccurate. But if you allow a bit of
self-promotion I will suggest a reference. Back in early 2006, just because
of sheer corporate decisions, I had written a 'Sample AJAX application' when
every conference session that had 'AJAX' in its title used to ensure very
high attendance. This 'application' demonstrated how you can detach a
persistent object graph (or rather a configurable sub-graph), transport it
to a remote Web tier where they materialize not as Java objects but as
JavaScript objects, gets modified and merged back to a different persistent
context. The inter-language conversion was handled by DWR (Direct Web
Remoting). 
   A BEA dev2dev blog was posted to explain the bits but that blog does not
exist anymore. However, this sample (it is reasonably documented and comes
with source code) can still (at least since I last looked:) be found in
Weblogic 9.x download as a Sample EJB3/AJAX application. I do not remember
the details anymore but if you can access that application, it may provide
some useful pointers for the problem you are addressing. 

  4. In essence, if (a big if) I have followed the use case you have
described, I will do the following

       a) decide on my detachment strategy (based on the environmental
constraints on the remote tier) and configure OpenJPA accordingly
       b) use fetch graphs to configure detached sub-graph per use case
       c) use an utility (e.g. DWR, JSON etc) for inter-language object
conversion
       d) not attempt to recreate a entity graph by hand
-- 
View this message in context: http://n2.nabble.com/Lazy-initialisation-questions-tp1662940p1664168.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.


Mime
View raw message