1

Google App Engine でデータストアを使用しようとしています。オブジェクトを永続化し、ID で取得できます。しかし、私はそれを照会することはできません。

これは私のエンティティです:

package my.company.domain;

import javax.jdo.annotations.IdGeneratorStrategy;
import javax.jdo.annotations.PersistenceCapable;
import javax.jdo.annotations.Persistent;
import javax.jdo.annotations.PrimaryKey;

@PersistenceCapable(detachable="true")
public class User {

    @PrimaryKey
    @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
    long key;   

    @Persistent
    private String name;

    @Persistent
    private String password;

    @Persistent
    private boolean adminPrivileges;

//getters & setters
}

そして私のユニットテスト:

public void persistAndFindUserTest(){

        User user = new User();
        user.setName(johnDoe");
        user.setPassword("password");

        UserService userService = new DefaultUserService();
        user = userService.createUserInDatabase(user);

        User userFromPersistence = userService.getUserById(user.getKey());
        Assert.assertEquals(user.getName(), userFromPersistence.getName());

        Assert.assertNotNull(userService.findUserByName("johnDoe"));
} 

findUserByName は次のように定義されています。

public List<User> findUserByEmail(String email){
        PersistenceManager persistenceManager = PMF.get()
                .getPersistenceManager();

        Query q = persistenceManager.newQuery(User.class);
        q.setFilter("email == emailParam");
        q.declareParameters("String emailParam");
    q.setUnique(false);

        List<User> results = null;
        try {
            results = (List<User>) q.execute(email);
        } finally {
            results = (List<User>)persistenceManager.detachCopyAll(results);
            q.closeAll();
        }
        return results;
    }

次の例外が発生します (行 116 は、結果リストをデタッチしようとする場所です)。

java.lang.NullPointerException
    at com.google.appengine.datanucleus.query.QueryEntityPKFetchFieldManager.fetchLongField(QueryEntityPKFetchFieldManager.java:74)
    at org.datanucleus.identity.IdentityUtils.getApplicationIdentityForResultSetRow(IdentityUtils.java:101)    
    at com.google.appengine.datanucleus.EntityUtils.entityToPojo(EntityUtils.java:1009)
    at com.google.appengine.datanucleus.query.DatastoreQuery$2.apply(DatastoreQuery.java:227)
    at com.google.appengine.datanucleus.query.DatastoreQuery$2.apply(DatastoreQuery.java:224)
    at com.google.appengine.datanucleus.query.LazyResult.resolveNext(LazyResult.java:96)
    at com.google.appengine.datanucleus.query.LazyResult$LazyAbstractListIterator.computeNext(LazyResult.java:229)
    at com.google.appengine.datanucleus.query.AbstractIterator.tryToComputeNext(AbstractIterator.java:131)
    at com.google.appengine.datanucleus.query.AbstractIterator.hasNext(AbstractIterator.java:126)
    at com.google.appengine.datanucleus.query.LazyResult$AbstractListIterator.hasNext(LazyResult.java:183)
    at org.datanucleus.api.jdo.JDOPersistenceManager.detachCopyAll(JDOPersistenceManager.java:1213)
    at ch.mttb.clientmanagement.service.impl.DefaultUserService.findUserByEmail(DefaultUserService.java:116)
    at ch.mttb.clientmanagement.service.test.UserServiceTest.persistUserTest(UserServiceTest.java:44)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:45)
    at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
    at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:42)
    at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
    at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28)
    at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:30)
    at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
    at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:68)
    at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:47)
    at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
    at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
    at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
    at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
    at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:222)
    at org.junit.runners.ParentRunner.run(ParentRunner.java:300)
    at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
    at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)

GAE SDK 1.7.2 の jar を使用しています。datanucleus jar は次のとおりです。

datanucleus-api-jdo-3.1.0-m3.jar datanucleus-api-jpa-3.1.0-m3.jar datanucleus-appengine-2.1.0-final.jar datanucleus-core3.1.0-m5.jar

