Skip to content
This repository was archived by the owner on May 8, 2026. It is now read-only.

Commit c0945b8

Browse files
deps: regenerating with new Protobuf (1.117.x) (#1342)
* fix: applying a different code generation * deps: shared deps 2.10.1 * 🦉 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 a58d689 commit c0945b8

64 files changed

Lines changed: 3343 additions & 5051 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/ci.yaml

Lines changed: 48 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -13,81 +13,75 @@
1313
# limitations under the License.
1414
# Github action job to test core java library features on
1515
# downstream client libraries before they are released.
16-
'on':
16+
on:
1717
push:
1818
branches:
19-
- 1.117.x
20-
pull_request: null
19+
- main
20+
pull_request:
2121
name: ci
2222
jobs:
2323
units:
2424
runs-on: ubuntu-latest
2525
strategy:
2626
fail-fast: false
2727
matrix:
28-
java:
29-
- 8
30-
- 11
31-
- 17
28+
java: [8, 11, 17]
3229
steps:
33-
- uses: actions/checkout@v3
34-
- uses: actions/setup-java@v3
35-
with:
36-
distribution: zulu
37-
java-version: ${{matrix.java}}
38-
- run: java -version
39-
- run: .kokoro/build.sh
40-
env:
41-
JOB_TYPE: test
30+
- uses: actions/checkout@v3
31+
- uses: actions/setup-java@v3
32+
with:
33+
distribution: zulu
34+
java-version: ${{matrix.java}}
35+
- run: java -version
36+
- run: .kokoro/build.sh
37+
env:
38+
JOB_TYPE: test
4239
windows:
4340
runs-on: windows-latest
4441
steps:
45-
- uses: actions/checkout@v3
46-
- uses: actions/setup-java@v3
47-
with:
48-
distribution: zulu
49-
java-version: 8
50-
- run: java -version
51-
- run: .kokoro/build.bat
52-
env:
53-
JOB_TYPE: test
42+
- uses: actions/checkout@v3
43+
- uses: actions/setup-java@v3
44+
with:
45+
distribution: zulu
46+
java-version: 8
47+
- run: java -version
48+
- run: .kokoro/build.bat
49+
env:
50+
JOB_TYPE: test
5451
dependencies:
5552
runs-on: ubuntu-latest
5653
strategy:
5754
matrix:
58-
java:
59-
- 8
60-
- 11
61-
- 17
55+
java: [8, 11, 17]
6256
steps:
63-
- uses: actions/checkout@v3
64-
- uses: actions/setup-java@v3
65-
with:
66-
distribution: zulu
67-
java-version: ${{matrix.java}}
68-
- run: java -version
69-
- run: .kokoro/dependencies.sh
57+
- uses: actions/checkout@v3
58+
- uses: actions/setup-java@v3
59+
with:
60+
distribution: zulu
61+
java-version: ${{matrix.java}}
62+
- run: java -version
63+
- run: .kokoro/dependencies.sh
7064
lint:
7165
runs-on: ubuntu-latest
7266
steps:
73-
- uses: actions/checkout@v3
74-
- uses: actions/setup-java@v3
75-
with:
76-
distribution: zulu
77-
java-version: 11
78-
- run: java -version
79-
- run: .kokoro/build.sh
80-
env:
81-
JOB_TYPE: lint
67+
- uses: actions/checkout@v3
68+
- uses: actions/setup-java@v3
69+
with:
70+
distribution: zulu
71+
java-version: 11
72+
- run: java -version
73+
- run: .kokoro/build.sh
74+
env:
75+
JOB_TYPE: lint
8276
clirr:
8377
runs-on: ubuntu-latest
8478
steps:
85-
- uses: actions/checkout@v3
86-
- uses: actions/setup-java@v3
87-
with:
88-
distribution: zulu
89-
java-version: 8
90-
- run: java -version
91-
- run: .kokoro/build.sh
92-
env:
93-
JOB_TYPE: clirr
79+
- uses: actions/checkout@v3
80+
- uses: actions/setup-java@v3
81+
with:
82+
distribution: zulu
83+
java-version: 8
84+
- run: java -version
85+
- run: .kokoro/build.sh
86+
env:
87+
JOB_TYPE: clirr

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,20 +51,20 @@ If you are using Maven without BOM, add this to your dependencies:
5151
If you are using Gradle 5.x or later, add this to your dependencies
5252

5353
```Groovy
54-
implementation platform('com.google.cloud:libraries-bom:25.2.0')
54+
implementation platform('com.google.cloud:libraries-bom:26.1.3')
5555
5656
implementation 'com.google.cloud:google-cloud-pubsub'
5757
```
5858
If you are using Gradle without BOM, add this to your dependencies
5959

6060
```Groovy
61-
implementation 'com.google.cloud:google-cloud-pubsub:1.116.4'
61+
implementation 'com.google.cloud:google-cloud-pubsub:1.120.20'
6262
```
6363

6464
If you are using SBT, add this to your dependencies
6565

6666
```Scala
67-
libraryDependencies += "com.google.cloud" % "google-cloud-pubsub" % "1.116.4"
67+
libraryDependencies += "com.google.cloud" % "google-cloud-pubsub" % "1.120.20"
6868
```
6969

7070
## Authentication

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161
<dependency>
6262
<groupId>com.google.cloud</groupId>
6363
<artifactId>google-cloud-shared-dependencies</artifactId>
64-
<version>2.10.0</version>
64+
<version>2.10.1</version>
6565
<type>pom</type>
6666
<scope>import</scope>
6767
</dependency>

proto-google-cloud-pubsub-v1/src/main/java/com/google/pubsub/v1/AcknowledgeRequest.java

Lines changed: 52 additions & 81 deletions
Original file line numberDiff line numberDiff line change
@@ -53,66 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
5353
return this.unknownFields;
5454
}
5555

