From 99df0919c7901948a90cc411fc212468a7754c01 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Fri, 5 Nov 2021 18:52:20 +0100 Subject: [PATCH 1/5] deps: update dependency com.google.errorprone:error_prone_annotations to v2.10.0 (#316) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.errorprone:error_prone_annotations](https://errorprone.info) ([source](https://togithub.com/google/error-prone)) | `2.9.0` -> `2.10.0` | [![age](https://badges.renovateapi.com/packages/maven/com.google.errorprone:error_prone_annotations/2.10.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.errorprone:error_prone_annotations/2.10.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.errorprone:error_prone_annotations/2.10.0/compatibility-slim/2.9.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.errorprone:error_prone_annotations/2.10.0/confidence-slim/2.9.0)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes
google/error-prone ### [`v2.10.0`](https://togithub.com/google/error-prone/releases/v2.10.0) New checks - [`AlwaysThrows`](http://errorprone.info/bugpattern/AlwaysThrows) - [`StackTraceElementGetClass`](http://errorprone.info/bugpattern/StackTraceElementGetClass) - [`BareDotMetacharacter`](http://errorprone.info/bugpattern/BareDotMetacharacter) - [`DistinctVarargsChecker`](http://errorprone.info/bugpattern/DistinctVarargsChecker) - [`MalformedInlineTag`](http://errorprone.info/bugpattern/MalformedInlineTag) - [`MemoizeConstantVisitorStateLookups`](http://errorprone.info/bugpattern/MemoizeConstantVisitorStateLookups) - [`UnicodeEscape`](http://errorprone.info/bugpattern/UnicodeEscape) - [`FieldMissingNullable`](http://errorprone.info/bugpattern/FieldMissingNullable) - [`Java8ApiChecker`](http://errorprone.info/bugpattern/Java8ApiChecker) - [`ParameterMissingNullable`](http://errorprone.info/bugpattern/ParameterMissingNullable) - [`TooManyParameters`](http://errorprone.info/bugpattern/TooManyParameters) - [`TryWithResourcesVariable`](http://errorprone.info/bugpattern/TryWithResourcesVariable) - [`UnnecessaryFinal`](http://errorprone.info/bugpattern/UnnecessaryFinal) - [`VoidMissingNullable`](http://errorprone.info/bugpattern/VoidMissingNullable) Fixed issues: [#​2616](https://togithub.com/google/error-prone/issues/2616), [#​2629](https://togithub.com/google/error-prone/issues/2629) **Full Changelog**: https://github.com/google/error-prone/compare/v2.9.0...v2.10.0
--- ### 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. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/api-common-java). --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 04f955686..ed86091f9 100644 --- a/build.gradle +++ b/build.gradle @@ -46,7 +46,7 @@ ext { auto_value_annotations: 'com.google.auto.value:auto-value-annotations:1.8.2', guava: 'com.google.guava:guava:31.0.1-jre', jsr305: 'com.google.code.findbugs:jsr305:3.0.2', - error_prone_annotations: 'com.google.errorprone:error_prone_annotations:2.9.0', + error_prone_annotations: 'com.google.errorprone:error_prone_annotations:2.10.0', // Testing junit: 'junit:junit:4.13.2', From b33d6e11c91d35b56392264c514d942084b21b95 Mon Sep 17 00:00:00 2001 From: Emily Ball Date: Tue, 9 Nov 2021 11:39:51 -0800 Subject: [PATCH 2/5] chore: include @code in javadoc (#318) fixes b/205642105 issue --- .../google/api/pathtemplate/PathTemplate.java | 36 +++++++++---------- .../pathtemplate/TemplatedResourceName.java | 4 +-- 2 files changed, 20 insertions(+), 20 deletions(-) diff --git a/src/main/java/com/google/api/pathtemplate/PathTemplate.java b/src/main/java/com/google/api/pathtemplate/PathTemplate.java index 098524210..4e4e770e6 100644 --- a/src/main/java/com/google/api/pathtemplate/PathTemplate.java +++ b/src/main/java/com/google/api/pathtemplate/PathTemplate.java @@ -69,7 +69,7 @@ *

* Here is an example for a template using simple variables: * - *

+ * 
{@code
  *   PathTemplate template = PathTemplate.create("v1/shelves/{shelf}/books/{book}");
  *   assert template.matches("v2/shelves") == false;
  *   Map<String, String> values = template.match("v1/shelves/s1/books/b1");
@@ -78,22 +78,22 @@
  *   expectedValues.put("book", "b1");
  *   assert values.equals(expectedValues);
  *   assert template.instantiate(values).equals("v1/shelves/s1/books/b1");
- * 
+ * }
* * Templates can use variables which match sub-paths. Example: * - *
+ * 
{@code
  *   PathTemplate template = PathTemplate.create("v1/{name=shelves/*/books/*}"};
  *   assert template.match("v1/shelves/books/b1") == null;
  *   Map<String, String> expectedValues = new HashMap<>();
  *   expectedValues.put("name", "shelves/s1/books/b1");
  *   assert template.match("v1/shelves/s1/books/b1").equals(expectedValues);
- * 
+ * }
* * Path templates can also be used with only wildcards. Each wildcard is associated with an implicit * variable {@code $n}, where n is the zero-based position of the wildcard. Example: * - *
+ * 
{@code
  *   PathTemplate template = PathTemplate.create("shelves/*/books/*"};
  *   assert template.match("shelves/books/b1") == null;
  *   Map<String, String> values = template.match("v1/shelves/s1/books/b1");
@@ -101,14 +101,14 @@
  *   expectedValues.put("$0", s1");
  *   expectedValues.put("$1", "b1");
  *   assert values.equals(expectedValues);
- * 
+ * }
* * Paths input to matching can use URL relative syntax to indicate a host name by prefixing the host * name, as in {@code //somewhere.io/some/path}. The host name is matched into the special variable * {@link #HOSTNAME_VAR}. Patterns are agnostic about host names, and the same pattern can be used * for URL relative syntax and simple path syntax: * - *
+ * 
{@code
  *   PathTemplate template = PathTemplate.create("shelves/*"};
  *   Map<String, String> expectedValues = new HashMap<>();
  *   expectedValues.put(PathTemplate.HOSTNAME_VAR, "//somewhere.io");
@@ -117,7 +117,7 @@
  *   expectedValues.clear();
  *   expectedValues.put("$0", s1");
  *   assert template.match("shelves/s1").equals(expectedValues);
- * 
+ * }
* * For the representation of a resource name see {@link TemplatedResourceName}, which is * based on path templates. @@ -347,10 +347,10 @@ public PathTemplate withoutVars() { /** * Returns a path template for the sub-path of the given variable. Example: * - *
+   * 
{@code
    *   PathTemplate template = PathTemplate.create("v1/{name=shelves/*/books/*}");
    *   assert template.subTemplate("name").toString().equals("shelves/*/books/*");
-   * 
+ * }
* * The returned template will never have named variables, but only wildcards, which are dealt with * in matching and instantiation using '$n'-variables. See the documentation of @@ -446,7 +446,7 @@ public void validate(String path, String exceptionMessagePrefix) { * For free wildcards in the template, the matching process creates variables named '$n', where * 'n' is the wildcard's position in the template (starting at n=0). For example: * - *
+   * 
{@code
    *   PathTemplate template = PathTemplate.create("shelves/*/books/*");
    *   Map<String, String> expectedValues = new HashMap<>();
    *   expectedValues.put("$0", "s1");
@@ -459,7 +459,7 @@ public void validate(String path, String exceptionMessagePrefix) {
    *   expectedValues.put("$1", "b1");
    *   assert template.validatedMatch("//somewhere.io/shelves/s1/books/b2", "User exception string")
    *              .equals(expectedValues);
-   * 
+ * }
* * All matched values will be properly unescaped using URL encoding rules (so long as URL encoding * has not been disabled by the {@link #createWithoutUrlEncoding} method). @@ -498,7 +498,7 @@ public boolean matches(String path) { * For free wildcards in the template, the matching process creates variables named '$n', where * 'n' is the wildcard's position in the template (starting at n=0). For example: * - *
+   * 
{@code
    *   PathTemplate template = PathTemplate.create("shelves/*/books/*");
    *   Map<String, String> expectedValues = new HashMap<>();
    *   expectedValues.put("$0", "s1");
@@ -509,7 +509,7 @@ public boolean matches(String path) {
    *   expectedValues.put("$0", "s1");
    *   expectedValues.put("$1", "b1");
    *   assert template.match("//somewhere.io/shelves/s1/books/b2").equals(expectedValues);
-   * 
+ * }
* * All matched values will be properly unescaped using URL encoding rules (so long as URL encoding * has not been disabled by the {@link #createWithoutUrlEncoding} method). @@ -523,13 +523,13 @@ public Map match(String path) { * Matches the path, where the first segment is interpreted as the host name regardless of whether * it starts with '//' or not. Example: * - *
+   * 
{@code
    *   Map<String, String> expectedValues = new HashMap<>();
    *   expectedValues.put(HOSTNAME_VAR, "//somewhere.io");
    *   expectedValues.put("name", "shelves/s1");
    *   assert template("{name=shelves/*}").matchFromFullName("somewhere.io/shelves/s1")
    *            .equals(expectedValues);
-   * 
+ * }
*/ @Nullable public Map matchFromFullName(String path) { @@ -721,12 +721,12 @@ public String instantiate(String... keysAndValues) { * Same like {@link #instantiate(Map)} but allows for unbound variables, which are substituted * using their original syntax. Example: * - *
+   * 
{@code
    *   PathTemplate template = PathTemplate.create("v1/shelves/{shelf}/books/{book}");
    *   Map<String, String> partialMap = new HashMap<>();
    *   partialMap.put("shelf", "s1");
    *   assert template.instantiatePartial(partialMap).equals("v1/shelves/s1/books/{book}");
-   * 
+ * }
* * The result of this call can be used to create a new template. */ diff --git a/src/main/java/com/google/api/pathtemplate/TemplatedResourceName.java b/src/main/java/com/google/api/pathtemplate/TemplatedResourceName.java index bbbedeaeb..c5e9cd6e1 100644 --- a/src/main/java/com/google/api/pathtemplate/TemplatedResourceName.java +++ b/src/main/java/com/google/api/pathtemplate/TemplatedResourceName.java @@ -58,12 +58,12 @@ *

* Usage examples: * - *

+ * 
{@code
  *   PathTemplate template = PathTemplate.create("shelves/*/books/*");
  *   TemplatedResourceName resourceName = TemplatedResourceName.create(template, "shelves/s1/books/b1");
  *   assert resourceName.get("$1").equals("b1");
  *   assert resourceName.parentName().toString().equals("shelves/s1/books");
- * 
+ * }
*/ public class TemplatedResourceName implements Map { From 6d8eeb4d8396cdcbbc8a25f5702971f869827377 Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Wed, 10 Nov 2021 11:12:14 -0500 Subject: [PATCH 3/5] chore: release 2.1.1-SNAPSHOT (#315) Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com> Co-authored-by: Neenu Shaji --- build.gradle | 2 +- versions.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/build.gradle b/build.gradle index ed86091f9..d129e0a32 100644 --- a/build.gradle +++ b/build.gradle @@ -26,7 +26,7 @@ apply plugin: 'io.github.gradle-nexus.publish-plugin' group = "com.google.api" archivesBaseName = "api-common" -project.version = "2.1.0" // {x-version-update:api-common:current} +project.version = "2.1.1-SNAPSHOT" // {x-version-update:api-common:current} sourceCompatibility = 1.8 targetCompatibility = 1.8 diff --git a/versions.txt b/versions.txt index a338d9794..e3dac80f2 100644 --- a/versions.txt +++ b/versions.txt @@ -1,4 +1,4 @@ # Format: # module:released-version:current-version -api-common:2.1.0:2.1.0 +api-common:2.1.0:2.1.1-SNAPSHOT From 1e0e382b5ab007a443a61137fd6dc01148dfe215 Mon Sep 17 00:00:00 2001 From: Emily Ball Date: Wed, 10 Nov 2021 09:49:55 -0800 Subject: [PATCH 4/5] chore: fix doc generation (#317) --- build.gradle | 3 +++ 1 file changed, 3 insertions(+) diff --git a/build.gradle b/build.gradle index d129e0a32..5343c6e7d 100644 --- a/build.gradle +++ b/build.gradle @@ -354,6 +354,9 @@ task javadocCombinedV3(type: Javadoc) { options.addStringOption("doclet", "com.microsoft.doclet.DocFxDoclet") options.addStringOption("projectname", "api-common") options.docletpath = [file(System.getenv('KOKORO_GFILE_DIR') + "/java-docfx-doclet-1.3.0.jar")] + // Newer Gradle 6 passes -notimestamp by default, which the doclet above doesn't understand: + // https://github.com/gradle/gradle/issues/11898 + options.noTimestamp false } clean { From 67cc5542896828e6b288b2969b42a305a11ee03d Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Mon, 15 Nov 2021 15:13:41 -0800 Subject: [PATCH 5/5] chore: release 2.1.1 (#319) Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com> Co-authored-by: Emily Ball --- CHANGELOG.md | 7 +++++++ build.gradle | 2 +- versions.txt | 2 +- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f53bb2ac8..410ecb87d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,12 @@ # Changelog +### [2.1.1](https://www.github.com/googleapis/api-common-java/compare/v2.1.0...v2.1.1) (2021-11-10) + + +### Dependencies + +* update dependency com.google.errorprone:error_prone_annotations to v2.10.0 ([#316](https://www.github.com/googleapis/api-common-java/issues/316)) ([99df091](https://www.github.com/googleapis/api-common-java/commit/99df0919c7901948a90cc411fc212468a7754c01)) + ## [2.1.0](https://www.github.com/googleapis/api-common-java/compare/v2.0.5...v2.1.0) (2021-10-20) diff --git a/build.gradle b/build.gradle index 5343c6e7d..d25359a92 100644 --- a/build.gradle +++ b/build.gradle @@ -26,7 +26,7 @@ apply plugin: 'io.github.gradle-nexus.publish-plugin' group = "com.google.api" archivesBaseName = "api-common" -project.version = "2.1.1-SNAPSHOT" // {x-version-update:api-common:current} +project.version = "2.1.1" // {x-version-update:api-common:current} sourceCompatibility = 1.8 targetCompatibility = 1.8 diff --git a/versions.txt b/versions.txt index e3dac80f2..8c4d855cb 100644 --- a/versions.txt +++ b/versions.txt @@ -1,4 +1,4 @@ # Format: # module:released-version:current-version -api-common:2.1.0:2.1.1-SNAPSHOT +api-common:2.1.1:2.1.1