Package com.google.api.servicecontrol.v1
Class QuotaControllerGrpc.QuotaControllerStub
java.lang.Object
io.grpc.stub.AbstractStub<S>
io.grpc.stub.AbstractAsyncStub<QuotaControllerGrpc.QuotaControllerStub>
com.google.api.servicecontrol.v1.QuotaControllerGrpc.QuotaControllerStub
- Enclosing class:
- QuotaControllerGrpc
public static final class QuotaControllerGrpc.QuotaControllerStub
extends io.grpc.stub.AbstractAsyncStub<QuotaControllerGrpc.QuotaControllerStub>
A stub to allow clients to do asynchronous rpc calls to service QuotaController.
[Google Quota Control API](/service-control/overview) Allows clients to allocate and release quota against a [managed service](https://cloud.google.com/service-management/reference/rpc/google.api/servicemanagement.v1#google.api.servicemanagement.v1.ManagedService).
-
Nested Class Summary
Nested classes/interfaces inherited from class io.grpc.stub.AbstractStub
io.grpc.stub.AbstractStub.StubFactory<T extends io.grpc.stub.AbstractStub<T>> -
Method Summary
Modifier and TypeMethodDescriptionvoidallocateQuota(AllocateQuotaRequest request, io.grpc.stub.StreamObserver<AllocateQuotaResponse> responseObserver) Attempts to allocate quota for the specified consumer.protected QuotaControllerGrpc.QuotaControllerStubbuild(io.grpc.Channel channel, io.grpc.CallOptions callOptions) Methods inherited from class io.grpc.stub.AbstractAsyncStub
newStub, newStubMethods inherited from class io.grpc.stub.AbstractStub
getCallOptions, getChannel, withCallCredentials, withChannel, withCompression, withDeadline, withDeadlineAfter, withDeadlineAfter, withExecutor, withInterceptors, withMaxInboundMessageSize, withMaxOutboundMessageSize, withOnReadyThreshold, withOption, withWaitForReady
-
Method Details
-
build
protected QuotaControllerGrpc.QuotaControllerStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) - Specified by:
buildin classio.grpc.stub.AbstractStub<QuotaControllerGrpc.QuotaControllerStub>
-
allocateQuota
public void allocateQuota(AllocateQuotaRequest request, io.grpc.stub.StreamObserver<AllocateQuotaResponse> responseObserver) Attempts to allocate quota for the specified consumer. It should be called before the operation is executed. This method requires the `servicemanagement.services.quota` permission on the specified service. For more information, see [Cloud IAM](https://cloud.google.com/iam). **NOTE:** The client **must** fail-open on server errors `INTERNAL`, `UNKNOWN`, `DEADLINE_EXCEEDED`, and `UNAVAILABLE`. To ensure system reliability, the server may inject these errors to prohibit any hard dependency on the quota functionality.
-