Skip to content
This repository was archived by the owner on Sep 16, 2023. It is now read-only.

Commit 04de9cc

Browse files
feat!: convert resource names to multipattern resource names (#99)
* chore(deps): update dependency com.google.cloud.samples:shared-configuration to v1.0.13 (#95) 9f1e9c7 commit 9f1e9c7 Author: WhiteSource Renovate <bot@renovateapp.com> Date: Wed Mar 25 20:52:39 2020 +0100 chore(deps): update dependency com.google.cloud.samples:shared-configuration to v1.0.13 (#95) This PR contains the following updates: | Package | Update | Change | |---|---|---| | [com.google.cloud.samples:shared-configuration](https://togithub.com/GoogleCloudPlatform/java-repo-tools) | patch | `1.0.12` -> `1.0.13` | --- ### Release Notes <details> <summary>GoogleCloudPlatform/java-repo-tools</summary> ### [`v1.0.13`](https://togithub.com/GoogleCloudPlatform/java-repo-tools/releases/v1.0.13) [Compare Source](https://togithub.com/GoogleCloudPlatform/java-repo-tools/compare/v1.0.12...v1.0.13) Fix some issues w/ Checkstyle configuration. We left the option to turn it off out. </details> --- ### Renovate configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻️ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#googleapis/java-securitycenter). * deps: update dependency com.google.api:api-common to v1.9.0 (#98) 08ea9c7 commit 08ea9c7 Author: WhiteSource Renovate <bot@renovateapp.com> Date: Thu Mar 26 00:21:44 2020 +0100 deps: update dependency com.google.api:api-common to v1.9.0 (#98) This PR contains the following updates: | Package | Update | Change | |---|---|---| | [com.google.api:api-common](https://togithub.com/googleapis/api-common-java) | minor | `1.8.1` -> `1.9.0` | --- ### Release Notes <details> <summary>googleapis/api-common-java</summary> ### [`v1.9.0`](https://togithub.com/googleapis/api-common-java/releases/v1.9.0) [Compare Source](https://togithub.com/googleapis/api-common-java/compare/v1.8.1...v1.9.0) 03-25-2020 14:09 PST #### New Features - Add `@BetaApi` `ApiFutres.catchingAsync()` ([#&#8203;117](https://togithub.com/googleapis/api-common-java/pull/117)) ##### Dependencies - Update guava to v28.2-android ([#&#8203;110](https://togithub.com/googleapis/api-common-java/pull/110)) - Update error_prone_annotations to v2.2.3 ([#&#8203;111](https://togithub.com/googleapis/api-common-java/pull/111)) </details> --- ### Renovate configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻️ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#googleapis/java-securitycenter). * chore: use latest protoc-java-resource-name-plugin in bazel WORKSPACE. new commits: - fix: stop generating `parseList` and `toStringList` if a multi-pattern resource name has subclasses (#79) googleapis/googleapis@8bea81b commit 8bea81bfa461698981b3d3a488a95633d2f6e9ff Author: Google APIs <noreply@google.com> Date: Thu Mar 26 14:44:25 2020 -0700 chore: use latest protoc-java-resource-name-plugin in bazel WORKSPACE. new commits: - fix: stop generating `parseList` and `toStringList` if a multi-pattern resource name has subclasses (#79) committer: @hzyi-google PiperOrigin-RevId: 303197602 * remove deprecated v1p1beta1 resource names and allow breaking changes Co-authored-by: Jeff Ching <chingor@google.com>
1 parent 95ee0da commit 04de9cc

File tree

7 files changed

+53
-181
lines changed

7 files changed

+53
-181
lines changed

proto-google-cloud-securitycenter-v1/clirr-ignored-differences.xml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,16 @@
1616
<className>com/google/cloud/securitycenter/v1/*OrBuilder</className>
1717
<method>boolean has*(*)</method>
1818
</difference>
19+
20+
<!-- TODO: remove after 0.121.0 -->
1921
<difference>
20-
<differenceType>5001</differenceType>
21-
<className>com/google/cloud/securitycenter/v1/*Name</className>
22-
<to>com/google/cloud/securitycenter/v1/*Name</to>
22+
<differenceType>7002</differenceType>
23+
<className>com/google/cloud/securitycenter/v1/SecurityMarksName</className>
24+
<method>java.util.List parse(java.util.List)</method>
2325
</difference>
2426
<difference>
25-
<differenceType>8001</differenceType>
26-
<className>com/google/cloud/securitycenter/v1/*Name*</className>
27+
<differenceType>7002</differenceType>
28+
<className>com/google/cloud/securitycenter/v1/SecurityMarksName</className>
29+
<method>java.util.List toStrings(java.util.List)</method>
2730
</difference>
2831
</differences>

proto-google-cloud-securitycenter-v1/src/main/java/com/google/cloud/securitycenter/v1/SecurityMarksName.java

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@
2222
import com.google.api.resourcenames.ResourceName;
2323
import com.google.common.base.Preconditions;
2424
import com.google.common.collect.ImmutableMap;
25-
import java.util.ArrayList;
26-
import java.util.List;
2725
import java.util.Map;
2826
import java.util.Objects;
2927

@@ -152,28 +150,6 @@ public static SecurityMarksName parse(String formattedString) {
152150
throw new ValidationException("JobName.parse: formattedString not in valid format");
153151
}
154152

155-
@BetaApi("The method will be renamed to parseList after subclasses of this class are removed.")
156-
public static List<SecurityMarksName> parse(List<String> formattedStrings) {
157-
List<SecurityMarksName> list = new ArrayList<>(formattedStrings.size());
158-
for (String formattedString : formattedStrings) {
159-
list.add(parse(formattedString));
160-
}
161-
return list;
162-
}
163-
164-
@BetaApi("The method will be renamed to toStringList after subclasses of this class are removed.")
165-
public static List<String> toStrings(List<SecurityMarksName> values) {
166-
List<String> list = new ArrayList<>(values.size());
167-
for (SecurityMarksName value : values) {
168-
if (value == null) {
169-
list.add("");
170-
} else {
171-
list.add(value.toString());
172-
}
173-
}
174-
return list;
175-
}
176-
177153
public static boolean isParsableFrom(String formattedString) {
178154
return ORGANIZATION_ASSET_PATH_TEMPLATE.matches(formattedString)
179155
|| ORGANIZATION_SOURCE_FINDING_PATH_TEMPLATE.matches(formattedString);
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!-- see http://www.mojohaus.org/clirr-maven-plugin/examples/ignored-differences.html -->
3+
<differences>
4+
<difference>
5+
<differenceType>7012</differenceType>
6+
<className>com/google/cloud/securitycenter/v1p1beta1/*OrBuilder</className>
7+
<method>* get*(*)</method>
8+
</difference>
9+
<difference>
10+
<differenceType>7012</differenceType>
11+
<className>com/google/cloud/securitycenter/v1p1beta1/*OrBuilder</className>
12+
<method>boolean contains*(*)</method>
13+
</difference>
14+
<difference>
15+
<differenceType>7012</differenceType>
16+
<className>com/google/cloud/securitycenter/v1p1beta1/*OrBuilder</className>
17+
<method>boolean has*(*)</method>
18+
</difference>
19+
20+
<!-- TODO: remove after 0.121.0 -->
21+
<difference>
22+
<differenceType>7002</differenceType>
23+
<className>com/google/cloud/securitycenter/v1p1beta1/SecurityMarksName</className>
24+
<method>*</method>
25+
</difference>
26+
<difference>
27+
<differenceType>8001</differenceType>
28+
<className>com/google/cloud/securitycenter/v1p1beta1/SecurityMarksNames</className>
29+
</difference>
30+
<difference>
31+
<differenceType>8001</differenceType>
32+
<className>com/google/cloud/securitycenter/v1p1beta1/UntypedSecurityMarksName</className>
33+
</difference>
34+
</differences>

proto-google-cloud-securitycenter-v1p1beta1/src/main/java/com/google/cloud/securitycenter/v1p1beta1/SecurityMarksName.java

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -152,17 +152,15 @@ public static SecurityMarksName parse(String formattedString) {
152152
throw new ValidationException("JobName.parse: formattedString not in valid format");
153153
}
154154

155-
@BetaApi("The method will be renamed to parseList after subclasses of this class are removed.")
156-
public static List<SecurityMarksName> parse(List<String> formattedStrings) {
155+
public static List<SecurityMarksName> parseList(List<String> formattedStrings) {
157156
List<SecurityMarksName> list = new ArrayList<>(formattedStrings.size());
158157
for (String formattedString : formattedStrings) {
159158
list.add(parse(formattedString));
160159
}
161160
return list;
162161
}
163162

164-
@BetaApi("The method will be renamed to toStringList after subclasses of this class are removed.")
165-
public static List<String> toStrings(List<SecurityMarksName> values) {
163+
public static List<String> toStringList(List<SecurityMarksName> values) {
166164
List<String> list = new ArrayList<>(values.size());
167165
for (SecurityMarksName value : values) {
168166
if (value == null) {

proto-google-cloud-securitycenter-v1p1beta1/src/main/java/com/google/cloud/securitycenter/v1p1beta1/SecurityMarksNames.java

Lines changed: 0 additions & 32 deletions
This file was deleted.

proto-google-cloud-securitycenter-v1p1beta1/src/main/java/com/google/cloud/securitycenter/v1p1beta1/UntypedSecurityMarksName.java

Lines changed: 0 additions & 106 deletions
This file was deleted.

synth.metadata

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,36 @@
11
{
2-
"updateTime": "2020-03-25T18:31:45.271331Z",
2+
"updateTime": "2020-03-26T22:41:16.428212Z",
33
"sources": [
44
{
55
"git": {
66
"name": "googleapis",
77
"remote": "https://github.com/googleapis/googleapis.git",
8-
"sha": "fd83ab212176a1042e8d45ea90766b3bf59ac679",
9-
"internalRef": "302913609"
8+
"sha": "8bea81bfa461698981b3d3a488a95633d2f6e9ff",
9+
"internalRef": "303197602"
1010
}
1111
},
1212
{
1313
"git": {
1414
"name": "googleapis",
1515
"remote": "https://github.com/googleapis/googleapis.git",
16-
"sha": "fd83ab212176a1042e8d45ea90766b3bf59ac679",
17-
"internalRef": "302913609"
16+
"sha": "8bea81bfa461698981b3d3a488a95633d2f6e9ff",
17+
"internalRef": "303197602"
1818
}
1919
},
2020
{
2121
"git": {
2222
"name": "googleapis",
2323
"remote": "https://github.com/googleapis/googleapis.git",
24-
"sha": "fd83ab212176a1042e8d45ea90766b3bf59ac679",
25-
"internalRef": "302913609",
26-
"log": "fd83ab212176a1042e8d45ea90766b3bf59ac679\nfix: migrate osconfig/agentendpoint/v1 go_gapic_library target to microgen impl\n\nPiperOrigin-RevId: 302913609\n\n0e07113e776bdd8fcc0783372e08bb6e76cb1b5b\ndocs: Update documentation with links to smart home developer guides and reference pages. Remove outdated authorization instructions.\n\nPiperOrigin-RevId: 302892245\n\n"
24+
"sha": "8bea81bfa461698981b3d3a488a95633d2f6e9ff",
25+
"internalRef": "303197602",
26+
"log": "8bea81bfa461698981b3d3a488a95633d2f6e9ff\nchore: use latest protoc-java-resource-name-plugin in bazel WORKSPACE.\nnew commits:\n- fix: stop generating `parseList` and `toStringList` if a multi-pattern resource name has subclasses (#79)\n\ncommitter: @hzyi-google\nPiperOrigin-RevId: 303197602\n\nb14af92e565264675d6b12cd2c0ded6c94ddd7f8\nfix talent API incorrect placeholders in two resource name patterns.\ncommitter: @hzyi-google\n\nPiperOrigin-RevId: 303189497\n\n8e22db908ae09e1f7e2802c03b4563fd6b524e0e\nchore(google/maps): Update postprocessing script for Java.\n\n- Update root build.gradle to load local plugin\n- Change com.google.api.grpc group to com.google.maps\n\nPiperOrigin-RevId: 303176850\n\n65816afa71e588252b7119dc723592abe51ea106\nbazel: update gapic-generator-go to v0.12.5 and gapic-generator hash\n\nChanges to gapic-generator-go include:\n* feat: strip invalid link references in comments\n* chore: updating Go deps in bazel repositories\n\nChanges to gapic-generator include:\n* fix: bazel go build gen check for cloud in proto pkg name\n* Revert \"feat: allow static substitution for group name\"\n\nPiperOrigin-RevId: 303150338\n\nd4aa417ed2bba89c2d216900282bddfdafef6128\nFix incorrect retry config in gapic v2 for kms.\n\nPiperOrigin-RevId: 303010132\n\nfd08334533204fdd1b33f79fcb263dbb5bf13de0\nfix: osconfig/v1 update go_gapic_library target to microgen interface\n\nPiperOrigin-RevId: 303007866\n\ne2c0f2a0e06d86b50aba98f67f9f291587d986b3\nUpdate comments for google/rpc/error_details.proto.\n\nPiperOrigin-RevId: 303002528\n\nf786c7586748e78a286b1620ff3ddbf7b4dcab92\nfeat: Add OsConfigService v1 patch APIs.\n\nPiperOrigin-RevId: 302999346\n\n0341fa3fc2f4073a1b1f260d37b2ce620799f545\nTurn on gapic config v2 for kms.\n\nCommitter: @hzyi-google\nPiperOrigin-RevId: 302980301\n\n32dc6e832039b61ac3fb82c72eb0a27570aebcd6\nredis: v1beta1 enables REDIS_5_0 as an option for redis_version field and adds two new redis configs --stream-node-max-entries --stream-node-max-bytes\n\nPiperOrigin-RevId: 302958009\n\n685f16483cc4d87c35051f21f8f13ef4fdc919b4\nredis: v1 enables REDIS_5_0 as an option for redis_version field and adds two new redis configs --stream-node-max-entries --stream-node-max-bytes\n\nPiperOrigin-RevId: 302957729\n\n733cb282ae5e64673ef86c9a5dff647df803d8b7\nAdd GAPIC cofiguration for v1 client library genetration.\n\nPiperOrigin-RevId: 302928200\n\n1b0fff5f2ec6dc4a9443d9b50e70e9c94c30c45b\ndocs: remove an internal lint declaration\n\nPiperOrigin-RevId: 302928106\n\n2be23f3f3036a6f7ce0844def3d2d3da74e5d415\nfix(google/maps): Add post-processing rules for Google Maps APIs\n\nPiperOrigin-RevId: 302925222\n\n"
2727
}
2828
},
2929
{
3030
"git": {
3131
"name": "synthtool",
3232
"remote": "https://github.com/googleapis/synthtool.git",
33-
"sha": "e36822bfa0acb355502dab391b8ef9c4f30208d8",
34-
"log": "e36822bfa0acb355502dab391b8ef9c4f30208d8\nchore(java): treat samples shared configuration dependency update as chore (#457)\n\n\n1b4cc80a7aaf164f6241937dd87f3bd1f4149e0c\nfix: do not run node 8 CI (#456)\n\n\n"
33+
"sha": "e36822bfa0acb355502dab391b8ef9c4f30208d8"
3534
}
3635
}
3736
],

0 commit comments

Comments
 (0)