Class CloudExecutor (6.77.0)

public abstract class CloudExecutor

Superclass of cloud Java Client implementations for cloud requests.

Inheritance

java.lang.Object > CloudExecutor

Static Fields

DB_NAME

protected static final Pattern DB_NAME
Field Value
Type Description
Pattern

HTTP_TRANSPORT_FACTORY

protected static final HttpTransportFactory HTTP_TRANSPORT_FACTORY
Field Value
Type Description
com.google.auth.http.HttpTransportFactory

PROJECT_ID

protected static final String PROJECT_ID
Field Value
Type Description
String

Static Methods

timestampToString(boolean useNanosPrecision, long timestampInMicros)

protected static String timestampToString(boolean useNanosPrecision, long timestampInMicros)

Converts timestamp microseconds to query-friendly timestamp string. If useNanosPrecision is set to true it pads input timestamp with 3 random digits treating it as timestamp nanoseconds.

Parameters
Name Description
useNanosPrecision boolean
timestampInMicros long
Returns
Type Description
String

toProto(Status status)

protected static Status toProto(Status status)

Convert a Status to a Status Proto.

Parameter
Name Description
status io.grpc.Status
Returns
Type Description
com.google.rpc.Status

Constructors

CloudExecutor()

public CloudExecutor()

Fields

enableGrpcFaultInjector

protected boolean enableGrpcFaultInjector
Field Value
Type Description
boolean

Methods

toStatus(SpannerException e)

protected Status toStatus(SpannerException e)

Map Cloud ErrorCode to Status.

Parameter
Name Description
e SpannerException
Returns
Type Description
io.grpc.Status