Class TracedOperationCallable<RequestT,ResponseT,MetadataT> (2.48.0)

public class TracedOperationCallable<RequestT,ResponseT,MetadataT> extends OperationCallable<RequestT,ResponseT,MetadataT>

This callable wraps a OperationCallable in a ApiTracer.

For internal use only.

Inheritance

java.lang.Object > OperationCallable > TracedOperationCallable<RequestT,ResponseT,MetadataT>

Type Parameters

Name Description
RequestT
ResponseT
MetadataT

Constructors

TracedOperationCallable(OperationCallable<RequestT,ResponseT,MetadataT> innerCallable, ApiTracerFactory tracerFactory, SpanName spanName)

public TracedOperationCallable(OperationCallable<RequestT,ResponseT,MetadataT> innerCallable, ApiTracerFactory tracerFactory, SpanName spanName)
Parameters
Name Description
innerCallable OperationCallable<RequestT,ResponseT,MetadataT>
tracerFactory ApiTracerFactory
spanName SpanName

Methods

cancel(String operationName, ApiCallContext context)

public ApiFuture<Void> cancel(String operationName, ApiCallContext context)

Wrap operation cancellation in a OperationType#Unary trace.

Parameters
Name Description
operationName String
context ApiCallContext
Returns
Type Description
ApiFuture<Void>
Overrides

futureCall(RequestT request, ApiCallContext context)

public OperationFuture<ResponseT,MetadataT> futureCall(RequestT request, ApiCallContext context)

Wrap the initial start polling logical operations in a single parent trace using a OperationType#LongRunning ApiTracer.

Parameters
Name Description
request RequestT
context ApiCallContext
Returns
Type Description
OperationFuture<ResponseT,MetadataT>
Overrides

resumeFutureCall(String operationName, ApiCallContext context)

public OperationFuture<ResponseT,MetadataT> resumeFutureCall(String operationName, ApiCallContext context)

Wrap the polling logical operations in a single parent trace using a OperationType#LongRunning ApiTracer.

Parameters
Name Description
operationName String
context ApiCallContext
Returns
Type Description
OperationFuture<ResponseT,MetadataT>
Overrides