Note that there are some explanatory texts on larger screens.

plurals
  1. POForce JDO full initialization (with datanucleus lib)
    primarykey
    data
    text
    <p>I am working on warmup request to minimize my requests latency: <a href="https://developers.google.com/appengine/docs/java/config/appconfig#Warmup_Requests" rel="nofollow">https://developers.google.com/appengine/docs/java/config/appconfig#Warmup_Requests</a></p> <p>During that initialization I perform:</p> <pre><code>PersistenceManager pm = PMF.get().getPersistenceManager(); </code></pre> <p>.. but from the logs I see it doesn't parse all the .jdo files where the class metadata are stored. They are parsed only the first time I call this function "getObjectById" (for example) ..</p> <p>Is it possible to force datanucleus to fully read all the metadata in order to be completely ready when the first getObjectById hits the PersistenceManager?</p> <p>Thank you, Michele</p> <p>============================================================================== UPDATE: I tried with this persistence.xml file:</p> <pre><code>&lt;persistence-unit name="my-transaction"&gt; &lt;mapping-file&gt;&lt;path-to-first-jdo-file&gt;&lt;/mapping-file&gt; &lt;mapping-file&gt;&lt;path-to-second-jdo-file&gt;&lt;/mapping-file&gt; &lt;mapping-file&gt;&lt;path-to-third-jdo-file&gt;&lt;/mapping-file&gt; &lt;properties&gt; &lt;property name="datanucleus.NontransactionalRead" value="true"/&gt; &lt;property name="datanucleus.NontransactionalWrite" value="true"/&gt; &lt;property name="datanucleus.ConnectionURL" value="appengine"/&gt; &lt;/properties&gt; &lt;/persistence-unit&gt; </code></pre> <p>that is associated with jdoconfig.xml:</p> <pre><code>&lt;persistence-manager-factory name="my-transaction"&gt; &lt;property name="javax.jdo.PersistenceManagerFactoryClass" value="org.datanucleus.store.appengine.jdo.DatastoreJDOPersistenceManagerFactory" /&gt; &lt;property name="javax.jdo.option.ConnectionURL" value="appengine" /&gt; &lt;property name="javax.jdo.option.NontransactionalRead" value="true" /&gt; &lt;property name="javax.jdo.option.NontransactionalWrite" value="true" /&gt; &lt;property name="javax.jdo.option.RetainValues" value="true" /&gt; &lt;property name="datanucleus.appengine.autoCreateDatastoreTxns" value="true" /&gt; &lt;property name="datanucleus.appengine.allowMultipleRelationsOfSameType" value="true" /&gt; &lt;property name="datanucleus.appengine.datastoreReadConsistency" value="STRONG" /&gt; &lt;property name="datanucleus.appengine.ignorableMetaDataBehavior" value="ERROR" /&gt; &lt;property name="javax.jdo.option.Multithreaded" value="true"/&gt; &lt;property name="javax.jdo.option.Optimistic" value="false" /&gt; &lt;/persistence-manager-factory&gt; </code></pre> <p></p> <p>.. but I continue to see in the logs the previuos behaviour. During loading request:</p> <pre><code>org.datanucleus.store.types.TypeManager addJavaType: Adding support for Java type &lt;class&gt; </code></pre> <p>.. and during the first request that really needs a class mapping (getObjectById for example):</p> <pre><code>org.datanucleus.metadata.xml.MetaDataParser parseMetaDataStream: Parsing MetaData file &lt;class&gt;.jdo </code></pre> <p>So the first request that retrieves the object is longer than the following ones because it needs to parse the XML file. What's wrong?</p> <p>I am using datanucleus 1.1.5</p> <p>Thank you</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload