You'll need to profile two separate things:

1) Compute-bound execution
2) Time spent in rpcs to our services

1) Compute-bound performance should be in the same rough ballpark on the
dev_appserver as our production servers. You can use any standard Java
profiler on your dev_appserer to measure this.

2) Time spent in services is going to vary wildly between production and the
dev_appserver. For example, the datastore for the dev_appserver is just an
in-memory store with periodic writebacks. The datastore for production is a
distributed database. You can measure these times in production using a
profiling ApiProxy.Delegate:

class ProfilingDelegate extends Delegate {
Delegate parent; public ProfilingDelegate(Delegate parent) { this.parent =
parent; } public byte[] makeSyncCall(Environment env, String pkg, String
method, byte[] request) { long start = System.nanoTime(); byte[] result =
parent.makeSyncCall(env, pkg, method, request); log.log(INFO, pkg + “.” +
method + “: “ + System.nanoTime() - start); return result; } }
ApiProxy.setDelegate(new ProfilingDelegate(ApiProxy.getDelegate()));

If you're feeling particularly aggressive, you can use the App Engine status
site <http://code.google.com/status/appengine> in conjunction with an
ApiProxy.Delegate to come up with an estimation of how much time you'll
spend in RPCs on the production and even insert corresponding sleeps into
your dev_appserver.

On Thu, Aug 20, 2009 at 5:17 AM, mar_novice <[email protected]> wrote:

>
> is there a way to do profiling with google app engine java?
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to