diff --git a/generation_config.yaml b/generation_config.yaml index a2188111195..6c476f6f865 100644 --- a/generation_config.yaml +++ b/generation_config.yaml @@ -1,5 +1,5 @@ gapic_generator_version: 2.52.0 -googleapis_commitish: 2a3db2e19f48a139db9f40278c0217df110add9b +googleapis_commitish: 3cf61b2df20eace09e6336c23f9e08859c0d87ae libraries_bom_version: 26.53.0 libraries: - api_shortname: spanner diff --git a/google-cloud-spanner-executor/src/main/resources/META-INF/native-image/com.google.cloud.spanner.executor.v1/reflect-config.json b/google-cloud-spanner-executor/src/main/resources/META-INF/native-image/com.google.cloud.spanner.executor.v1/reflect-config.json index 25668dd3de8..1b9c4de2d83 100644 --- a/google-cloud-spanner-executor/src/main/resources/META-INF/native-image/com.google.cloud.spanner.executor.v1/reflect-config.json +++ b/google-cloud-spanner-executor/src/main/resources/META-INF/native-image/com.google.cloud.spanner.executor.v1/reflect-config.json @@ -1700,6 +1700,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.spanner.admin.database.v1.AddSplitPointsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.spanner.admin.database.v1.AddSplitPointsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.spanner.admin.database.v1.AddSplitPointsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.spanner.admin.database.v1.AddSplitPointsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.spanner.admin.database.v1.Backup", "queryAllDeclaredConstructors": true, @@ -2618,6 +2654,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.spanner.admin.database.v1.SplitPoints", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.spanner.admin.database.v1.SplitPoints$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.spanner.admin.database.v1.SplitPoints$Key", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.spanner.admin.database.v1.SplitPoints$Key$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.spanner.admin.database.v1.UpdateBackupRequest", "queryAllDeclaredConstructors": true, diff --git a/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminClient.java b/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminClient.java index 416913e22f7..b91188619aa 100644 --- a/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminClient.java +++ b/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminClient.java @@ -41,6 +41,8 @@ import com.google.protobuf.Empty; import com.google.protobuf.FieldMask; import com.google.protobuf.Timestamp; +import com.google.spanner.admin.database.v1.AddSplitPointsRequest; +import com.google.spanner.admin.database.v1.AddSplitPointsResponse; import com.google.spanner.admin.database.v1.Backup; import com.google.spanner.admin.database.v1.BackupName; import com.google.spanner.admin.database.v1.BackupSchedule; @@ -78,6 +80,7 @@ import com.google.spanner.admin.database.v1.ListDatabasesResponse; import com.google.spanner.admin.database.v1.RestoreDatabaseMetadata; import com.google.spanner.admin.database.v1.RestoreDatabaseRequest; +import com.google.spanner.admin.database.v1.SplitPoints; import com.google.spanner.admin.database.v1.UpdateBackupRequest; import com.google.spanner.admin.database.v1.UpdateBackupScheduleRequest; import com.google.spanner.admin.database.v1.UpdateDatabaseDdlMetadata; @@ -524,6 +527,25 @@ * * *
AddSplitPoints
Adds split points to specified tables, indexes of a database.
Request object method variants only take one parameter, a request object, which must be constructed before the call.
+ *addSplitPoints(AddSplitPointsRequest request) + *
"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.
+ *addSplitPoints(DatabaseName database, List<SplitPoints> splitPoints) + *
addSplitPoints(String database, List<SplitPoints> splitPoints) + *
Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.
+ *addSplitPointsCallable() + *
CreateBackupSchedule
Creates a new backup schedule.
Sample code: + * + *
{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * try (DatabaseAdminClient databaseAdminClient = DatabaseAdminClient.create()) {
+ * DatabaseName database = DatabaseName.of("[PROJECT]", "[INSTANCE]", "[DATABASE]");
+ * List splitPoints = new ArrayList<>();
+ * AddSplitPointsResponse response = databaseAdminClient.addSplitPoints(database, splitPoints);
+ * }
+ * }
+ *
+ * @param database Required. The database on whose tables/indexes split points are to be added.
+ * Values are of the form
+ * `projects/<project>/instances/<instance>/databases/<database>`.
+ * @param splitPoints Required. The split points to add.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final AddSplitPointsResponse addSplitPoints(
+ DatabaseName database, ListSample code: + * + *
{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * try (DatabaseAdminClient databaseAdminClient = DatabaseAdminClient.create()) {
+ * String database = DatabaseName.of("[PROJECT]", "[INSTANCE]", "[DATABASE]").toString();
+ * List splitPoints = new ArrayList<>();
+ * AddSplitPointsResponse response = databaseAdminClient.addSplitPoints(database, splitPoints);
+ * }
+ * }
+ *
+ * @param database Required. The database on whose tables/indexes split points are to be added.
+ * Values are of the form
+ * `projects/<project>/instances/<instance>/databases/<database>`.
+ * @param splitPoints Required. The split points to add.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final AddSplitPointsResponse addSplitPoints(
+ String database, ListSample code: + * + *
{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * try (DatabaseAdminClient databaseAdminClient = DatabaseAdminClient.create()) {
+ * AddSplitPointsRequest request =
+ * AddSplitPointsRequest.newBuilder()
+ * .setDatabase(DatabaseName.of("[PROJECT]", "[INSTANCE]", "[DATABASE]").toString())
+ * .addAllSplitPoints(new ArrayList())
+ * .setInitiator("initiator-248987089")
+ * .build();
+ * AddSplitPointsResponse response = databaseAdminClient.addSplitPoints(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final AddSplitPointsResponse addSplitPoints(AddSplitPointsRequest request) {
+ return addSplitPointsCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Adds split points to specified tables, indexes of a database.
+ *
+ * Sample code: + * + *
{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * try (DatabaseAdminClient databaseAdminClient = DatabaseAdminClient.create()) {
+ * AddSplitPointsRequest request =
+ * AddSplitPointsRequest.newBuilder()
+ * .setDatabase(DatabaseName.of("[PROJECT]", "[INSTANCE]", "[DATABASE]").toString())
+ * .addAllSplitPoints(new ArrayList())
+ * .setInitiator("initiator-248987089")
+ * .build();
+ * ApiFuture future =
+ * databaseAdminClient.addSplitPointsCallable().futureCall(request);
+ * // Do something.
+ * AddSplitPointsResponse response = future.get();
+ * }
+ * }
+ */
+ public final UnaryCallable+ * Adds split points to specified tables, indexes of a database. + *+ */ + default void addSplitPoints( + com.google.spanner.admin.database.v1.AddSplitPointsRequest request, + io.grpc.stub.StreamObserver
+ * Adds split points to specified tables, indexes of a database. + *+ */ + public void addSplitPoints( + com.google.spanner.admin.database.v1.AddSplitPointsRequest request, + io.grpc.stub.StreamObserver
+ * Adds split points to specified tables, indexes of a database. + *+ */ + public com.google.spanner.admin.database.v1.AddSplitPointsResponse addSplitPoints( + com.google.spanner.admin.database.v1.AddSplitPointsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getAddSplitPointsMethod(), getCallOptions(), request); + } + /** * * @@ -3221,6 +3313,20 @@ protected DatabaseAdminFutureStub build( getChannel().newCall(getListDatabaseRolesMethod(), getCallOptions()), request); } + /** + * + * + *
+ * Adds split points to specified tables, indexes of a database. + *+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.spanner.admin.database.v1.AddSplitPointsResponse> + addSplitPoints(com.google.spanner.admin.database.v1.AddSplitPointsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getAddSplitPointsMethod(), getCallOptions()), request); + } + /** * * @@ -3315,11 +3421,12 @@ protected DatabaseAdminFutureStub build( private static final int METHODID_LIST_DATABASE_OPERATIONS = 17; private static final int METHODID_LIST_BACKUP_OPERATIONS = 18; private static final int METHODID_LIST_DATABASE_ROLES = 19; - private static final int METHODID_CREATE_BACKUP_SCHEDULE = 20; - private static final int METHODID_GET_BACKUP_SCHEDULE = 21; - private static final int METHODID_UPDATE_BACKUP_SCHEDULE = 22; - private static final int METHODID_DELETE_BACKUP_SCHEDULE = 23; - private static final int METHODID_LIST_BACKUP_SCHEDULES = 24; + private static final int METHODID_ADD_SPLIT_POINTS = 20; + private static final int METHODID_CREATE_BACKUP_SCHEDULE = 21; + private static final int METHODID_GET_BACKUP_SCHEDULE = 22; + private static final int METHODID_UPDATE_BACKUP_SCHEDULE = 23; + private static final int METHODID_DELETE_BACKUP_SCHEDULE = 24; + private static final int METHODID_LIST_BACKUP_SCHEDULES = 25; private static final class MethodHandlers
+ * The request for + * [AddSplitPoints][google.spanner.admin.database.v1.DatabaseAdmin.AddSplitPoints]. + *+ * + * Protobuf type {@code google.spanner.admin.database.v1.AddSplitPointsRequest} + */ +public final class AddSplitPointsRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.spanner.admin.database.v1.AddSplitPointsRequest) + AddSplitPointsRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use AddSplitPointsRequest.newBuilder() to construct. + private AddSplitPointsRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + + private AddSplitPointsRequest() { + database_ = ""; + splitPoints_ = java.util.Collections.emptyList(); + initiator_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new AddSplitPointsRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.spanner.admin.database.v1.SpannerDatabaseAdminProto + .internal_static_google_spanner_admin_database_v1_AddSplitPointsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.spanner.admin.database.v1.SpannerDatabaseAdminProto + .internal_static_google_spanner_admin_database_v1_AddSplitPointsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.spanner.admin.database.v1.AddSplitPointsRequest.class, + com.google.spanner.admin.database.v1.AddSplitPointsRequest.Builder.class); + } + + public static final int DATABASE_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object database_ = ""; + /** + * + * + *
+ * Required. The database on whose tables/indexes split points are to be + * added. Values are of the form + * `projects/<project>/instances/<instance>/databases/<database>`. + *+ * + *
+ * string database = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The database.
+ */
+ @java.lang.Override
+ public java.lang.String getDatabase() {
+ java.lang.Object ref = database_;
+ if (ref instanceof java.lang.String) {
+ return (java.lang.String) ref;
+ } else {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ database_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The database on whose tables/indexes split points are to be + * added. Values are of the form + * `projects/<project>/instances/<instance>/databases/<database>`. + *+ * + *
+ * string database = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The bytes for database.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getDatabaseBytes() {
+ java.lang.Object ref = database_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ database_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int SPLIT_POINTS_FIELD_NUMBER = 2;
+
+ @SuppressWarnings("serial")
+ private java.util.List+ * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ @java.lang.Override
+ public java.util.List+ * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ @java.lang.Override
+ public java.util.List extends com.google.spanner.admin.database.v1.SplitPointsOrBuilder>
+ getSplitPointsOrBuilderList() {
+ return splitPoints_;
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ @java.lang.Override
+ public int getSplitPointsCount() {
+ return splitPoints_.size();
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ @java.lang.Override
+ public com.google.spanner.admin.database.v1.SplitPoints getSplitPoints(int index) {
+ return splitPoints_.get(index);
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ @java.lang.Override
+ public com.google.spanner.admin.database.v1.SplitPointsOrBuilder getSplitPointsOrBuilder(
+ int index) {
+ return splitPoints_.get(index);
+ }
+
+ public static final int INITIATOR_FIELD_NUMBER = 3;
+
+ @SuppressWarnings("serial")
+ private volatile java.lang.Object initiator_ = "";
+ /**
+ *
+ *
+ * + * Optional. A user-supplied tag associated with the split points. + * For example, "intital_data_load", "special_event_1". + * Defaults to "CloudAddSplitPointsAPI" if not specified. + * The length of the tag must not exceed 50 characters,else will be trimmed. + * Only valid UTF8 characters are allowed. + *+ * + *
string initiator = 3 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The initiator.
+ */
+ @java.lang.Override
+ public java.lang.String getInitiator() {
+ java.lang.Object ref = initiator_;
+ if (ref instanceof java.lang.String) {
+ return (java.lang.String) ref;
+ } else {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ initiator_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. A user-supplied tag associated with the split points. + * For example, "intital_data_load", "special_event_1". + * Defaults to "CloudAddSplitPointsAPI" if not specified. + * The length of the tag must not exceed 50 characters,else will be trimmed. + * Only valid UTF8 characters are allowed. + *+ * + *
string initiator = 3 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The bytes for initiator.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getInitiatorBytes() {
+ java.lang.Object ref = initiator_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ initiator_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ private byte memoizedIsInitialized = -1;
+
+ @java.lang.Override
+ public final boolean isInitialized() {
+ byte isInitialized = memoizedIsInitialized;
+ if (isInitialized == 1) return true;
+ if (isInitialized == 0) return false;
+
+ memoizedIsInitialized = 1;
+ return true;
+ }
+
+ @java.lang.Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(database_)) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 1, database_);
+ }
+ for (int i = 0; i < splitPoints_.size(); i++) {
+ output.writeMessage(2, splitPoints_.get(i));
+ }
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(initiator_)) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 3, initiator_);
+ }
+ getUnknownFields().writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(database_)) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, database_);
+ }
+ for (int i = 0; i < splitPoints_.size(); i++) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, splitPoints_.get(i));
+ }
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(initiator_)) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, initiator_);
+ }
+ size += getUnknownFields().getSerializedSize();
+ memoizedSize = size;
+ return size;
+ }
+
+ @java.lang.Override
+ public boolean equals(final java.lang.Object obj) {
+ if (obj == this) {
+ return true;
+ }
+ if (!(obj instanceof com.google.spanner.admin.database.v1.AddSplitPointsRequest)) {
+ return super.equals(obj);
+ }
+ com.google.spanner.admin.database.v1.AddSplitPointsRequest other =
+ (com.google.spanner.admin.database.v1.AddSplitPointsRequest) obj;
+
+ if (!getDatabase().equals(other.getDatabase())) return false;
+ if (!getSplitPointsList().equals(other.getSplitPointsList())) return false;
+ if (!getInitiator().equals(other.getInitiator())) return false;
+ if (!getUnknownFields().equals(other.getUnknownFields())) return false;
+ return true;
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ if (memoizedHashCode != 0) {
+ return memoizedHashCode;
+ }
+ int hash = 41;
+ hash = (19 * hash) + getDescriptor().hashCode();
+ hash = (37 * hash) + DATABASE_FIELD_NUMBER;
+ hash = (53 * hash) + getDatabase().hashCode();
+ if (getSplitPointsCount() > 0) {
+ hash = (37 * hash) + SPLIT_POINTS_FIELD_NUMBER;
+ hash = (53 * hash) + getSplitPointsList().hashCode();
+ }
+ hash = (37 * hash) + INITIATOR_FIELD_NUMBER;
+ hash = (53 * hash) + getInitiator().hashCode();
+ hash = (29 * hash) + getUnknownFields().hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseFrom(
+ java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseFrom(
+ java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseFrom(
+ com.google.protobuf.ByteString data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseFrom(
+ byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseDelimitedFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseDelimitedFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseFrom(
+ com.google.protobuf.CodedInputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest parseFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ @java.lang.Override
+ public Builder newBuilderForType() {
+ return newBuilder();
+ }
+
+ public static Builder newBuilder() {
+ return DEFAULT_INSTANCE.toBuilder();
+ }
+
+ public static Builder newBuilder(
+ com.google.spanner.admin.database.v1.AddSplitPointsRequest prototype) {
+ return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
+ }
+
+ @java.lang.Override
+ public Builder toBuilder() {
+ return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
+ }
+
+ @java.lang.Override
+ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+ Builder builder = new Builder(parent);
+ return builder;
+ }
+ /**
+ *
+ *
+ * + * The request for + * [AddSplitPoints][google.spanner.admin.database.v1.DatabaseAdmin.AddSplitPoints]. + *+ * + * Protobuf type {@code google.spanner.admin.database.v1.AddSplitPointsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+ * Required. The database on whose tables/indexes split points are to be + * added. Values are of the form + * `projects/<project>/instances/<instance>/databases/<database>`. + *+ * + *
+ * string database = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The database.
+ */
+ public java.lang.String getDatabase() {
+ java.lang.Object ref = database_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ database_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The database on whose tables/indexes split points are to be + * added. Values are of the form + * `projects/<project>/instances/<instance>/databases/<database>`. + *+ * + *
+ * string database = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The bytes for database.
+ */
+ public com.google.protobuf.ByteString getDatabaseBytes() {
+ java.lang.Object ref = database_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ database_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The database on whose tables/indexes split points are to be + * added. Values are of the form + * `projects/<project>/instances/<instance>/databases/<database>`. + *+ * + *
+ * string database = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @param value The database to set.
+ * @return This builder for chaining.
+ */
+ public Builder setDatabase(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ database_ = value;
+ bitField0_ |= 0x00000001;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The database on whose tables/indexes split points are to be + * added. Values are of the form + * `projects/<project>/instances/<instance>/databases/<database>`. + *+ * + *
+ * string database = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearDatabase() {
+ database_ = getDefaultInstance().getDatabase();
+ bitField0_ = (bitField0_ & ~0x00000001);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The database on whose tables/indexes split points are to be + * added. Values are of the form + * `projects/<project>/instances/<instance>/databases/<database>`. + *+ * + *
+ * string database = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @param value The bytes for database to set.
+ * @return This builder for chaining.
+ */
+ public Builder setDatabaseBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+ database_ = value;
+ bitField0_ |= 0x00000001;
+ onChanged();
+ return this;
+ }
+
+ private java.util.List+ * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public java.util.List+ * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public int getSplitPointsCount() {
+ if (splitPointsBuilder_ == null) {
+ return splitPoints_.size();
+ } else {
+ return splitPointsBuilder_.getCount();
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.spanner.admin.database.v1.SplitPoints getSplitPoints(int index) {
+ if (splitPointsBuilder_ == null) {
+ return splitPoints_.get(index);
+ } else {
+ return splitPointsBuilder_.getMessage(index);
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder setSplitPoints(
+ int index, com.google.spanner.admin.database.v1.SplitPoints value) {
+ if (splitPointsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureSplitPointsIsMutable();
+ splitPoints_.set(index, value);
+ onChanged();
+ } else {
+ splitPointsBuilder_.setMessage(index, value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder setSplitPoints(
+ int index, com.google.spanner.admin.database.v1.SplitPoints.Builder builderForValue) {
+ if (splitPointsBuilder_ == null) {
+ ensureSplitPointsIsMutable();
+ splitPoints_.set(index, builderForValue.build());
+ onChanged();
+ } else {
+ splitPointsBuilder_.setMessage(index, builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder addSplitPoints(com.google.spanner.admin.database.v1.SplitPoints value) {
+ if (splitPointsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureSplitPointsIsMutable();
+ splitPoints_.add(value);
+ onChanged();
+ } else {
+ splitPointsBuilder_.addMessage(value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder addSplitPoints(
+ int index, com.google.spanner.admin.database.v1.SplitPoints value) {
+ if (splitPointsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureSplitPointsIsMutable();
+ splitPoints_.add(index, value);
+ onChanged();
+ } else {
+ splitPointsBuilder_.addMessage(index, value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder addSplitPoints(
+ com.google.spanner.admin.database.v1.SplitPoints.Builder builderForValue) {
+ if (splitPointsBuilder_ == null) {
+ ensureSplitPointsIsMutable();
+ splitPoints_.add(builderForValue.build());
+ onChanged();
+ } else {
+ splitPointsBuilder_.addMessage(builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder addSplitPoints(
+ int index, com.google.spanner.admin.database.v1.SplitPoints.Builder builderForValue) {
+ if (splitPointsBuilder_ == null) {
+ ensureSplitPointsIsMutable();
+ splitPoints_.add(index, builderForValue.build());
+ onChanged();
+ } else {
+ splitPointsBuilder_.addMessage(index, builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder addAllSplitPoints(
+ java.lang.Iterable extends com.google.spanner.admin.database.v1.SplitPoints> values) {
+ if (splitPointsBuilder_ == null) {
+ ensureSplitPointsIsMutable();
+ com.google.protobuf.AbstractMessageLite.Builder.addAll(values, splitPoints_);
+ onChanged();
+ } else {
+ splitPointsBuilder_.addAllMessages(values);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder clearSplitPoints() {
+ if (splitPointsBuilder_ == null) {
+ splitPoints_ = java.util.Collections.emptyList();
+ bitField0_ = (bitField0_ & ~0x00000002);
+ onChanged();
+ } else {
+ splitPointsBuilder_.clear();
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder removeSplitPoints(int index) {
+ if (splitPointsBuilder_ == null) {
+ ensureSplitPointsIsMutable();
+ splitPoints_.remove(index);
+ onChanged();
+ } else {
+ splitPointsBuilder_.remove(index);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.spanner.admin.database.v1.SplitPoints.Builder getSplitPointsBuilder(
+ int index) {
+ return getSplitPointsFieldBuilder().getBuilder(index);
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.spanner.admin.database.v1.SplitPointsOrBuilder getSplitPointsOrBuilder(
+ int index) {
+ if (splitPointsBuilder_ == null) {
+ return splitPoints_.get(index);
+ } else {
+ return splitPointsBuilder_.getMessageOrBuilder(index);
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public java.util.List extends com.google.spanner.admin.database.v1.SplitPointsOrBuilder>
+ getSplitPointsOrBuilderList() {
+ if (splitPointsBuilder_ != null) {
+ return splitPointsBuilder_.getMessageOrBuilderList();
+ } else {
+ return java.util.Collections.unmodifiableList(splitPoints_);
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.spanner.admin.database.v1.SplitPoints.Builder addSplitPointsBuilder() {
+ return getSplitPointsFieldBuilder()
+ .addBuilder(com.google.spanner.admin.database.v1.SplitPoints.getDefaultInstance());
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.spanner.admin.database.v1.SplitPoints.Builder addSplitPointsBuilder(
+ int index) {
+ return getSplitPointsFieldBuilder()
+ .addBuilder(index, com.google.spanner.admin.database.v1.SplitPoints.getDefaultInstance());
+ }
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public java.util.List+ * Optional. A user-supplied tag associated with the split points. + * For example, "intital_data_load", "special_event_1". + * Defaults to "CloudAddSplitPointsAPI" if not specified. + * The length of the tag must not exceed 50 characters,else will be trimmed. + * Only valid UTF8 characters are allowed. + *+ * + *
string initiator = 3 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The initiator.
+ */
+ public java.lang.String getInitiator() {
+ java.lang.Object ref = initiator_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ initiator_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. A user-supplied tag associated with the split points. + * For example, "intital_data_load", "special_event_1". + * Defaults to "CloudAddSplitPointsAPI" if not specified. + * The length of the tag must not exceed 50 characters,else will be trimmed. + * Only valid UTF8 characters are allowed. + *+ * + *
string initiator = 3 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The bytes for initiator.
+ */
+ public com.google.protobuf.ByteString getInitiatorBytes() {
+ java.lang.Object ref = initiator_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ initiator_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. A user-supplied tag associated with the split points. + * For example, "intital_data_load", "special_event_1". + * Defaults to "CloudAddSplitPointsAPI" if not specified. + * The length of the tag must not exceed 50 characters,else will be trimmed. + * Only valid UTF8 characters are allowed. + *+ * + *
string initiator = 3 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param value The initiator to set.
+ * @return This builder for chaining.
+ */
+ public Builder setInitiator(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ initiator_ = value;
+ bitField0_ |= 0x00000004;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. A user-supplied tag associated with the split points. + * For example, "intital_data_load", "special_event_1". + * Defaults to "CloudAddSplitPointsAPI" if not specified. + * The length of the tag must not exceed 50 characters,else will be trimmed. + * Only valid UTF8 characters are allowed. + *+ * + *
string initiator = 3 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearInitiator() {
+ initiator_ = getDefaultInstance().getInitiator();
+ bitField0_ = (bitField0_ & ~0x00000004);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. A user-supplied tag associated with the split points. + * For example, "intital_data_load", "special_event_1". + * Defaults to "CloudAddSplitPointsAPI" if not specified. + * The length of the tag must not exceed 50 characters,else will be trimmed. + * Only valid UTF8 characters are allowed. + *+ * + *
string initiator = 3 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param value The bytes for initiator to set.
+ * @return This builder for chaining.
+ */
+ public Builder setInitiatorBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+ initiator_ = value;
+ bitField0_ |= 0x00000004;
+ onChanged();
+ return this;
+ }
+
+ @java.lang.Override
+ public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.setUnknownFields(unknownFields);
+ }
+
+ @java.lang.Override
+ public final Builder mergeUnknownFields(
+ final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.mergeUnknownFields(unknownFields);
+ }
+
+ // @@protoc_insertion_point(builder_scope:google.spanner.admin.database.v1.AddSplitPointsRequest)
+ }
+
+ // @@protoc_insertion_point(class_scope:google.spanner.admin.database.v1.AddSplitPointsRequest)
+ private static final com.google.spanner.admin.database.v1.AddSplitPointsRequest DEFAULT_INSTANCE;
+
+ static {
+ DEFAULT_INSTANCE = new com.google.spanner.admin.database.v1.AddSplitPointsRequest();
+ }
+
+ public static com.google.spanner.admin.database.v1.AddSplitPointsRequest getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser+ * Required. The database on whose tables/indexes split points are to be + * added. Values are of the form + * `projects/<project>/instances/<instance>/databases/<database>`. + *+ * + *
+ * string database = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The database.
+ */
+ java.lang.String getDatabase();
+ /**
+ *
+ *
+ * + * Required. The database on whose tables/indexes split points are to be + * added. Values are of the form + * `projects/<project>/instances/<instance>/databases/<database>`. + *+ * + *
+ * string database = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The bytes for database.
+ */
+ com.google.protobuf.ByteString getDatabaseBytes();
+
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ java.util.List+ * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ com.google.spanner.admin.database.v1.SplitPoints getSplitPoints(int index);
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ int getSplitPointsCount();
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ java.util.List extends com.google.spanner.admin.database.v1.SplitPointsOrBuilder>
+ getSplitPointsOrBuilderList();
+ /**
+ *
+ *
+ * + * Required. The split points to add. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints split_points = 2 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ com.google.spanner.admin.database.v1.SplitPointsOrBuilder getSplitPointsOrBuilder(int index);
+
+ /**
+ *
+ *
+ * + * Optional. A user-supplied tag associated with the split points. + * For example, "intital_data_load", "special_event_1". + * Defaults to "CloudAddSplitPointsAPI" if not specified. + * The length of the tag must not exceed 50 characters,else will be trimmed. + * Only valid UTF8 characters are allowed. + *+ * + *
string initiator = 3 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The initiator.
+ */
+ java.lang.String getInitiator();
+ /**
+ *
+ *
+ * + * Optional. A user-supplied tag associated with the split points. + * For example, "intital_data_load", "special_event_1". + * Defaults to "CloudAddSplitPointsAPI" if not specified. + * The length of the tag must not exceed 50 characters,else will be trimmed. + * Only valid UTF8 characters are allowed. + *+ * + *
string initiator = 3 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The bytes for initiator.
+ */
+ com.google.protobuf.ByteString getInitiatorBytes();
+}
diff --git a/proto-google-cloud-spanner-admin-database-v1/src/main/java/com/google/spanner/admin/database/v1/AddSplitPointsResponse.java b/proto-google-cloud-spanner-admin-database-v1/src/main/java/com/google/spanner/admin/database/v1/AddSplitPointsResponse.java
new file mode 100644
index 00000000000..a78c8b880e4
--- /dev/null
+++ b/proto-google-cloud-spanner-admin-database-v1/src/main/java/com/google/spanner/admin/database/v1/AddSplitPointsResponse.java
@@ -0,0 +1,435 @@
+/*
+ * Copyright 2025 Google LLC
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * https://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: google/spanner/admin/database/v1/spanner_database_admin.proto
+
+// Protobuf Java Version: 3.25.5
+package com.google.spanner.admin.database.v1;
+
+/**
+ *
+ *
+ * + * The response for + * [AddSplitPoints][google.spanner.admin.database.v1.DatabaseAdmin.AddSplitPoints]. + *+ * + * Protobuf type {@code google.spanner.admin.database.v1.AddSplitPointsResponse} + */ +public final class AddSplitPointsResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.spanner.admin.database.v1.AddSplitPointsResponse) + AddSplitPointsResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use AddSplitPointsResponse.newBuilder() to construct. + private AddSplitPointsResponse(com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + + private AddSplitPointsResponse() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new AddSplitPointsResponse(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.spanner.admin.database.v1.SpannerDatabaseAdminProto + .internal_static_google_spanner_admin_database_v1_AddSplitPointsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.spanner.admin.database.v1.SpannerDatabaseAdminProto + .internal_static_google_spanner_admin_database_v1_AddSplitPointsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.spanner.admin.database.v1.AddSplitPointsResponse.class, + com.google.spanner.admin.database.v1.AddSplitPointsResponse.Builder.class); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.spanner.admin.database.v1.AddSplitPointsResponse)) { + return super.equals(obj); + } + com.google.spanner.admin.database.v1.AddSplitPointsResponse other = + (com.google.spanner.admin.database.v1.AddSplitPointsResponse) obj; + + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.spanner.admin.database.v1.AddSplitPointsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.spanner.admin.database.v1.AddSplitPointsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+ * The response for + * [AddSplitPoints][google.spanner.admin.database.v1.DatabaseAdmin.AddSplitPoints]. + *+ * + * Protobuf type {@code google.spanner.admin.database.v1.AddSplitPointsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+ * The split points of a table/index. + *+ * + * Protobuf type {@code google.spanner.admin.database.v1.SplitPoints} + */ +public final class SplitPoints extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.spanner.admin.database.v1.SplitPoints) + SplitPointsOrBuilder { + private static final long serialVersionUID = 0L; + // Use SplitPoints.newBuilder() to construct. + private SplitPoints(com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + + private SplitPoints() { + table_ = ""; + index_ = ""; + keys_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SplitPoints(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.spanner.admin.database.v1.SpannerDatabaseAdminProto + .internal_static_google_spanner_admin_database_v1_SplitPoints_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.spanner.admin.database.v1.SpannerDatabaseAdminProto + .internal_static_google_spanner_admin_database_v1_SplitPoints_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.spanner.admin.database.v1.SplitPoints.class, + com.google.spanner.admin.database.v1.SplitPoints.Builder.class); + } + + public interface KeyOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.spanner.admin.database.v1.SplitPoints.Key) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+ * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ *
+ * @return Whether the keyParts field is set.
+ */
+ boolean hasKeyParts();
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ *
+ * @return The keyParts.
+ */
+ com.google.protobuf.ListValue getKeyParts();
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ com.google.protobuf.ListValueOrBuilder getKeyPartsOrBuilder();
+ }
+ /**
+ *
+ *
+ * + * A split key. + *+ * + * Protobuf type {@code google.spanner.admin.database.v1.SplitPoints.Key} + */ + public static final class Key extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.spanner.admin.database.v1.SplitPoints.Key) + KeyOrBuilder { + private static final long serialVersionUID = 0L; + // Use Key.newBuilder() to construct. + private Key(com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + + private Key() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Key(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.spanner.admin.database.v1.SpannerDatabaseAdminProto + .internal_static_google_spanner_admin_database_v1_SplitPoints_Key_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.spanner.admin.database.v1.SpannerDatabaseAdminProto + .internal_static_google_spanner_admin_database_v1_SplitPoints_Key_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.spanner.admin.database.v1.SplitPoints.Key.class, + com.google.spanner.admin.database.v1.SplitPoints.Key.Builder.class); + } + + private int bitField0_; + public static final int KEY_PARTS_FIELD_NUMBER = 1; + private com.google.protobuf.ListValue keyParts_; + /** + * + * + *
+ * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ *
+ * @return Whether the keyParts field is set.
+ */
+ @java.lang.Override
+ public boolean hasKeyParts() {
+ return ((bitField0_ & 0x00000001) != 0);
+ }
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ *
+ * @return The keyParts.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ListValue getKeyParts() {
+ return keyParts_ == null ? com.google.protobuf.ListValue.getDefaultInstance() : keyParts_;
+ }
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ @java.lang.Override
+ public com.google.protobuf.ListValueOrBuilder getKeyPartsOrBuilder() {
+ return keyParts_ == null ? com.google.protobuf.ListValue.getDefaultInstance() : keyParts_;
+ }
+
+ private byte memoizedIsInitialized = -1;
+
+ @java.lang.Override
+ public final boolean isInitialized() {
+ byte isInitialized = memoizedIsInitialized;
+ if (isInitialized == 1) return true;
+ if (isInitialized == 0) return false;
+
+ memoizedIsInitialized = 1;
+ return true;
+ }
+
+ @java.lang.Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
+ if (((bitField0_ & 0x00000001) != 0)) {
+ output.writeMessage(1, getKeyParts());
+ }
+ getUnknownFields().writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (((bitField0_ & 0x00000001) != 0)) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getKeyParts());
+ }
+ size += getUnknownFields().getSerializedSize();
+ memoizedSize = size;
+ return size;
+ }
+
+ @java.lang.Override
+ public boolean equals(final java.lang.Object obj) {
+ if (obj == this) {
+ return true;
+ }
+ if (!(obj instanceof com.google.spanner.admin.database.v1.SplitPoints.Key)) {
+ return super.equals(obj);
+ }
+ com.google.spanner.admin.database.v1.SplitPoints.Key other =
+ (com.google.spanner.admin.database.v1.SplitPoints.Key) obj;
+
+ if (hasKeyParts() != other.hasKeyParts()) return false;
+ if (hasKeyParts()) {
+ if (!getKeyParts().equals(other.getKeyParts())) return false;
+ }
+ if (!getUnknownFields().equals(other.getUnknownFields())) return false;
+ return true;
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ if (memoizedHashCode != 0) {
+ return memoizedHashCode;
+ }
+ int hash = 41;
+ hash = (19 * hash) + getDescriptor().hashCode();
+ if (hasKeyParts()) {
+ hash = (37 * hash) + KEY_PARTS_FIELD_NUMBER;
+ hash = (53 * hash) + getKeyParts().hashCode();
+ }
+ hash = (29 * hash) + getUnknownFields().hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseFrom(
+ java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseFrom(
+ java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseFrom(
+ com.google.protobuf.ByteString data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseFrom(
+ byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseDelimitedFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseDelimitedFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseFrom(
+ com.google.protobuf.CodedInputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key parseFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ @java.lang.Override
+ public Builder newBuilderForType() {
+ return newBuilder();
+ }
+
+ public static Builder newBuilder() {
+ return DEFAULT_INSTANCE.toBuilder();
+ }
+
+ public static Builder newBuilder(
+ com.google.spanner.admin.database.v1.SplitPoints.Key prototype) {
+ return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
+ }
+
+ @java.lang.Override
+ public Builder toBuilder() {
+ return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
+ }
+
+ @java.lang.Override
+ protected Builder newBuilderForType(
+ com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+ Builder builder = new Builder(parent);
+ return builder;
+ }
+ /**
+ *
+ *
+ * + * A split key. + *+ * + * Protobuf type {@code google.spanner.admin.database.v1.SplitPoints.Key} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder
+ * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ *
+ * @return Whether the keyParts field is set.
+ */
+ public boolean hasKeyParts() {
+ return ((bitField0_ & 0x00000001) != 0);
+ }
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ *
+ * @return The keyParts.
+ */
+ public com.google.protobuf.ListValue getKeyParts() {
+ if (keyPartsBuilder_ == null) {
+ return keyParts_ == null ? com.google.protobuf.ListValue.getDefaultInstance() : keyParts_;
+ } else {
+ return keyPartsBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder setKeyParts(com.google.protobuf.ListValue value) {
+ if (keyPartsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ keyParts_ = value;
+ } else {
+ keyPartsBuilder_.setMessage(value);
+ }
+ bitField0_ |= 0x00000001;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder setKeyParts(com.google.protobuf.ListValue.Builder builderForValue) {
+ if (keyPartsBuilder_ == null) {
+ keyParts_ = builderForValue.build();
+ } else {
+ keyPartsBuilder_.setMessage(builderForValue.build());
+ }
+ bitField0_ |= 0x00000001;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder mergeKeyParts(com.google.protobuf.ListValue value) {
+ if (keyPartsBuilder_ == null) {
+ if (((bitField0_ & 0x00000001) != 0)
+ && keyParts_ != null
+ && keyParts_ != com.google.protobuf.ListValue.getDefaultInstance()) {
+ getKeyPartsBuilder().mergeFrom(value);
+ } else {
+ keyParts_ = value;
+ }
+ } else {
+ keyPartsBuilder_.mergeFrom(value);
+ }
+ if (keyParts_ != null) {
+ bitField0_ |= 0x00000001;
+ onChanged();
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder clearKeyParts() {
+ bitField0_ = (bitField0_ & ~0x00000001);
+ keyParts_ = null;
+ if (keyPartsBuilder_ != null) {
+ keyPartsBuilder_.dispose();
+ keyPartsBuilder_ = null;
+ }
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.protobuf.ListValue.Builder getKeyPartsBuilder() {
+ bitField0_ |= 0x00000001;
+ onChanged();
+ return getKeyPartsFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.protobuf.ListValueOrBuilder getKeyPartsOrBuilder() {
+ if (keyPartsBuilder_ != null) {
+ return keyPartsBuilder_.getMessageOrBuilder();
+ } else {
+ return keyParts_ == null ? com.google.protobuf.ListValue.getDefaultInstance() : keyParts_;
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The column values making up the split key. + *+ * + *
.google.protobuf.ListValue key_parts = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.protobuf.ListValue,
+ com.google.protobuf.ListValue.Builder,
+ com.google.protobuf.ListValueOrBuilder>
+ getKeyPartsFieldBuilder() {
+ if (keyPartsBuilder_ == null) {
+ keyPartsBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.protobuf.ListValue,
+ com.google.protobuf.ListValue.Builder,
+ com.google.protobuf.ListValueOrBuilder>(
+ getKeyParts(), getParentForChildren(), isClean());
+ keyParts_ = null;
+ }
+ return keyPartsBuilder_;
+ }
+
+ @java.lang.Override
+ public final Builder setUnknownFields(
+ final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.setUnknownFields(unknownFields);
+ }
+
+ @java.lang.Override
+ public final Builder mergeUnknownFields(
+ final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.mergeUnknownFields(unknownFields);
+ }
+
+ // @@protoc_insertion_point(builder_scope:google.spanner.admin.database.v1.SplitPoints.Key)
+ }
+
+ // @@protoc_insertion_point(class_scope:google.spanner.admin.database.v1.SplitPoints.Key)
+ private static final com.google.spanner.admin.database.v1.SplitPoints.Key DEFAULT_INSTANCE;
+
+ static {
+ DEFAULT_INSTANCE = new com.google.spanner.admin.database.v1.SplitPoints.Key();
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints.Key getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser+ * The table to split. + *+ * + *
string table = 1;
+ *
+ * @return The table.
+ */
+ @java.lang.Override
+ public java.lang.String getTable() {
+ java.lang.Object ref = table_;
+ if (ref instanceof java.lang.String) {
+ return (java.lang.String) ref;
+ } else {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ table_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * The table to split. + *+ * + *
string table = 1;
+ *
+ * @return The bytes for table.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getTableBytes() {
+ java.lang.Object ref = table_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ table_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int INDEX_FIELD_NUMBER = 2;
+
+ @SuppressWarnings("serial")
+ private volatile java.lang.Object index_ = "";
+ /**
+ *
+ *
+ * + * The index to split. + * If specified, the `table` field must refer to the index's base table. + *+ * + *
string index = 2;
+ *
+ * @return The index.
+ */
+ @java.lang.Override
+ public java.lang.String getIndex() {
+ java.lang.Object ref = index_;
+ if (ref instanceof java.lang.String) {
+ return (java.lang.String) ref;
+ } else {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ index_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * The index to split. + * If specified, the `table` field must refer to the index's base table. + *+ * + *
string index = 2;
+ *
+ * @return The bytes for index.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getIndexBytes() {
+ java.lang.Object ref = index_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ index_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int KEYS_FIELD_NUMBER = 3;
+
+ @SuppressWarnings("serial")
+ private java.util.List+ * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ @java.lang.Override
+ public java.util.List+ * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ @java.lang.Override
+ public java.util.List extends com.google.spanner.admin.database.v1.SplitPoints.KeyOrBuilder>
+ getKeysOrBuilderList() {
+ return keys_;
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ @java.lang.Override
+ public int getKeysCount() {
+ return keys_.size();
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ @java.lang.Override
+ public com.google.spanner.admin.database.v1.SplitPoints.Key getKeys(int index) {
+ return keys_.get(index);
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ @java.lang.Override
+ public com.google.spanner.admin.database.v1.SplitPoints.KeyOrBuilder getKeysOrBuilder(int index) {
+ return keys_.get(index);
+ }
+
+ public static final int EXPIRE_TIME_FIELD_NUMBER = 5;
+ private com.google.protobuf.Timestamp expireTime_;
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ *
+ * @return Whether the expireTime field is set.
+ */
+ @java.lang.Override
+ public boolean hasExpireTime() {
+ return ((bitField0_ & 0x00000001) != 0);
+ }
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ *
+ * @return The expireTime.
+ */
+ @java.lang.Override
+ public com.google.protobuf.Timestamp getExpireTime() {
+ return expireTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : expireTime_;
+ }
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ */
+ @java.lang.Override
+ public com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder() {
+ return expireTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : expireTime_;
+ }
+
+ private byte memoizedIsInitialized = -1;
+
+ @java.lang.Override
+ public final boolean isInitialized() {
+ byte isInitialized = memoizedIsInitialized;
+ if (isInitialized == 1) return true;
+ if (isInitialized == 0) return false;
+
+ memoizedIsInitialized = 1;
+ return true;
+ }
+
+ @java.lang.Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(table_)) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 1, table_);
+ }
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(index_)) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 2, index_);
+ }
+ for (int i = 0; i < keys_.size(); i++) {
+ output.writeMessage(3, keys_.get(i));
+ }
+ if (((bitField0_ & 0x00000001) != 0)) {
+ output.writeMessage(5, getExpireTime());
+ }
+ getUnknownFields().writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(table_)) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, table_);
+ }
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(index_)) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, index_);
+ }
+ for (int i = 0; i < keys_.size(); i++) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, keys_.get(i));
+ }
+ if (((bitField0_ & 0x00000001) != 0)) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getExpireTime());
+ }
+ size += getUnknownFields().getSerializedSize();
+ memoizedSize = size;
+ return size;
+ }
+
+ @java.lang.Override
+ public boolean equals(final java.lang.Object obj) {
+ if (obj == this) {
+ return true;
+ }
+ if (!(obj instanceof com.google.spanner.admin.database.v1.SplitPoints)) {
+ return super.equals(obj);
+ }
+ com.google.spanner.admin.database.v1.SplitPoints other =
+ (com.google.spanner.admin.database.v1.SplitPoints) obj;
+
+ if (!getTable().equals(other.getTable())) return false;
+ if (!getIndex().equals(other.getIndex())) return false;
+ if (!getKeysList().equals(other.getKeysList())) return false;
+ if (hasExpireTime() != other.hasExpireTime()) return false;
+ if (hasExpireTime()) {
+ if (!getExpireTime().equals(other.getExpireTime())) return false;
+ }
+ if (!getUnknownFields().equals(other.getUnknownFields())) return false;
+ return true;
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ if (memoizedHashCode != 0) {
+ return memoizedHashCode;
+ }
+ int hash = 41;
+ hash = (19 * hash) + getDescriptor().hashCode();
+ hash = (37 * hash) + TABLE_FIELD_NUMBER;
+ hash = (53 * hash) + getTable().hashCode();
+ hash = (37 * hash) + INDEX_FIELD_NUMBER;
+ hash = (53 * hash) + getIndex().hashCode();
+ if (getKeysCount() > 0) {
+ hash = (37 * hash) + KEYS_FIELD_NUMBER;
+ hash = (53 * hash) + getKeysList().hashCode();
+ }
+ if (hasExpireTime()) {
+ hash = (37 * hash) + EXPIRE_TIME_FIELD_NUMBER;
+ hash = (53 * hash) + getExpireTime().hashCode();
+ }
+ hash = (29 * hash) + getUnknownFields().hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseFrom(java.nio.ByteBuffer data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseFrom(
+ java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseFrom(
+ com.google.protobuf.ByteString data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseFrom(
+ byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseDelimitedFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseDelimitedFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseFrom(
+ com.google.protobuf.CodedInputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints parseFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ @java.lang.Override
+ public Builder newBuilderForType() {
+ return newBuilder();
+ }
+
+ public static Builder newBuilder() {
+ return DEFAULT_INSTANCE.toBuilder();
+ }
+
+ public static Builder newBuilder(com.google.spanner.admin.database.v1.SplitPoints prototype) {
+ return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
+ }
+
+ @java.lang.Override
+ public Builder toBuilder() {
+ return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
+ }
+
+ @java.lang.Override
+ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+ Builder builder = new Builder(parent);
+ return builder;
+ }
+ /**
+ *
+ *
+ * + * The split points of a table/index. + *+ * + * Protobuf type {@code google.spanner.admin.database.v1.SplitPoints} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+ * The table to split. + *+ * + *
string table = 1;
+ *
+ * @return The table.
+ */
+ public java.lang.String getTable() {
+ java.lang.Object ref = table_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ table_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The table to split. + *+ * + *
string table = 1;
+ *
+ * @return The bytes for table.
+ */
+ public com.google.protobuf.ByteString getTableBytes() {
+ java.lang.Object ref = table_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ table_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The table to split. + *+ * + *
string table = 1;
+ *
+ * @param value The table to set.
+ * @return This builder for chaining.
+ */
+ public Builder setTable(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ table_ = value;
+ bitField0_ |= 0x00000001;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The table to split. + *+ * + *
string table = 1;
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearTable() {
+ table_ = getDefaultInstance().getTable();
+ bitField0_ = (bitField0_ & ~0x00000001);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The table to split. + *+ * + *
string table = 1;
+ *
+ * @param value The bytes for table to set.
+ * @return This builder for chaining.
+ */
+ public Builder setTableBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+ table_ = value;
+ bitField0_ |= 0x00000001;
+ onChanged();
+ return this;
+ }
+
+ private java.lang.Object index_ = "";
+ /**
+ *
+ *
+ * + * The index to split. + * If specified, the `table` field must refer to the index's base table. + *+ * + *
string index = 2;
+ *
+ * @return The index.
+ */
+ public java.lang.String getIndex() {
+ java.lang.Object ref = index_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ index_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The index to split. + * If specified, the `table` field must refer to the index's base table. + *+ * + *
string index = 2;
+ *
+ * @return The bytes for index.
+ */
+ public com.google.protobuf.ByteString getIndexBytes() {
+ java.lang.Object ref = index_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ index_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The index to split. + * If specified, the `table` field must refer to the index's base table. + *+ * + *
string index = 2;
+ *
+ * @param value The index to set.
+ * @return This builder for chaining.
+ */
+ public Builder setIndex(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ index_ = value;
+ bitField0_ |= 0x00000002;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The index to split. + * If specified, the `table` field must refer to the index's base table. + *+ * + *
string index = 2;
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearIndex() {
+ index_ = getDefaultInstance().getIndex();
+ bitField0_ = (bitField0_ & ~0x00000002);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The index to split. + * If specified, the `table` field must refer to the index's base table. + *+ * + *
string index = 2;
+ *
+ * @param value The bytes for index to set.
+ * @return This builder for chaining.
+ */
+ public Builder setIndexBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+ index_ = value;
+ bitField0_ |= 0x00000002;
+ onChanged();
+ return this;
+ }
+
+ private java.util.List+ * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public java.util.List+ * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public int getKeysCount() {
+ if (keysBuilder_ == null) {
+ return keys_.size();
+ } else {
+ return keysBuilder_.getCount();
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.spanner.admin.database.v1.SplitPoints.Key getKeys(int index) {
+ if (keysBuilder_ == null) {
+ return keys_.get(index);
+ } else {
+ return keysBuilder_.getMessage(index);
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder setKeys(int index, com.google.spanner.admin.database.v1.SplitPoints.Key value) {
+ if (keysBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureKeysIsMutable();
+ keys_.set(index, value);
+ onChanged();
+ } else {
+ keysBuilder_.setMessage(index, value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder setKeys(
+ int index, com.google.spanner.admin.database.v1.SplitPoints.Key.Builder builderForValue) {
+ if (keysBuilder_ == null) {
+ ensureKeysIsMutable();
+ keys_.set(index, builderForValue.build());
+ onChanged();
+ } else {
+ keysBuilder_.setMessage(index, builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder addKeys(com.google.spanner.admin.database.v1.SplitPoints.Key value) {
+ if (keysBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureKeysIsMutable();
+ keys_.add(value);
+ onChanged();
+ } else {
+ keysBuilder_.addMessage(value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder addKeys(int index, com.google.spanner.admin.database.v1.SplitPoints.Key value) {
+ if (keysBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureKeysIsMutable();
+ keys_.add(index, value);
+ onChanged();
+ } else {
+ keysBuilder_.addMessage(index, value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder addKeys(
+ com.google.spanner.admin.database.v1.SplitPoints.Key.Builder builderForValue) {
+ if (keysBuilder_ == null) {
+ ensureKeysIsMutable();
+ keys_.add(builderForValue.build());
+ onChanged();
+ } else {
+ keysBuilder_.addMessage(builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder addKeys(
+ int index, com.google.spanner.admin.database.v1.SplitPoints.Key.Builder builderForValue) {
+ if (keysBuilder_ == null) {
+ ensureKeysIsMutable();
+ keys_.add(index, builderForValue.build());
+ onChanged();
+ } else {
+ keysBuilder_.addMessage(index, builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder addAllKeys(
+ java.lang.Iterable extends com.google.spanner.admin.database.v1.SplitPoints.Key> values) {
+ if (keysBuilder_ == null) {
+ ensureKeysIsMutable();
+ com.google.protobuf.AbstractMessageLite.Builder.addAll(values, keys_);
+ onChanged();
+ } else {
+ keysBuilder_.addAllMessages(values);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder clearKeys() {
+ if (keysBuilder_ == null) {
+ keys_ = java.util.Collections.emptyList();
+ bitField0_ = (bitField0_ & ~0x00000004);
+ onChanged();
+ } else {
+ keysBuilder_.clear();
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public Builder removeKeys(int index) {
+ if (keysBuilder_ == null) {
+ ensureKeysIsMutable();
+ keys_.remove(index);
+ onChanged();
+ } else {
+ keysBuilder_.remove(index);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.spanner.admin.database.v1.SplitPoints.Key.Builder getKeysBuilder(int index) {
+ return getKeysFieldBuilder().getBuilder(index);
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.spanner.admin.database.v1.SplitPoints.KeyOrBuilder getKeysOrBuilder(
+ int index) {
+ if (keysBuilder_ == null) {
+ return keys_.get(index);
+ } else {
+ return keysBuilder_.getMessageOrBuilder(index);
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public java.util.List extends com.google.spanner.admin.database.v1.SplitPoints.KeyOrBuilder>
+ getKeysOrBuilderList() {
+ if (keysBuilder_ != null) {
+ return keysBuilder_.getMessageOrBuilderList();
+ } else {
+ return java.util.Collections.unmodifiableList(keys_);
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.spanner.admin.database.v1.SplitPoints.Key.Builder addKeysBuilder() {
+ return getKeysFieldBuilder()
+ .addBuilder(com.google.spanner.admin.database.v1.SplitPoints.Key.getDefaultInstance());
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public com.google.spanner.admin.database.v1.SplitPoints.Key.Builder addKeysBuilder(int index) {
+ return getKeysFieldBuilder()
+ .addBuilder(
+ index, com.google.spanner.admin.database.v1.SplitPoints.Key.getDefaultInstance());
+ }
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ public java.util.List+ * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ *
+ * @return Whether the expireTime field is set.
+ */
+ public boolean hasExpireTime() {
+ return ((bitField0_ & 0x00000008) != 0);
+ }
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ *
+ * @return The expireTime.
+ */
+ public com.google.protobuf.Timestamp getExpireTime() {
+ if (expireTimeBuilder_ == null) {
+ return expireTime_ == null
+ ? com.google.protobuf.Timestamp.getDefaultInstance()
+ : expireTime_;
+ } else {
+ return expireTimeBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ */
+ public Builder setExpireTime(com.google.protobuf.Timestamp value) {
+ if (expireTimeBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ expireTime_ = value;
+ } else {
+ expireTimeBuilder_.setMessage(value);
+ }
+ bitField0_ |= 0x00000008;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ */
+ public Builder setExpireTime(com.google.protobuf.Timestamp.Builder builderForValue) {
+ if (expireTimeBuilder_ == null) {
+ expireTime_ = builderForValue.build();
+ } else {
+ expireTimeBuilder_.setMessage(builderForValue.build());
+ }
+ bitField0_ |= 0x00000008;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ */
+ public Builder mergeExpireTime(com.google.protobuf.Timestamp value) {
+ if (expireTimeBuilder_ == null) {
+ if (((bitField0_ & 0x00000008) != 0)
+ && expireTime_ != null
+ && expireTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) {
+ getExpireTimeBuilder().mergeFrom(value);
+ } else {
+ expireTime_ = value;
+ }
+ } else {
+ expireTimeBuilder_.mergeFrom(value);
+ }
+ if (expireTime_ != null) {
+ bitField0_ |= 0x00000008;
+ onChanged();
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ */
+ public Builder clearExpireTime() {
+ bitField0_ = (bitField0_ & ~0x00000008);
+ expireTime_ = null;
+ if (expireTimeBuilder_ != null) {
+ expireTimeBuilder_.dispose();
+ expireTimeBuilder_ = null;
+ }
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ */
+ public com.google.protobuf.Timestamp.Builder getExpireTimeBuilder() {
+ bitField0_ |= 0x00000008;
+ onChanged();
+ return getExpireTimeFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ */
+ public com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder() {
+ if (expireTimeBuilder_ != null) {
+ return expireTimeBuilder_.getMessageOrBuilder();
+ } else {
+ return expireTime_ == null
+ ? com.google.protobuf.Timestamp.getDefaultInstance()
+ : expireTime_;
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.protobuf.Timestamp,
+ com.google.protobuf.Timestamp.Builder,
+ com.google.protobuf.TimestampOrBuilder>
+ getExpireTimeFieldBuilder() {
+ if (expireTimeBuilder_ == null) {
+ expireTimeBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.protobuf.Timestamp,
+ com.google.protobuf.Timestamp.Builder,
+ com.google.protobuf.TimestampOrBuilder>(
+ getExpireTime(), getParentForChildren(), isClean());
+ expireTime_ = null;
+ }
+ return expireTimeBuilder_;
+ }
+
+ @java.lang.Override
+ public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.setUnknownFields(unknownFields);
+ }
+
+ @java.lang.Override
+ public final Builder mergeUnknownFields(
+ final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.mergeUnknownFields(unknownFields);
+ }
+
+ // @@protoc_insertion_point(builder_scope:google.spanner.admin.database.v1.SplitPoints)
+ }
+
+ // @@protoc_insertion_point(class_scope:google.spanner.admin.database.v1.SplitPoints)
+ private static final com.google.spanner.admin.database.v1.SplitPoints DEFAULT_INSTANCE;
+
+ static {
+ DEFAULT_INSTANCE = new com.google.spanner.admin.database.v1.SplitPoints();
+ }
+
+ public static com.google.spanner.admin.database.v1.SplitPoints getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser+ * The table to split. + *+ * + *
string table = 1;
+ *
+ * @return The table.
+ */
+ java.lang.String getTable();
+ /**
+ *
+ *
+ * + * The table to split. + *+ * + *
string table = 1;
+ *
+ * @return The bytes for table.
+ */
+ com.google.protobuf.ByteString getTableBytes();
+
+ /**
+ *
+ *
+ * + * The index to split. + * If specified, the `table` field must refer to the index's base table. + *+ * + *
string index = 2;
+ *
+ * @return The index.
+ */
+ java.lang.String getIndex();
+ /**
+ *
+ *
+ * + * The index to split. + * If specified, the `table` field must refer to the index's base table. + *+ * + *
string index = 2;
+ *
+ * @return The bytes for index.
+ */
+ com.google.protobuf.ByteString getIndexBytes();
+
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ java.util.List+ * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ com.google.spanner.admin.database.v1.SplitPoints.Key getKeys(int index);
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ int getKeysCount();
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ java.util.List extends com.google.spanner.admin.database.v1.SplitPoints.KeyOrBuilder>
+ getKeysOrBuilderList();
+ /**
+ *
+ *
+ * + * Required. The list of split keys, i.e., the split boundaries. + *+ * + *
+ * repeated .google.spanner.admin.database.v1.SplitPoints.Key keys = 3 [(.google.api.field_behavior) = REQUIRED];
+ *
+ */
+ com.google.spanner.admin.database.v1.SplitPoints.KeyOrBuilder getKeysOrBuilder(int index);
+
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ *
+ * @return Whether the expireTime field is set.
+ */
+ boolean hasExpireTime();
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ *
+ * @return The expireTime.
+ */
+ com.google.protobuf.Timestamp getExpireTime();
+ /**
+ *
+ *
+ * + * Optional. The expiration timestamp of the split points. + * A timestamp in the past means immediate expiration. + * The maximum value can be 30 days in the future. + * Defaults to 10 days in the future if not specified. + *+ * + *
.google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ */
+ com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder();
+}
diff --git a/proto-google-cloud-spanner-admin-database-v1/src/main/proto/google/spanner/admin/database/v1/spanner_database_admin.proto b/proto-google-cloud-spanner-admin-database-v1/src/main/proto/google/spanner/admin/database/v1/spanner_database_admin.proto
index 5df142403e6..27e3206293e 100644
--- a/proto-google-cloud-spanner-admin-database-v1/src/main/proto/google/spanner/admin/database/v1/spanner_database_admin.proto
+++ b/proto-google-cloud-spanner-admin-database-v1/src/main/proto/google/spanner/admin/database/v1/spanner_database_admin.proto
@@ -25,6 +25,7 @@ import "google/iam/v1/policy.proto";
import "google/longrunning/operations.proto";
import "google/protobuf/empty.proto";
import "google/protobuf/field_mask.proto";
+import "google/protobuf/struct.proto";
import "google/protobuf/timestamp.proto";
import "google/spanner/admin/database/v1/backup.proto";
import "google/spanner/admin/database/v1/backup_schedule.proto";
@@ -425,6 +426,15 @@ service DatabaseAdmin {
option (google.api.method_signature) = "parent";
}
+ // Adds split points to specified tables, indexes of a database.
+ rpc AddSplitPoints(AddSplitPointsRequest) returns (AddSplitPointsResponse) {
+ option (google.api.http) = {
+ post: "/v1/{database=projects/*/instances/*/databases/*}:addSplitPoints"
+ body: "*"
+ };
+ option (google.api.method_signature) = "database,split_points";
+ }
+
// Creates a new backup schedule.
rpc CreateBackupSchedule(CreateBackupScheduleRequest)
returns (BackupSchedule) {
@@ -1207,3 +1217,59 @@ message ListDatabaseRolesResponse {
// call to fetch more of the matching roles.
string next_page_token = 2;
}
+
+// The request for
+// [AddSplitPoints][google.spanner.admin.database.v1.DatabaseAdmin.AddSplitPoints].
+message AddSplitPointsRequest {
+ // Required. The database on whose tables/indexes split points are to be
+ // added. Values are of the form
+ // `projects/