Skip to content

Commit 08c5bf1

Browse files
feat: Adding feature flags for routing cookie and retry info (#2031)
* feat: Modify ModifyColumnFamiliesRequest proto to expose ignore_warnings field PiperOrigin-RevId: 590940407 Source-Link: googleapis/googleapis@fb027c8 Source-Link: https://github.com/googleapis/googleapis-gen/commit/f0728cda227b38835822c4e5519e568ce8d2b5ac Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiZjA3MjhjZGEyMjdiMzg4MzU4MjJjNGU1NTE5ZTU2OGNlOGQyYjVhYyJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * feat: Adding feature flags for routing cookie and retry info PiperOrigin-RevId: 591912877 Source-Link: googleapis/googleapis@f6505fe Source-Link: https://github.com/googleapis/googleapis-gen/commit/7499187415f8d405ef0d46dd6ff608b125c53c8f Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNzQ5OTE4NzQxNWY4ZDQwNWVmMGQ0NmRkNmZmNjA4YjEyNWM1M2M4ZiJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
1 parent f1b7fc7 commit 08c5bf1

File tree

9 files changed

+567
-222
lines changed

9 files changed

+567
-222
lines changed

google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminClient.java

+2
Original file line numberDiff line numberDiff line change
@@ -1396,6 +1396,7 @@ public final Table modifyColumnFamilies(
13961396
* ModifyColumnFamiliesRequest.newBuilder()
13971397
* .setName(TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]").toString())
13981398
* .addAllModifications(new ArrayList<ModifyColumnFamiliesRequest.Modification>())
1399+
* .setIgnoreWarnings(true)
13991400
* .build();
14001401
* Table response = baseBigtableTableAdminClient.modifyColumnFamilies(request);
14011402
* }
@@ -1428,6 +1429,7 @@ public final Table modifyColumnFamilies(ModifyColumnFamiliesRequest request) {
14281429
* ModifyColumnFamiliesRequest.newBuilder()
14291430
* .setName(TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]").toString())
14301431
* .addAllModifications(new ArrayList<ModifyColumnFamiliesRequest.Modification>())
1432+
* .setIgnoreWarnings(true)
14311433
* .build();
14321434
* ApiFuture<Table> future =
14331435
* baseBigtableTableAdminClient.modifyColumnFamiliesCallable().futureCall(request);

proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BigtableTableAdminProto.java

+216-215
Large diffs are not rendered by default.

proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ModifyColumnFamiliesRequest.java

+93
Original file line numberDiff line numberDiff line change
@@ -1819,6 +1819,24 @@ public com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification get
18191819
return modifications_.get(index);
18201820
}
18211821

1822+
public static final int IGNORE_WARNINGS_FIELD_NUMBER = 3;
1823+
private boolean ignoreWarnings_ = false;
1824+
/**
1825+
*
1826+
*
1827+
* <pre>
1828+
* Optional. If true, ignore safety checks when modifying the column families.
1829+
* </pre>
1830+
*
1831+
* <code>bool ignore_warnings = 3 [(.google.api.field_behavior) = OPTIONAL];</code>
1832+
*
1833+
* @return The ignoreWarnings.
1834+
*/
1835+
@java.lang.Override
1836+
public boolean getIgnoreWarnings() {
1837+
return ignoreWarnings_;
1838+
}
1839+
18221840
private byte memoizedIsInitialized = -1;
18231841

18241842
@java.lang.Override
@@ -1839,6 +1857,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
18391857
for (int i = 0; i < modifications_.size(); i++) {
18401858
output.writeMessage(2, modifications_.get(i));
18411859
}
1860+
if (ignoreWarnings_ != false) {
1861+
output.writeBool(3, ignoreWarnings_);
1862+
}
18421863
getUnknownFields().writeTo(output);
18431864
}
18441865

@@ -1854,6 +1875,9 @@ public int getSerializedSize() {
18541875
for (int i = 0; i < modifications_.size(); i++) {
18551876
size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, modifications_.get(i));
18561877
}
1878+
if (ignoreWarnings_ != false) {
1879+
size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, ignoreWarnings_);
1880+
}
18571881
size += getUnknownFields().getSerializedSize();
18581882
memoizedSize = size;
18591883
return size;
@@ -1872,6 +1896,7 @@ public boolean equals(final java.lang.Object obj) {
18721896

18731897
if (!getName().equals(other.getName())) return false;
18741898
if (!getModificationsList().equals(other.getModificationsList())) return false;
1899+
if (getIgnoreWarnings() != other.getIgnoreWarnings()) return false;
18751900
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
18761901
return true;
18771902
}
@@ -1889,6 +1914,8 @@ public int hashCode() {
18891914
hash = (37 * hash) + MODIFICATIONS_FIELD_NUMBER;
18901915
hash = (53 * hash) + getModificationsList().hashCode();
18911916
}
1917+
hash = (37 * hash) + IGNORE_WARNINGS_FIELD_NUMBER;
1918+
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getIgnoreWarnings());
18921919
hash = (29 * hash) + getUnknownFields().hashCode();
18931920
memoizedHashCode = hash;
18941921
return hash;
@@ -2038,6 +2065,7 @@ public Builder clear() {
20382065
modificationsBuilder_.clear();
20392066
}
20402067
bitField0_ = (bitField0_ & ~0x00000002);
2068+
ignoreWarnings_ = false;
20412069
return this;
20422070
}
20432071