Enhancedr.log ファイルがまだ空です。Logging を次のように構成しました: put log4j.properites und WEB-INF

log4j.プロパティ:

log4j.appender.A1=org.apache.log4j.ConsoleAppender
log4j.appender.A1.layout=org.apache.log4j.PatternLayout
log4j.appender.A1.layout.ConversionPattern=%d{HH:mm:ss,SSS} %-5p [%c] - %m%n


log4j.category.DataNucleus.JDO=WARN, A1
log4j.category.DataNucleus.Persistence=WARN, A1
log4j.category.DataNucleus.Cache=WARN, A1
log4j.category.DataNucleus.MetaData=WARN, A1
log4j.category.DataNucleus.General=WARN, A1
log4j.category.DataNucleus.Utility=WARN, A1
log4j.category.DataNucleus.Transaction=WARN, A1
log4j.category.DataNucleus.Datastore=WARN, A1
log4j.category.DataNucleus.ClassLoading=WARN, A1
log4j.category.DataNucleus.Plugin=WARN, A1
log4j.category.DataNucleus.ValueGeneration=WARN, A1
log4j.category.DataNucleus.Enhancer=WARN, A1
log4j.category.DataNucleus.SchemaTool=WARN, A1

私は日食ジュノを使用しています。

junit テストを実行したときのログ出力:

