Class HttpFaultAbort.Builder (1.12.1)

public static final class HttpFaultAbort.Builder extends GeneratedMessageV3.Builder<HttpFaultAbort.Builder> implements HttpFaultAbortOrBuilder

Specification for how requests are aborted as part of fault injection.

Protobuf type google.cloud.compute.v1.HttpFaultAbort

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public HttpFaultAbort.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
HttpFaultAbort.Builder
Overrides

build()

public HttpFaultAbort build()
Returns
TypeDescription
HttpFaultAbort

buildPartial()

public HttpFaultAbort buildPartial()
Returns
TypeDescription
HttpFaultAbort

clear()

public HttpFaultAbort.Builder clear()
Returns
TypeDescription
HttpFaultAbort.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public HttpFaultAbort.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
HttpFaultAbort.Builder
Overrides

clearHttpStatus()

public HttpFaultAbort.Builder clearHttpStatus()

The HTTP status code used to abort the request. The value must be from 200 to 599 inclusive. For gRPC protocol, the gRPC status code is mapped to HTTP status code according to this mapping table. HTTP status 200 is mapped to gRPC status UNKNOWN. Injecting an OK status is currently not supported by Traffic Director.

optional uint32 http_status = 468949897;

Returns
TypeDescription
HttpFaultAbort.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public HttpFaultAbort.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
HttpFaultAbort.Builder
Overrides

clearPercentage()

public HttpFaultAbort.Builder clearPercentage()

The percentage of traffic for connections, operations, or requests that is aborted as part of fault injection. The value must be from 0.0 to 100.0 inclusive.

optional double percentage = 151909018;

Returns
TypeDescription
HttpFaultAbort.Builder

This builder for chaining.

clone()

public HttpFaultAbort.Builder clone()
Returns
TypeDescription
HttpFaultAbort.Builder
Overrides

getDefaultInstanceForType()

public HttpFaultAbort getDefaultInstanceForType()
Returns
TypeDescription
HttpFaultAbort

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getHttpStatus()

public int getHttpStatus()

The HTTP status code used to abort the request. The value must be from 200 to 599 inclusive. For gRPC protocol, the gRPC status code is mapped to HTTP status code according to this mapping table. HTTP status 200 is mapped to gRPC status UNKNOWN. Injecting an OK status is currently not supported by Traffic Director.

optional uint32 http_status = 468949897;

Returns
TypeDescription
int

The httpStatus.

getPercentage()

public double getPercentage()

The percentage of traffic for connections, operations, or requests that is aborted as part of fault injection. The value must be from 0.0 to 100.0 inclusive.

optional double percentage = 151909018;

Returns
TypeDescription
double

The percentage.

hasHttpStatus()

public boolean hasHttpStatus()

The HTTP status code used to abort the request. The value must be from 200 to 599 inclusive. For gRPC protocol, the gRPC status code is mapped to HTTP status code according to this mapping table. HTTP status 200 is mapped to gRPC status UNKNOWN. Injecting an OK status is currently not supported by Traffic Director.

optional uint32 http_status = 468949897;

Returns
TypeDescription
boolean

Whether the httpStatus field is set.

hasPercentage()

public boolean hasPercentage()

The percentage of traffic for connections, operations, or requests that is aborted as part of fault injection. The value must be from 0.0 to 100.0 inclusive.

optional double percentage = 151909018;

Returns
TypeDescription
boolean

Whether the percentage field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(HttpFaultAbort other)

public HttpFaultAbort.Builder mergeFrom(HttpFaultAbort other)
Parameter
NameDescription
otherHttpFaultAbort
Returns
TypeDescription
HttpFaultAbort.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public HttpFaultAbort.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
HttpFaultAbort.Builder
Overrides Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public HttpFaultAbort.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
HttpFaultAbort.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final HttpFaultAbort.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
HttpFaultAbort.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public HttpFaultAbort.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
HttpFaultAbort.Builder
Overrides

setHttpStatus(int value)

public HttpFaultAbort.Builder setHttpStatus(int value)

The HTTP status code used to abort the request. The value must be from 200 to 599 inclusive. For gRPC protocol, the gRPC status code is mapped to HTTP status code according to this mapping table. HTTP status 200 is mapped to gRPC status UNKNOWN. Injecting an OK status is currently not supported by Traffic Director.

optional uint32 http_status = 468949897;

Parameter
NameDescription
valueint

The httpStatus to set.

Returns
TypeDescription
HttpFaultAbort.Builder

This builder for chaining.

setPercentage(double value)

public HttpFaultAbort.Builder setPercentage(double value)

The percentage of traffic for connections, operations, or requests that is aborted as part of fault injection. The value must be from 0.0 to 100.0 inclusive.

optional double percentage = 151909018;

Parameter
NameDescription
valuedouble

The percentage to set.

Returns
TypeDescription
HttpFaultAbort.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public HttpFaultAbort.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
HttpFaultAbort.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final HttpFaultAbort.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
HttpFaultAbort.Builder
Overrides