56-
private AcknowledgeRequest(
57-
com.google.protobuf.CodedInputStream input,
58-
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
59-
throws com.google.protobuf.InvalidProtocolBufferException {
60-
this();
61-
if (extensionRegistry == null) {
62-
throw new java.lang.NullPointerException();
63-
}
64-
int mutable_bitField0_ = 0;
65-
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
66-
com.google.protobuf.UnknownFieldSet.newBuilder();
67-
try {
68-
boolean done = false;
69-
while (!done) {
70-
int tag = input.readTag();
71-
switch (tag) {
72-
case 0:
73-
done = true;
74-
break;
75-
case 10:
76-
{
77-
java.lang.String s = input.readStringRequireUtf8();
78-
79-
subscription_ = s;
80-
break;
81-
}
82-
case 18:
83-
{
84-
java.lang.String s = input.readStringRequireUtf8();
85-
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
86-
ackIds_ = new com.google.protobuf.LazyStringArrayList();
87-
mutable_bitField0_ |= 0x00000001;
88-
}
89-
ackIds_.add(s);
90-
break;
91-
}
92-
default:
93-
{
94-
if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) {
95-
done = true;
96-
}
97-
break;
98-
}
99-
}
100-
}
101-
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
102-
throw e.setUnfinishedMessage(this);
103-
} catch (com.google.protobuf.UninitializedMessageException e) {
104-
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
105-
} catch (java.io.IOException e) {
106-
throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
107-
} finally {
108-
if (((mutable_bitField0_ & 0x00000001) != 0)) {
109-
ackIds_ = ackIds_.getUnmodifiableView();
110-
}
111-
this.unknownFields = unknownFields.build();
112-
makeExtensionsImmutable();
113-
}
114-
}
115-
11656
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
11757
return com.google.pubsub.v1.PubsubProto
11858
.internal_static_google_pubsub_v1_AcknowledgeRequest_descriptor;
@@ -272,7 +212,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
272212
for (int i = 0; i < ackIds_.size(); i++) {
273213
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, ackIds_.getRaw(i));
274214
}
275-
unknownFields.writeTo(output);
215+
getUnknownFields().writeTo(output);
276216
}
277217

