Class CapacityCommitment
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite
-
- com.google.protobuf.AbstractMessage
-
- com.google.protobuf.GeneratedMessageV3
-
- com.google.cloud.bigquery.reservation.v1.CapacityCommitment
-
- All Implemented Interfaces:
CapacityCommitmentOrBuilder,com.google.protobuf.Message,com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Serializable
public final class CapacityCommitment extends com.google.protobuf.GeneratedMessageV3 implements CapacityCommitmentOrBuilder
Capacity commitment is a way to purchase compute capacity for BigQuery jobs (in the form of slots) with some committed period of usage. Annual commitments renew by default. Commitments can be removed after their commitment end time passes. In order to remove annual commitment, its plan needs to be changed to monthly or flex first. A capacity commitment resource exists as a child resource of the admin project.
Protobuf typegoogle.cloud.bigquery.reservation.v1.CapacityCommitment- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classCapacityCommitment.BuilderCapacity commitment is a way to purchase compute capacity for BigQuery jobs (in the form of slots) with some committed period of usage.static classCapacityCommitment.CommitmentPlanCommitment plan defines the current committed period.static classCapacityCommitment.StateCapacity commitment can either become ACTIVE right away or transition from PENDING to ACTIVE or FAILED.-
Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter
-
-
Field Summary
Fields Modifier and Type Field Description static intCOMMITMENT_END_TIME_FIELD_NUMBERstatic intCOMMITMENT_START_TIME_FIELD_NUMBERstatic intEDITION_FIELD_NUMBERstatic intFAILURE_STATUS_FIELD_NUMBERstatic intMULTI_REGION_AUXILIARY_FIELD_NUMBERstatic intNAME_FIELD_NUMBERstatic intPLAN_FIELD_NUMBERstatic intRENEWAL_PLAN_FIELD_NUMBERstatic intSLOT_COUNT_FIELD_NUMBERstatic intSTATE_FIELD_NUMBER
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)com.google.protobuf.TimestampgetCommitmentEndTime()Output only.com.google.protobuf.TimestampOrBuildergetCommitmentEndTimeOrBuilder()Output only.com.google.protobuf.TimestampgetCommitmentStartTime()Output only.com.google.protobuf.TimestampOrBuildergetCommitmentStartTimeOrBuilder()Output only.static CapacityCommitmentgetDefaultInstance()CapacityCommitmentgetDefaultInstanceForType()static com.google.protobuf.Descriptors.DescriptorgetDescriptor()EditiongetEdition()Edition of the capacity commitment.intgetEditionValue()Edition of the capacity commitment.com.google.rpc.StatusgetFailureStatus()Output only.com.google.rpc.StatusOrBuildergetFailureStatusOrBuilder()Output only.booleangetMultiRegionAuxiliary()Applicable only for commitments located within one of the BigQuery multi-regions (US or EU).StringgetName()Output only.com.google.protobuf.ByteStringgetNameBytes()Output only.com.google.protobuf.Parser<CapacityCommitment>getParserForType()CapacityCommitment.CommitmentPlangetPlan()Capacity commitment commitment plan.intgetPlanValue()Capacity commitment commitment plan.CapacityCommitment.CommitmentPlangetRenewalPlan()The plan this capacity commitment is converted to after commitment_end_time passes.intgetRenewalPlanValue()The plan this capacity commitment is converted to after commitment_end_time passes.intgetSerializedSize()longgetSlotCount()Number of slots in this commitment.CapacityCommitment.StategetState()Output only.intgetStateValue()Output only.booleanhasCommitmentEndTime()Output only.booleanhasCommitmentStartTime()Output only.booleanhasFailureStatus()Output only.inthashCode()protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()booleanisInitialized()static CapacityCommitment.BuildernewBuilder()static CapacityCommitment.BuildernewBuilder(CapacityCommitment prototype)CapacityCommitment.BuildernewBuilderForType()protected CapacityCommitment.BuildernewBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)protected ObjectnewInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)static CapacityCommitmentparseDelimitedFrom(InputStream input)static CapacityCommitmentparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static CapacityCommitmentparseFrom(byte[] data)static CapacityCommitmentparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static CapacityCommitmentparseFrom(com.google.protobuf.ByteString data)static CapacityCommitmentparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static CapacityCommitmentparseFrom(com.google.protobuf.CodedInputStream input)static CapacityCommitmentparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static CapacityCommitmentparseFrom(InputStream input)static CapacityCommitmentparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static CapacityCommitmentparseFrom(ByteBuffer data)static CapacityCommitmentparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static com.google.protobuf.Parser<CapacityCommitment>parser()CapacityCommitment.BuildertoBuilder()voidwriteTo(com.google.protobuf.CodedOutputStream output)-
Methods inherited from class com.google.protobuf.GeneratedMessageV3
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
-
Methods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite
addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
-
-
-
Field Detail
-
NAME_FIELD_NUMBER
public static final int NAME_FIELD_NUMBER
- See Also:
- Constant Field Values
-
SLOT_COUNT_FIELD_NUMBER
public static final int SLOT_COUNT_FIELD_NUMBER
- See Also:
- Constant Field Values
-
PLAN_FIELD_NUMBER
public static final int PLAN_FIELD_NUMBER
- See Also:
- Constant Field Values
-
STATE_FIELD_NUMBER
public static final int STATE_FIELD_NUMBER
- See Also:
- Constant Field Values
-
COMMITMENT_START_TIME_FIELD_NUMBER
public static final int COMMITMENT_START_TIME_FIELD_NUMBER
- See Also:
- Constant Field Values
-
COMMITMENT_END_TIME_FIELD_NUMBER
public static final int COMMITMENT_END_TIME_FIELD_NUMBER
- See Also:
- Constant Field Values
-
FAILURE_STATUS_FIELD_NUMBER
public static final int FAILURE_STATUS_FIELD_NUMBER
- See Also:
- Constant Field Values
-
RENEWAL_PLAN_FIELD_NUMBER
public static final int RENEWAL_PLAN_FIELD_NUMBER
- See Also:
- Constant Field Values
-
MULTI_REGION_AUXILIARY_FIELD_NUMBER
public static final int MULTI_REGION_AUXILIARY_FIELD_NUMBER
- See Also:
- Constant Field Values
-
EDITION_FIELD_NUMBER
public static final int EDITION_FIELD_NUMBER
- See Also:
- Constant Field Values
-
-
Method Detail
-
newInstance
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
- Overrides:
newInstancein classcom.google.protobuf.GeneratedMessageV3
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3
-
getName
public String getName()
Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` The commitment_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.
string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getNamein interfaceCapacityCommitmentOrBuilder- Returns:
- The name.
-
getNameBytes
public com.google.protobuf.ByteString getNameBytes()
Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` The commitment_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.
string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getNameBytesin interfaceCapacityCommitmentOrBuilder- Returns:
- The bytes for name.
-
getSlotCount
public long getSlotCount()
Number of slots in this commitment.
int64 slot_count = 2;- Specified by:
getSlotCountin interfaceCapacityCommitmentOrBuilder- Returns:
- The slotCount.
-
getPlanValue
public int getPlanValue()
Capacity commitment commitment plan.
.google.cloud.bigquery.reservation.v1.CapacityCommitment.CommitmentPlan plan = 3;- Specified by:
getPlanValuein interfaceCapacityCommitmentOrBuilder- Returns:
- The enum numeric value on the wire for plan.
-
getPlan
public CapacityCommitment.CommitmentPlan getPlan()
Capacity commitment commitment plan.
.google.cloud.bigquery.reservation.v1.CapacityCommitment.CommitmentPlan plan = 3;- Specified by:
getPlanin interfaceCapacityCommitmentOrBuilder- Returns:
- The plan.
-
getStateValue
public int getStateValue()
Output only. State of the commitment.
.google.cloud.bigquery.reservation.v1.CapacityCommitment.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getStateValuein interfaceCapacityCommitmentOrBuilder- Returns:
- The enum numeric value on the wire for state.
-
getState
public CapacityCommitment.State getState()
Output only. State of the commitment.
.google.cloud.bigquery.reservation.v1.CapacityCommitment.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getStatein interfaceCapacityCommitmentOrBuilder- Returns:
- The state.
-
hasCommitmentStartTime
public boolean hasCommitmentStartTime()
Output only. The start of the current commitment period. It is applicable only for ACTIVE capacity commitments.
.google.protobuf.Timestamp commitment_start_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
hasCommitmentStartTimein interfaceCapacityCommitmentOrBuilder- Returns:
- Whether the commitmentStartTime field is set.
-
getCommitmentStartTime
public com.google.protobuf.Timestamp getCommitmentStartTime()
Output only. The start of the current commitment period. It is applicable only for ACTIVE capacity commitments.
.google.protobuf.Timestamp commitment_start_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getCommitmentStartTimein interfaceCapacityCommitmentOrBuilder- Returns:
- The commitmentStartTime.
-
getCommitmentStartTimeOrBuilder
public com.google.protobuf.TimestampOrBuilder getCommitmentStartTimeOrBuilder()
Output only. The start of the current commitment period. It is applicable only for ACTIVE capacity commitments.
.google.protobuf.Timestamp commitment_start_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getCommitmentStartTimeOrBuilderin interfaceCapacityCommitmentOrBuilder
-
hasCommitmentEndTime
public boolean hasCommitmentEndTime()
Output only. The end of the current commitment period. It is applicable only for ACTIVE capacity commitments.
.google.protobuf.Timestamp commitment_end_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
hasCommitmentEndTimein interfaceCapacityCommitmentOrBuilder- Returns:
- Whether the commitmentEndTime field is set.
-
getCommitmentEndTime
public com.google.protobuf.Timestamp getCommitmentEndTime()
Output only. The end of the current commitment period. It is applicable only for ACTIVE capacity commitments.
.google.protobuf.Timestamp commitment_end_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getCommitmentEndTimein interfaceCapacityCommitmentOrBuilder- Returns:
- The commitmentEndTime.
-
getCommitmentEndTimeOrBuilder
public com.google.protobuf.TimestampOrBuilder getCommitmentEndTimeOrBuilder()
Output only. The end of the current commitment period. It is applicable only for ACTIVE capacity commitments.
.google.protobuf.Timestamp commitment_end_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getCommitmentEndTimeOrBuilderin interfaceCapacityCommitmentOrBuilder
-
hasFailureStatus
public boolean hasFailureStatus()
Output only. For FAILED commitment plan, provides the reason of failure.
.google.rpc.Status failure_status = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
hasFailureStatusin interfaceCapacityCommitmentOrBuilder- Returns:
- Whether the failureStatus field is set.
-
getFailureStatus
public com.google.rpc.Status getFailureStatus()
Output only. For FAILED commitment plan, provides the reason of failure.
.google.rpc.Status failure_status = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getFailureStatusin interfaceCapacityCommitmentOrBuilder- Returns:
- The failureStatus.
-
getFailureStatusOrBuilder
public com.google.rpc.StatusOrBuilder getFailureStatusOrBuilder()
Output only. For FAILED commitment plan, provides the reason of failure.
.google.rpc.Status failure_status = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getFailureStatusOrBuilderin interfaceCapacityCommitmentOrBuilder
-
getRenewalPlanValue
public int getRenewalPlanValue()
The plan this capacity commitment is converted to after commitment_end_time passes. Once the plan is changed, committed period is extended according to commitment plan. Only applicable for ANNUAL and TRIAL commitments.
.google.cloud.bigquery.reservation.v1.CapacityCommitment.CommitmentPlan renewal_plan = 8;- Specified by:
getRenewalPlanValuein interfaceCapacityCommitmentOrBuilder- Returns:
- The enum numeric value on the wire for renewalPlan.
-
getRenewalPlan
public CapacityCommitment.CommitmentPlan getRenewalPlan()
The plan this capacity commitment is converted to after commitment_end_time passes. Once the plan is changed, committed period is extended according to commitment plan. Only applicable for ANNUAL and TRIAL commitments.
.google.cloud.bigquery.reservation.v1.CapacityCommitment.CommitmentPlan renewal_plan = 8;- Specified by:
getRenewalPlanin interfaceCapacityCommitmentOrBuilder- Returns:
- The renewalPlan.
-
getMultiRegionAuxiliary
public boolean getMultiRegionAuxiliary()
Applicable only for commitments located within one of the BigQuery multi-regions (US or EU). If set to true, this commitment is placed in the organization's secondary region which is designated for disaster recovery purposes. If false, this commitment is placed in the organization's default region. NOTE: this is a preview feature. Project must be allow-listed in order to set this field.
bool multi_region_auxiliary = 10;- Specified by:
getMultiRegionAuxiliaryin interfaceCapacityCommitmentOrBuilder- Returns:
- The multiRegionAuxiliary.
-
getEditionValue
public int getEditionValue()
Edition of the capacity commitment.
.google.cloud.bigquery.reservation.v1.Edition edition = 12;- Specified by:
getEditionValuein interfaceCapacityCommitmentOrBuilder- Returns:
- The enum numeric value on the wire for edition.
-
getEdition
public Edition getEdition()
Edition of the capacity commitment.
.google.cloud.bigquery.reservation.v1.Edition edition = 12;- Specified by:
getEditionin interfaceCapacityCommitmentOrBuilder- Returns:
- The edition.
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3
-
writeTo
public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException- Specified by:
writeToin interfacecom.google.protobuf.MessageLite- Overrides:
writeToin classcom.google.protobuf.GeneratedMessageV3- Throws:
IOException
-
getSerializedSize
public int getSerializedSize()
- Specified by:
getSerializedSizein interfacecom.google.protobuf.MessageLite- Overrides:
getSerializedSizein classcom.google.protobuf.GeneratedMessageV3
-
equals
public boolean equals(Object obj)
- Specified by:
equalsin interfacecom.google.protobuf.Message- Overrides:
equalsin classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()
- Specified by:
hashCodein interfacecom.google.protobuf.Message- Overrides:
hashCodein classcom.google.protobuf.AbstractMessage
-
parseFrom
public static CapacityCommitment parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static CapacityCommitment parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static CapacityCommitment parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static CapacityCommitment parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static CapacityCommitment parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static CapacityCommitment parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static CapacityCommitment parseFrom(InputStream input) throws IOException
- Throws:
IOException
-
parseFrom
public static CapacityCommitment parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
parseDelimitedFrom
public static CapacityCommitment parseDelimitedFrom(InputStream input) throws IOException
- Throws:
IOException
-
parseDelimitedFrom
public static CapacityCommitment parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
parseFrom
public static CapacityCommitment parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
- Throws:
IOException
-
parseFrom
public static CapacityCommitment parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
newBuilderForType
public CapacityCommitment.Builder newBuilderForType()
- Specified by:
newBuilderForTypein interfacecom.google.protobuf.Message- Specified by:
newBuilderForTypein interfacecom.google.protobuf.MessageLite
-
newBuilder
public static CapacityCommitment.Builder newBuilder()
-
newBuilder
public static CapacityCommitment.Builder newBuilder(CapacityCommitment prototype)
-
toBuilder
public CapacityCommitment.Builder toBuilder()
- Specified by:
toBuilderin interfacecom.google.protobuf.Message- Specified by:
toBuilderin interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected CapacityCommitment.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
- Specified by:
newBuilderForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstance
public static CapacityCommitment getDefaultInstance()
-
parser
public static com.google.protobuf.Parser<CapacityCommitment> parser()
-
getParserForType
public com.google.protobuf.Parser<CapacityCommitment> getParserForType()
- Specified by:
getParserForTypein interfacecom.google.protobuf.Message- Specified by:
getParserForTypein interfacecom.google.protobuf.MessageLite- Overrides:
getParserForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstanceForType
public CapacityCommitment getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
-