@@ -2091,6 +2119,9 @@ private void buildPartial0(com.google.bigtable.admin.v2.ModifyColumnFamiliesRequ
20912119
if (((from_bitField0_ & 0x00000001) != 0)) {
20922120
result.name_ = name_;
20932121
}
2122+
if (((from_bitField0_ & 0x00000004) != 0)) {
2123+
result.ignoreWarnings_ = ignoreWarnings_;
2124+
}
20942125
}
20952126

20962127
@java.lang.Override
@@ -2171,6 +2202,9 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ModifyColumnFamiliesReques
21712202
}
21722203
}
21732204
}
2205+
if (other.getIgnoreWarnings() != false) {
2206+
setIgnoreWarnings(other.getIgnoreWarnings());
2207+
}
21742208
this.mergeUnknownFields(other.getUnknownFields());
21752209
onChanged();
21762210
return this;
@@ -2218,6 +2252,12 @@ public Builder mergeFrom(
22182252
}
22192253
break;
22202254
} // case 18
2255+
case 24:
2256+
{
2257+
ignoreWarnings_ = input.readBool();
2258+
bitField0_ |= 0x00000004;
2259+
break;
2260+
} // case 24
22212261
default:
22222262
{
22232263
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
@@ -2833,6 +2873,59 @@ public Builder removeModifications(int index) {
28332873
return modificationsBuilder_;
28342874
}
28352875

2876+
private boolean ignoreWarnings_;
2877+
/**
2878+
*
2879+
*
2880+
* <pre>
2881+
* Optional. If true, ignore safety checks when modifying the column families.
2882+
* </pre>
2883+
*
2884+
* <code>bool ignore_warnings = 3 [(.google.api.field_behavior) = OPTIONAL];</code>
2885+
*
2886+
* @return The ignoreWarnings.
2887+
*/
2888+
@java.lang.Override
2889+
public boolean getIgnoreWarnings() {
2890+
return ignoreWarnings_;
2891+
}
2892+
/**
2893+
*
2894+
*
2895+
* <pre>
2896+
* Optional. If true, ignore safety checks when modifying the column families.
2897+
* </pre>
2898+
*
2899+
* <code>bool ignore_warnings = 3 [(.google.api.field_behavior) = OPTIONAL];</code>
2900+
*
2901+
* @param value The ignoreWarnings to set.
2902+
* @return This builder for chaining.
2903+
*/
2904+
public Builder setIgnoreWarnings(boolean value) {
2905+
2906+
ignoreWarnings_ = value;
2907+
bitField0_ |= 0x00000004;
2908+
onChanged();
2909+
return this;
2910+
}
2911+
/**
2912+
*
2913+
*
2914+
* <pre>
2915+
* Optional. If true, ignore safety checks when modifying the column families.
2916+
* </pre>
2917+
*
2918+
* <code>bool ignore_warnings = 3 [(.google.api.field_behavior) = OPTIONAL];</code>
2919+
*
2920+
* @return This builder for chaining.
2921+
*/
2922+
public Builder clearIgnoreWarnings() {
2923+
bitField0_ = (bitField0_ & ~0x00000004);
2924+
ignoreWarnings_ = false;
2925+
onChanged();
2926+
return this;
2927+
}
2928+
28362929
@java.lang.Override
28372930
public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
28382931
return super.setUnknownFields(unknownFields);

proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ModifyColumnFamiliesRequestOrBuilder.java

+13
Original file line numberDiff line numberDiff line change
@@ -135,4 +135,17 @@ public interface ModifyColumnFamiliesRequestOrBuilder
135135
*/
136136
com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.ModificationOrBuilder
137137
getModificationsOrBuilder(int index);
138+
139+
/**
140+
*
141+
*
142+
* <pre>
143+
* Optional. If true, ignore safety checks when modifying the column families.
144+
* </pre>
145+
*
146+
* <code>bool ignore_warnings = 3 [(.google.api.field_behavior) = OPTIONAL];</code>
147+
*
148+
* @return The ignoreWarnings.
149+
*/
150+
boolean getIgnoreWarnings();
138151
}

proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/bigtable_table_admin.proto

+3
Original file line numberDiff line numberDiff line change
@@ -734,6 +734,9 @@ message ModifyColumnFamiliesRequest {
734734
// family, for example).
735735
repeated Modification modifications = 2
736736
[(google.api.field_behavior) = REQUIRED];
737+
738+
// Optional. If true, ignore safety checks when modifying the column families.
739+
bool ignore_warnings = 3 [(google.api.field_behavior) = OPTIONAL];
737740
}
738741

739742
// Request message for

0 commit comments

Comments
 (0)