Package com.google.apphosting.api
Interface ApiProxy.ApiResultFuture<T>
- All Superinterfaces:
Future<T>
- Enclosing class:
- ApiProxy
A subtype of
Future that provides more detailed
information about the timing and resource consumption of
particular API calls.
Objects returned from ApiProxy.makeAsyncCall(String,String,byte[],ApiConfig) may implement
this interface. However, callers should not currently assume
that all RPCs will.
-
Method Summary
Modifier and TypeMethodDescriptionlongReturns the amount of CPU time consumed across any backend servers responsible for serving this API call.longReturns the amount of wallclock time, measured in milliseconds, that this API call took to complete, as measured from the client side.
-
Method Details
-
getCpuTimeInMegaCycles
long getCpuTimeInMegaCycles()Returns the amount of CPU time consumed across any backend servers responsible for serving this API call. This quantity is measured in millions of CPU cycles to avoid suming times across a hetergeneous machine set with varied CPU clock speeds.- Throws:
IllegalStateException- If the RPC has not yet completed.
-
getWallclockTimeInMillis
long getWallclockTimeInMillis()Returns the amount of wallclock time, measured in milliseconds, that this API call took to complete, as measured from the client side.- Throws:
IllegalStateException- If the RPC has not yet completed.
-