18:3811,450 DEBUG [DataNucleus.Plugin] - Plugin Registry "org.datanucleus.plugin.EclipsePluginRegistry" not found. Falling back to DataNucleus registry. Reason : Class "org.eclipse.core.runtime.RegistryFactory" was not found in the CLASSPATH. Please check your specification and your CLASSPATH..
18:3811,452 DEBUG [DataNucleus.Plugin] - Using PluginRegistry org.datanucleus.plugin.NonManagedPluginRegistry
18:3811,464 DEBUG [DataNucleus.Plugin] - Registering bundle org.datanucleus.api.jpa version 3.1.0.m3 at URL file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-api-jpa-3.1.0-m3.jar.
18:3811,471 DEBUG [DataNucleus.Plugin] - Loading extension points from plug-in file jar:file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-api-jpa-3.1.0-m3.jar!/plugin.xml.
18:3811,472 DEBUG [DataNucleus.Plugin] - Loading extensions from plug-in file jar:file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-api-jpa-3.1.0-m3.jar!/plugin.xml.
18:3811,476 DEBUG [DataNucleus.Plugin] - Registering bundle org.datanucleus version 3.1.0.m5 at URL file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-core-3.1.0-m5.jar.
18:3811,506 DEBUG [DataNucleus.Plugin] - Loading extension points from plug-in file jar:file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-core-3.1.0-m5.jar!/plugin.xml.
18:3811,535 DEBUG [DataNucleus.Plugin] - Loading extensions from plug-in file jar:file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-core-3.1.0-m5.jar!/plugin.xml.
18:3811,540 DEBUG [DataNucleus.Plugin] - Registering bundle com.google.appengine.datanucleus version 2.1.0 at URL file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-appengine-2.1.0-final.jar.
18:3811,549 DEBUG [DataNucleus.Plugin] - Loading extension points from plug-in file jar:file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-appengine-2.1.0-final.jar!/plugin.xml.
18:3811,554 DEBUG [DataNucleus.Plugin] - Loading extensions from plug-in file jar:file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-appengine-2.1.0-final.jar!/plugin.xml.
18:3811,558 DEBUG [DataNucleus.Plugin] - Registering bundle org.datanucleus.api.jdo version 3.1.0.m3 at URL file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-api-jdo-3.1.0-m3.jar.
18:3811,564 DEBUG [DataNucleus.Plugin] - Loading extension points from plug-in file jar:file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-api-jdo-3.1.0-m3.jar!/plugin.xml.
18:3811,567 DEBUG [DataNucleus.Plugin] - Loading extensions from plug-in file jar:file:/C:/eclipse/plugins/com.google.appengine.eclipse.sdkbundle_1.7.2.1/appengine-java-sdk-1.7.2.1/lib/opt/user/datanucleus/v2/datanucleus-api-jdo-3.1.0-m3.jar!/plugin.xml.
18:3811,587 INFO  [DataNucleus.Persistence] - Property datanucleus.appengine.singletonPMFForName unknown - will be ignored
18:3811,587 INFO  [DataNucleus.Persistence] - Property datanucleus.appengine.autoCreateDatastoreTxns unknown - will be ignored
18:3811,602 DEBUG [DataNucleus.Persistence] - Java types support initialising ...
18:3811,603 DEBUG [DataNucleus.Persistence] - Java type [B (persistent=true, DFG=true, embedded=true)
18:3811,604 DEBUG [DataNucleus.Persistence] - Java type [C (persistent=true, DFG=true, embedded=true)
18:3811,604 DEBUG [DataNucleus.Persistence] - Java type [D (persistent=true, DFG=true, embedded=true)
18:3811,604 DEBUG [DataNucleus.Persistence] - Java type [F (persistent=true, DFG=true, embedded=true)
18:3811,604 DEBUG [DataNucleus.Persistence] - Java type [I (persistent=true, DFG=true, embedded=true)
18:3811,604 DEBUG [DataNucleus.Persistence] - Java type [J (persistent=true, DFG=true, embedded=true)
18:3811,604 DEBUG [DataNucleus.Persistence] - Java type [S (persistent=true, DFG=true, embedded=true)
18:3811,604 DEBUG [DataNucleus.Persistence] - Java type [Z (persistent=true, DFG=true, embedded=true)
18:3811,605 DEBUG [DataNucleus.Persistence] - Java type [Ljava.lang.Boolean; (persistent=true, DFG=true, embedded=true)

same for many types

18:3811,651 DEBUG [DataNucleus.Persistence] - Java type [Lcom.google.appengine.api.users.User; (persistent=true, DFG=true, embedded=true)

same for typed Collections, Lists and Sets


18:3811,659 DEBUG [DataNucleus.Persistence] - Java types support loaded
18:3811,659 DEBUG [DataNucleus.Persistence] - Type converter support initialising ...
18:3811,660 DEBUG [DataNucleus.Persistence] - Added converter for java.math.BigDecimal<->java.lang.String using org.datanucleus.store.types.converters.BigDecimalStringConverter

lot more converters added...

18:3811,667 DEBUG [DataNucleus.Persistence] - Added converter for java.util.UUID<->java.lang.String using org.datanucleus.store.types.converters.UUIDStringConverter
18:3811,667 DEBUG [DataNucleus.Persistence] - TypeConverter for javax.time.calendar.LocalDate<->java.lang.String ignored since java type not present in CLASSPATH
18:3811,668 DEBUG [DataNucleus.Persistence] - TypeConverter for javax.time.calendar.LocalTime<->java.lang.String ignored since java type not present in CLASSPATH
18:3811,669 DEBUG [DataNucleus.Persistence] - TypeConverter for javax.time.calendar.LocalTime<->java.lang.Long ignored since java type not present in CLASSPATH
18:3811,669 DEBUG [DataNucleus.Persistence] - TypeConverter for javax.time.calendar.LocalDateTime<->java.lang.String ignored since java type not present in CLASSPATH
18:3811,669 DEBUG [DataNucleus.Persistence] - Type converter support loaded
18:3811,670 DEBUG [DataNucleus.MetaData] - MetaDataManager : Input=(XML,Annotations), XML-Validation=false, XML-Suffices=(persistence=*.jdo, orm=orm, query=*.jdoquery), JDO-listener=true
18:3811,670 DEBUG [DataNucleus.MetaData] - Registering listener for metadata initialisation
18:3811,674 DEBUG [DataNucleus.MetaData] - Listener found initialisation for persistable class my.company.domain.User
18:3811,676 DEBUG [DataNucleus.MetaData] - MetaData of type "jdo" for class "my.company.domain.User" NOT found at /META-INF/package.jdo

same for many different locations

18:3811,724 DEBUG [DataNucleus.MetaData] - Class "my.company.domain.User" has been specified with JDO annotations so using those.
18:3811,743 DEBUG [DataNucleus.MetaData] - Populating Meta-Data for class my.company.domain.User.
18:3811,743 DEBUG [DataNucleus.MetaData] - MetaData of type "orm" for class "my.company.domain.User" NOT found at /META-INF/package.orm

same for many different locations

18:3811,755 DEBUG [DataNucleus.Datastore] - Creating StoreManager for datastore
18:3811,772 DEBUG [DataNucleus.Connection] - Registered transactional connection factory under name "appengine"
18:3811,773 DEBUG [DataNucleus.Connection] - Registered nontransactional connection factory under name "appengine-nontx"
18:3811,804 DEBUG [DataNucleus.Datastore] - ======================= Datastore =========================
18:3811,805 DEBUG [DataNucleus.Datastore] - StoreManager : "appengine" (com.google.appengine.datanucleus.DatastoreManager)
18:3811,805 DEBUG [DataNucleus.Datastore] - AutoStart : mechanism=None, mode=Quiet
18:3811,805 DEBUG [DataNucleus.Datastore] - Datastore : read-write
18:3811,805 DEBUG [DataNucleus.Datastore] - Schema Control : AutoCreate(None), Validate(None)
18:3811,805 DEBUG [DataNucleus.Datastore] - Query Languages : [JDOQL, JPQL]
18:3811,805 DEBUG [DataNucleus.Datastore] - Queries : Timeout=0
18:3811,805 DEBUG [DataNucleus.Datastore] - ===========================================================
18:3811,805 DEBUG [DataNucleus.Datastore] - StorageVersion : READ_OWNED_CHILD_KEYS_FROM_PARENTS
18:3811,805 DEBUG [DataNucleus.Datastore] - Default Relation Mode : owned
18:3811,805 DEBUG [DataNucleus.Datastore] - ===========================================================
18:3811,819 DEBUG [DataNucleus.Datastore] - StoreManager now created
18:3811,819 DEBUG [DataNucleus.Persistence] - ================= Persistence Configuration ===============
18:3811,819 DEBUG [DataNucleus.Persistence] - DataNucleus Persistence Factory - Vendor: "DataNucleus"  Version: "3.1.0.m5"
18:3811,819 DEBUG [DataNucleus.Persistence] - DataNucleus Persistence Factory initialised for datastore URL="appengine" driver="" userName=""
18:3811,819 DEBUG [DataNucleus.Persistence] - JDK : 1.7.0_05 on Windows 7
18:3811,819 DEBUG [DataNucleus.Persistence] - Persistence API : JDO
18:3811,819 DEBUG [DataNucleus.Persistence] - Plugin Registry : org.datanucleus.plugin.NonManagedPluginRegistry
18:3811,820 DEBUG [DataNucleus.Persistence] - Standard Options : pm-singlethreaded, retain-values, nontransactional-read, nontransactional-write, serverTimeZone=UTC
18:3811,820 DEBUG [DataNucleus.Persistence] - Persistence Options : reachability-at-commit managed-relations(checked) deletion-policy=JDO2
18:3811,820 DEBUG [DataNucleus.Persistence] - Transactions : type=RESOURCE_LOCAL mode=datastore isolation=read-committed
18:3811,820 DEBUG [DataNucleus.Persistence] - Value Generation : txn-isolation=read-committed connection=New
18:3811,820 DEBUG [DataNucleus.Persistence] - ClassLoading : jdo
18:3811,820 DEBUG [DataNucleus.Persistence] - Cache : Level1 (soft), Level2 (soft, mode=UNSPECIFIED), QueryResults (soft), Collections/Maps 
18:3811,820 DEBUG [DataNucleus.Persistence] - ===========================================================
18:3811,823 DEBUG [DataNucleus.Cache] - Level 2 Cache of type "soft" initialised
18:3811,849 DEBUG [DataNucleus.Persistence] - Implementation creator not configured. Due to that, support for 'persistent interfaces' ("PersistenceManager.newInstance()") was disabled!
18:3811,851 DEBUG [DataNucleus.Cache] - Level 1 Cache of type "soft" initialised
18:3811,855 DEBUG [DataNucleus.Persistence] - Object Manager "org.datanucleus.ObjectManagerImpl@3e5b3b80" opened for datastore "com.google.appengine.datanucleus.DatastoreManager@579f707b" with txn="org.datanucleus.TransactionImpl@2491c82e"
18:3811,859 DEBUG [DataNucleus.MetaData] - Initialising Meta-Data for class my.company.domain.User.
18:3811,860 DEBUG [DataNucleus.Persistence] - Making object persistent : "my.company.domain.User@78871dc5"
18:3811,882 INFO  [DataNucleus.MetaData] - Performing appengine-specific metadata validation for my.company.domain.User
18:3811,883 INFO  [DataNucleus.MetaData] - Finished performing appengine-specific metadata validation for my.company.domain.User
18:3811,904 DEBUG [DataNucleus.Persistence] - Managing Persistence of Class : my.company.domain.User [Table : my.company.domain.User, InheritanceStrategy : new-table]
18:3811,918 DEBUG [DataNucleus.Connection] - Created ManagedConnection using DatastoreService = com.google.appengine.api.datastore.DatastoreServiceImpl@79e479a3
18:3811,919 DEBUG [DataNucleus.Connection] - Connection added to the pool : com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl$DatastoreManagedConnection@7303d690 for key=org.datanucleus.ObjectManagerImpl@3e5b3b80 in factory=ConnectionFactory:nontx[com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl@fbc2ee]
18:3811,921 DEBUG [DataNucleus.Datastore.Native] - Putting entity of kind User with key User(no-id-yet) as {tenantId[0], password[password], name[johnDoe], adminPrivileges[false], key[0], }
Okt 11, 2012 6:38:11 PM com.google.appengine.api.datastore.dev.LocalDatastoreService init
INFO: Local Datastore initialized: 
    Type: Master/Slave
    Storage: In-memory
18:3812,064 DEBUG [DataNucleus.Cache] - Object "my.company.domain.User@78871dc5" (id="my.company.domain.User:1") added to Level 1 cache (loadedFlags="[YYYYY]")
18:3812,064 DEBUG [DataNucleus.Connection] - Connection found in the pool : com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl$DatastoreManagedConnection@7303d690 for key=org.datanucleus.ObjectManagerImpl@3e5b3b80 in factory=ConnectionFactory:nontx[com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl@fbc2ee]
18:3812,064 DEBUG [DataNucleus.Persistence] - ObjectManager.internalFlush() process started using ordered flush - 1 dirty objects
18:3812,066 DEBUG [DataNucleus.Cache] - Query Cache of type "org.datanucleus.query.cache.SoftQueryCompilationCache" initialised
18:3812,067 DEBUG [DataNucleus.Cache] - Query Cache of type "org.datanucleus.store.query.cache.SoftQueryDatastoreCompilationCache" initialised
18:3812,068 DEBUG [DataNucleus.Cache] - Query Cache of type "org.datanucleus.store.query.cache.SoftQueryResultsCache" initialised
18:3812,068 DEBUG [DataNucleus.Persistence] - ObjectManager.internalFlush() process finished
18:3812,070 DEBUG [DataNucleus.Cache] - Object "my.company.domain.User@78871dc5" (id="1") added to Level 2 cache (fields="[0, 1, 2, 3, 4]", version="")
18:3812,070 DEBUG [DataNucleus.Lifecycle] - Object "my.company.domain.User@78871dc5" (id="my.company.domain.User:1") has a lifecycle change : "P_NEW"->"P_NONTRANS"
18:3812,070 DEBUG [DataNucleus.Transaction] - Object "my.company.domain.User@78871dc5" (id="my.company.domain.User:1") being evicted from transactional cache
18:3812,071 DEBUG [DataNucleus.Persistence] - Detaching copy of object : "my.company.domain.User@78871dc5" (depth=0) - will be "my.company.domain.User@43ae24e3"
18:3812,073 DEBUG [DataNucleus.Connection] - Connection found in the pool : com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl$DatastoreManagedConnection@7303d690 for key=org.datanucleus.ObjectManagerImpl@3e5b3b80 in factory=ConnectionFactory:nontx[com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl@fbc2ee] but owner object closing so closing connection
18:3812,073 DEBUG [DataNucleus.Connection] - Connection removed from the pool : com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl$DatastoreManagedConnection@7303d690 for key=org.datanucleus.ObjectManagerImpl@3e5b3b80 in factory=ConnectionFactory:nontx[com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl@fbc2ee]
18:3812,073 DEBUG [DataNucleus.Persistence] - Disconnecting my.company.domain.User@78871dc5 from StateManager[pc=my.company.domain.User@78871dc5, lifecycle=P_NONTRANS]
18:3812,073 DEBUG [DataNucleus.Cache] - Object with id="my.company.domain.User:1" being removed from Level 1 cache [current cache size = 1]
18:3812,073 DEBUG [DataNucleus.Cache] - Level 1 Cache cleared
18:3812,074 DEBUG [DataNucleus.Persistence] - Object Manager "org.datanucleus.ObjectManagerImpl@3e5b3b80" closed
18:3812,075 DEBUG [DataNucleus.Cache] - Level 1 Cache of type "soft" initialised
18:3812,075 DEBUG [DataNucleus.Persistence] - Object Manager "org.datanucleus.ObjectManagerImpl@1f6aa236" opened for datastore "com.google.appengine.datanucleus.DatastoreManager@579f707b" with txn="org.datanucleus.TransactionImpl@11bf9757"
18:3812,077 DEBUG [DataNucleus.Cache] - Object with id "my.company.domain.User:1" not found in Level 1 cache [cache size = 0]
18:3812,077 DEBUG [DataNucleus.Cache] - Object "my.company.domain.User@6ccc45d2" (id="my.company.domain.User:1") added to Level 1 cache (loadedFlags="[NNYNN]")
18:3812,079 DEBUG [DataNucleus.Cache] - Object with id="my.company.domain.User:1" taken from Level 2 cache (fields="[0, 1, 2, 3, 4]", version="") - represented as "my.company.domain.User@6ccc45d2"
18:3812,079 DEBUG [DataNucleus.Lifecycle] - Object "my.company.domain.User@6ccc45d2" (id="my.company.domain.User:1") has a lifecycle change : "P_CLEAN"->"P_NONTRANS"
18:3812,079 DEBUG [DataNucleus.Transaction] - Object "my.company.domain.User@6ccc45d2" (id="my.company.domain.User:1") being evicted from transactional cache
18:3812,079 DEBUG [DataNucleus.Transaction] - Object "my.company.domain.User@6ccc45d2" (id="my.company.domain.User:1") is not transactional
18:3812,079 DEBUG [DataNucleus.Connection] - Created ManagedConnection using DatastoreService = com.google.appengine.api.datastore.DatastoreServiceImpl@18d1287b
18:3812,079 DEBUG [DataNucleus.Connection] - Connection added to the pool : com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl$DatastoreManagedConnection@4bb8aff7 for key=org.datanucleus.ObjectManagerImpl@1f6aa236 in factory=ConnectionFactory:nontx[com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl@fbc2ee]
18:3812,080 DEBUG [DataNucleus.Datastore.Native] - Getting entity of kind User with key User(1)
18:3812,088 DEBUG [DataNucleus.Persistence] - Detaching copy of object : "my.company.domain.User@6ccc45d2" (depth=0) - will be "my.company.domain.User@13997783"
18:3812,088 DEBUG [DataNucleus.Connection] - Connection found in the pool : com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl$DatastoreManagedConnection@4bb8aff7 for key=org.datanucleus.ObjectManagerImpl@1f6aa236 in factory=ConnectionFactory:nontx[com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl@fbc2ee] but owner object closing so closing connection
18:3812,088 DEBUG [DataNucleus.Connection] - Connection removed from the pool : com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl$DatastoreManagedConnection@4bb8aff7 for key=org.datanucleus.ObjectManagerImpl@1f6aa236 in factory=ConnectionFactory:nontx[com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl@fbc2ee]
18:3812,088 DEBUG [DataNucleus.Persistence] - Disconnecting my.company.domain.User@6ccc45d2 from StateManager[pc=my.company.domain.User@6ccc45d2, lifecycle=P_NONTRANS]
18:3812,088 DEBUG [DataNucleus.Cache] - Object with id="my.company.domain.User:1" being removed from Level 1 cache [current cache size = 1]
18:3812,088 DEBUG [DataNucleus.Cache] - Level 1 Cache cleared
18:3812,089 DEBUG [DataNucleus.Persistence] - Object Manager "org.datanucleus.ObjectManagerImpl@1f6aa236" closed
18:3812,090 DEBUG [DataNucleus.Cache] - Level 1 Cache of type "soft" initialised
18:3812,090 DEBUG [DataNucleus.Persistence] - Object Manager "org.datanucleus.ObjectManagerImpl@5244c8cc" opened for datastore "com.google.appengine.datanucleus.DatastoreManager@579f707b" with txn="org.datanucleus.TransactionImpl@21daf346"
18:3812,107 DEBUG [DataNucleus.Query] - JDOQL Query : Compiling "SELECT UNIQUE FROM my.company.domain.User WHERE name == nameParam PARAMETERS String nameParam"
18:3812,115 DEBUG [DataNucleus.General] - Class String was resolved to be java.lang.String. It wasnt defined fully-qualified so had to be looked up; you can avoid the lookup (and improve performance) by fully-qualifying the class in the query.
18:3812,122 DEBUG [DataNucleus.Query] - JDOQL Query : Compile Time = 15 ms
18:3812,123 DEBUG [DataNucleus.Query] - QueryCompilation:
  [filter:DyadicExpression{PrimaryExpression{name}  =  ParameterExpression{nameParam}}]
  [symbols: nameParam type=java.lang.String, this type=my.company.domain.User]
18:3812,123 DEBUG [DataNucleus.Query] - JDOQL Query : Executing "SELECT UNIQUE FROM my.company.domain.User WHERE name == nameParam PARAMETERS String nameParam" ...
18:3812,125 DEBUG [DataNucleus.Query] - Query compiled as : Kind=my.company.domain.User Filter : name=johnDoe
18:3812,130 DEBUG [DataNucleus.Datastore.Native] - Executing query in datastore for SELECT UNIQUE FROM my.company.domain.User WHERE name == nameParam PARAMETERS String nameParam
18:3812,146 DEBUG [DataNucleus.Connection] - Created ManagedConnection using DatastoreService = com.google.appengine.api.datastore.DatastoreServiceImpl@3e36cb
18:3812,146 DEBUG [DataNucleus.Connection] - Connection added to the pool : com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl$DatastoreManagedConnection@747f498c for key=org.datanucleus.ObjectManagerImpl@5244c8cc in factory=ConnectionFactory:nontx[com.google.appengine.datanucleus.DatastoreConnectionFactoryImpl@fbc2ee]
18:3812,146 DEBUG [DataNucleus.Query] - JDOQL Query : Execution Time = 23 ms

(いくつかの重複行を削除しました)

敬具、マイケル

4

0 に答える 0