Package com.google.apphosting.runtime
Class ApiProxyImpl.EnvironmentImpl
java.lang.Object
com.google.apphosting.runtime.ApiProxyImpl.EnvironmentImpl
- All Implemented Interfaces:
com.google.apphosting.api.ApiProxy.Environment,com.google.apphosting.api.ApiProxy.EnvironmentWithTrace
- Enclosing class:
- ApiProxyImpl
public static final class ApiProxyImpl.EnvironmentImpl
extends Object
implements com.google.apphosting.api.ApiProxy.EnvironmentWithTrace
To implement ApiProxy.Environment, we use a class that wraps
around an UPRequest and retrieves the necessary information from
it.
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddLogRecord(com.google.apphosting.api.ApiProxy.LogRecord record) voidgetAppId()getEmail()longDeprecated.Get the span id of the current request, which can be used to identify a span within a trace.Get the trace id of the current request, which can be used to correlate log messages belonging to that request.booleanisAdmin()boolean
-
Method Details
-
addLogRecord
public void addLogRecord(com.google.apphosting.api.ApiProxy.LogRecord record) -
flushLogs
public void flushLogs() -
getTraceWriter
-
getAppId
- Specified by:
getAppIdin interfacecom.google.apphosting.api.ApiProxy.Environment
-
getModuleId
- Specified by:
getModuleIdin interfacecom.google.apphosting.api.ApiProxy.Environment
-
getVersionId
- Specified by:
getVersionIdin interfacecom.google.apphosting.api.ApiProxy.Environment
-
getTraceId
Get the trace id of the current request, which can be used to correlate log messages belonging to that request.- Specified by:
getTraceIdin interfacecom.google.apphosting.api.ApiProxy.EnvironmentWithTrace
-
getSpanId
Get the span id of the current request, which can be used to identify a span within a trace.- Specified by:
getSpanIdin interfacecom.google.apphosting.api.ApiProxy.EnvironmentWithTrace
-
getAppVersion
-
isLoggedIn
public boolean isLoggedIn()- Specified by:
isLoggedInin interfacecom.google.apphosting.api.ApiProxy.Environment
-
isAdmin
public boolean isAdmin()- Specified by:
isAdminin interfacecom.google.apphosting.api.ApiProxy.Environment
-
getEmail
- Specified by:
getEmailin interfacecom.google.apphosting.api.ApiProxy.Environment
-
getAuthDomain
- Specified by:
getAuthDomainin interfacecom.google.apphosting.api.ApiProxy.Environment
-
getRequestNamespace
Deprecated.- Specified by:
getRequestNamespacein interfacecom.google.apphosting.api.ApiProxy.Environment
-
getAttributes
- Specified by:
getAttributesin interfacecom.google.apphosting.api.ApiProxy.Environment
-
getRemainingMillis
public long getRemainingMillis()- Specified by:
getRemainingMillisin interfacecom.google.apphosting.api.ApiProxy.Environment
-
getTraceExceptionGenerator
public com.google.apphosting.runtime.ApiProxyImpl.TraceExceptionGenerator getTraceExceptionGenerator()
-