278218
@java.lang.Override
@@ -292,7 +232,7 @@ public int getSerializedSize() {
292232
size += dataSize;
293233
size += 1 * getAckIdsList().size();
294234
}
295-
size += unknownFields.getSerializedSize();
235+
size += getUnknownFields().getSerializedSize();
296236
memoizedSize = size;
297237
return size;
298238
}
@@ -309,7 +249,7 @@ public boolean equals(final java.lang.Object obj) {
309249

310250
if (!getSubscription().equals(other.getSubscription())) return false;
311251
if (!getAckIdsList().equals(other.getAckIdsList())) return false;
312-
if (!unknownFields.equals(other.unknownFields)) return false;
252+
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
313253
return true;
314254
}
315255

@@ -326,7 +266,7 @@ public int hashCode() {
326266
hash = (37 * hash) + ACK_IDS_FIELD_NUMBER;
327267
hash = (53 * hash) + getAckIdsList().hashCode();
328268
}
329-
hash = (29 * hash) + unknownFields.hashCode();
269+
hash = (29 * hash) + getUnknownFields().hashCode();
330270
memoizedHashCode = hash;
331271
return hash;
332272
}
@@ -455,17 +395,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
455395
}
456396

457397
// Construct using com.google.pubsub.v1.AcknowledgeRequest.newBuilder()
458-
private Builder() {
459-
maybeForceBuilderInitialization();
460-
}
398+
private Builder() {}
461399

462400
private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
463401
super(parent);
464-
maybeForceBuilderInitialization();
465-
}
466-
467-
private void maybeForceBuilderInitialization() {
468-
if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {}
469402
}
470403

471404
@java.lang.Override
@@ -572,7 +505,7 @@ public Builder mergeFrom(com.google.pubsub.v1.AcknowledgeRequest other) {
572505
}
573506
onChanged();
574507
}
575-
this.mergeUnknownFields(other.unknownFields);
508+
this.mergeUnknownFields(other.getUnknownFields());
576509
onChanged();
577510
return this;
578511
}
@@ -587,17 +520,44 @@ public Builder mergeFrom(
587520
com.google.protobuf.CodedInputStream input,
588521
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
589522
throws java.io.IOException {
590-
com.google.pubsub.v1.AcknowledgeRequest parsedMessage = null;
523+
if (extensionRegistry == null) {
524+
throw new java.lang.NullPointerException();
525+
}
591526
try {
592-
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
527+
boolean done = false;
528+
while (!done) {
529+
int tag = input.readTag();
530+
switch (tag) {
531+
case 0:
532+
done = true;
533+
break;
534+
case 10:
535+
{
536+
subscription_ = input.readStringRequireUtf8();
537+
538+
break;
539+
} // case 10
540+
case 18:
541+
{
542+
java.lang.String s = input.readStringRequireUtf8();
543+
ensureAckIdsIsMutable();
544+
ackIds_.add(s);
545+
break;
546+
} // case 18
547+
default:
548+
{
549+
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
550+
done = true; // was an endgroup tag
551+
}
552+
break;
553+
} // default:
554+
} // switch (tag)
555+
} // while (!done)
593556
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
594-
parsedMessage = (com.google.pubsub.v1.AcknowledgeRequest) e.getUnfinishedMessage();
595557
throw e.unwrapIOException();
596558
} finally {
597-
if (parsedMessage != null) {
598-
mergeFrom(parsedMessage);
599-
}
600-
}
559+
onChanged();
560+
} // finally
601561
return this;
602562
}
603563

@@ -942,7 +902,18 @@ public AcknowledgeRequest parsePartialFrom(
942902
com.google.protobuf.CodedInputStream input,
943903
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
944904
throws com.google.protobuf.InvalidProtocolBufferException {
945-
return new AcknowledgeRequest(input, extensionRegistry);
905+
Builder builder = newBuilder();
906+
try {
907+
builder.mergeFrom(input, extensionRegistry);
908+
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
909+
throw e.setUnfinishedMessage(builder.buildPartial());
910+
} catch (com.google.protobuf.UninitializedMessageException e) {
911+
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
912+
} catch (java.io.IOException e) {
913+
throw new com.google.protobuf.InvalidProtocolBufferException(e)
914+
.setUnfinishedMessage(builder.buildPartial());
915+
}
916+
return builder.buildPartial();
946917
}
947918
};
948919

0 commit comments

Comments
 (0)