Why isn't there a system property that can be used to detect if a
program is running on appengine?
This is really a glaring oversight. I would expect something like
System.getProperty(google.appengine) to be development or
production (or of course null).
Before someone says check the servlet
I agree. My workaround was to create a ServletEventListener and put this in
the contextInitialized() method:
System.setProperty( appengine.server,
event.getServletContext().getServerInfo().contains( Development ) ?
development : production );
Vince
On Thu, Dec 3, 2009 at 1:15 PM, Jeff
Yes, I totally agree that the current official way of checking for App
Engine presence is not great for third party libraries which don't even
necessarily run in a servlet container. We've been putting together a
solution for this and hope to make it available soon.
On Thu, Dec 3, 2009 at 1:15
Could you create a Servlet that is loaded on launch, and set this kind of
property? I think this is a workaround until they can do it officially.
--Jeff
On Thu, Dec 3, 2009 at 10:39 AM, Toby Reyelts to...@google.com wrote:
Yes, I totally agree that the current official way of checking for App
On Thu, Dec 3, 2009 at 10:46 AM, Jeffrey Goetsch jeffg@gmail.com wrote:
Could you create a Servlet that is loaded on launch, and set this kind of
property? I think this is a workaround until they can do it officially.
I can't - remember this is in a library, so I would have to force all