Originally my application started out using Spring MVC and JDO. The first use of JDO took my application about 5 seconds to get everything set up. Similarily, Spring MVC added around 6 seconds to the cold start
time
Google App Engine Cold Start Guide for Java - 0 views
-
-
If you are not using either JDO or JPA, you can safely delete all related libraries (ones that have JDO, JPA, or Datanucleus in their name) and use the command line tool to upload your app. Deleting these libraries shaves about 400ms off of cold start time.
Parallel Asynchronous Datastore Commands with Twig 1.0 - Google App Engine for Java | G... - 1 views
-
Twig is an alternative to the standard persistence interfaces JDO and JPA, specifically designed to make the most of the underlying datastore's unique features.
-
Twig is the only interface to support direct unowned relationships so your code is not dependent on low-level datastore classes. It is the only interface to support OR queries by merging together multiple queries, sorting them and filtering out duplicates at the lowest level for performance.
-
Async datastore calls are not yet part of the low-level API. Twig uses the underlying Protocol Buffer layer classes to call ApiProxy.makeAsyncCall() instead of makeSyncCall. All the code is open source so you can check out how its done.
Java App Engine Get Auto Generated Key value - Stack Overflow - 0 views
-
I have an Entity with an id type of Long, and the id gets filled in after I call makePersistent(). Here is what the code looks like: GameEntity game = new GameEntity(); log.warning("before makePersistent id is " + game.getId()); pm.makePersistent(game); log.warning("after makePersistent id is " + game.getId()); Here is a snippet of the GameEntity class: @PersistenceCapable(identityType = IdentityType.APPLICATION)public class GameEntity { @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) private Long id; And the output shows what you'd expect: WARNING 6428 - before makePersistent id is nullWARNING 6444 - after makePersistent id is 6 UPDATE: It occurred to me belatedly that you might want an actual Key object. You can create that yourself if you have the id: public Key getKey() { return KeyFactory.createKey(GameEntity.class.getSimpleName(), id);}
1 - 5 of 5
Showing 20▼ items per page