Skip to content

Commit

Permalink
ci: javadoc job (JDK 17) in ci.yaml (#1819) (#2781)
Browse files Browse the repository at this point in the history
* ci: javadoc job (JDK 17) in ci.yaml (#1819)

This also changes the JDK distribution from zulu to temurin
https://github.com/actions/setup-java#eclipse-temurin
Source-Link: googleapis/synthtool@ef9fe2e
Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-java:latest@sha256:31c8276a1bfb43766597d32645721c029cb94571f1b8d996cb2c290744fe52f9

* fix errors

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

* fix error

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Co-authored-by: Neenu1995 <neenushaji@google.com>
  • Loading branch information
3 people committed Jun 28, 2023
1 parent 7fcfa63 commit 07760b7
Show file tree
Hide file tree
Showing 12 changed files with 107 additions and 100 deletions.
4 changes: 2 additions & 2 deletions .github/.OwlBot.lock.yaml
Expand Up @@ -13,5 +13,5 @@
# limitations under the License.
docker:
image: gcr.io/cloud-devrel-public-resources/owlbot-java:latest
digest: sha256:32851debfefed2b66038e0141f1b5c2103bb59ba80b7475adbc10ef7abab3de7
# created: 2023-06-22T15:06:52.039318836Z
digest: sha256:31c8276a1bfb43766597d32645721c029cb94571f1b8d996cb2c290744fe52f9
# created: 2023-06-27T18:51:58.922150125Z
26 changes: 19 additions & 7 deletions .github/workflows/ci.yaml
Expand Up @@ -30,7 +30,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
distribution: zulu
distribution: temurin
java-version: ${{matrix.java}}
- run: java -version
- run: .kokoro/build.sh
Expand All @@ -45,7 +45,7 @@ jobs:
- uses: actions/setup-java@v3
with:
java-version: 8
distribution: zulu
distribution: temurin
- name: "Set jvm system property environment variable for surefire plugin (unit tests)"
# Maven surefire plugin (unit tests) allows us to specify JVM to run the tests.
# https://maven.apache.org/surefire/maven-surefire-plugin/test-mojo.html#jvm
Expand All @@ -54,7 +54,7 @@ jobs:
- uses: actions/setup-java@v3
with:
java-version: 17
distribution: zulu
distribution: temurin
- run: .kokoro/build.sh
env:
JOB_TYPE: test
Expand All @@ -66,7 +66,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
distribution: zulu
distribution: temurin
java-version: 8
- run: java -version
- run: .kokoro/build.bat
Expand All @@ -81,17 +81,29 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
distribution: zulu
distribution: temurin
java-version: ${{matrix.java}}
- run: java -version
- run: .kokoro/dependencies.sh
javadoc:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
distribution: temurin
java-version: 17
- run: java -version
- run: .kokoro/build.sh
env:
JOB_TYPE: javadoc
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
distribution: zulu
distribution: temurin
java-version: 11
- run: java -version
- run: .kokoro/build.sh
Expand All @@ -103,7 +115,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
distribution: zulu
distribution: temurin
java-version: 8
- run: java -version
- run: .kokoro/build.sh
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/samples.yaml
Expand Up @@ -23,7 +23,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
distribution: zulu
distribution: temurin
java-version: 8
- name: Run checkstyle
run: mvn -P lint --quiet --batch-mode checkstyle:check
Expand Down
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -53,7 +53,7 @@ If you are using Maven without the BOM, add this to your dependencies:
If you are using Gradle 5.x or later, add this to your dependencies:

```Groovy
implementation platform('com.google.cloud:libraries-bom:26.17.0')
implementation platform('com.google.cloud:libraries-bom:26.18.0')
implementation 'com.google.cloud:google-cloud-bigquery'
```
Expand Down
Expand Up @@ -31,7 +31,7 @@
* Access Control for a BigQuery Dataset. BigQuery uses ACLs to manage permissions on datasets. ACLs
* are not directly supported on tables. A table inherits its ACL from the dataset that contains it.
* Project roles affect your ability to run jobs or manage the project, while dataset roles affect
* how you can access or modify the data inside of a project.
* how you can access or modify the data inside a project.
*
* @see <a href="https://cloud.google.com/bigquery/access-control">Access Control</a>
*/
Expand Down Expand Up @@ -82,12 +82,15 @@ public static Role valueOfStrict(String constant) {
return type.valueOfStrict(constant);
}

/** Get the Role for the given String constant, and allow unrecognized values. */
/**
* @param constant
* @return Get the Role for the given String constant, and allow unrecognized values.
*/
public static Role valueOf(String constant) {
return type.valueOf(constant);
}

/** Return the known values for Role. */
/** @return Return the known values for Role. */
public static Role[] values() {
return type.values();
}
Expand Down Expand Up @@ -167,14 +170,19 @@ public static final class DatasetAclEntity extends Entity {
private final DatasetId id;
private final List<String> targetTypes;

/** Creates a DatasetAclEntity given the DatasetAclEntity's id. */
/**
* Creates a DatasetAclEntity given the DatasetAclEntity's id.
*
* @param id
* @param targetTypes
*/
public DatasetAclEntity(DatasetId id, List<String> targetTypes) {
super(Type.DATASET);
this.id = id;
this.targetTypes = targetTypes;
}

/** Returns DatasetAclEntity's identity. */
/** @return Returns DatasetAclEntity's identity. */
public DatasetId getId() {
return id;
}
Expand Down Expand Up @@ -230,7 +238,7 @@ public Domain(String domain) {
this.domain = domain;
}

/** Returns the domain name. */
/** @return Returns the domain name. */
public String getDomain() {
return domain;
}
Expand Down Expand Up @@ -291,9 +299,9 @@ public Group(String identifier) {
}

/**
* Returns group's identifier, can be either a <a
* href="https://cloud.google.com/bigquery/docs/reference/v2/datasets#access.specialGroup">
* special group identifier</a> or a group email.
* @return Returns group's identifier, can be either a <a
* href="https://cloud.google.com/bigquery/docs/reference/v2/datasets#access.specialGroup">
* special group identifier</a> or a group email.
*/
public String getIdentifier() {
return identifier;
Expand Down Expand Up @@ -338,22 +346,22 @@ Access toPb() {
}
}

/** Returns a Group entity representing all project's owners. */
/** @return Returns a Group entity representing all project's owners. */
public static Group ofProjectOwners() {
return new Group(PROJECT_OWNERS);
}

/** Returns a Group entity representing all project's readers. */
/** @return Returns a Group entity representing all project's readers. */
public static Group ofProjectReaders() {
return new Group(PROJECT_READERS);
}

/** Returns a Group entity representing all project's writers. */
/** @return Returns a Group entity representing all project's writers. */
public static Group ofProjectWriters() {
return new Group(PROJECT_WRITERS);
}

/** Returns a Group entity representing all BigQuery authenticated users. */
/** @return Returns a Group entity representing all BigQuery authenticated users. */
public static Group ofAllAuthenticatedUsers() {
return new Group(ALL_AUTHENTICATED_USERS);
}
Expand All @@ -375,7 +383,7 @@ public User(String email) {
this.email = email;
}

/** Returns user's email. */
/** @return Returns user's email. */
public String getEmail() {
return email;
}
Expand Down Expand Up @@ -427,7 +435,7 @@ public View(TableId id) {
this.id = id;
}

/** Returns table's identity. */
/** @return Returns table's identity. */
public TableId getId() {
return id;
}
Expand Down Expand Up @@ -479,7 +487,7 @@ public Routine(RoutineId id) {
this.id = id;
}

/** Returns routine's identity. */
/** @return Returns routine's identity. */
public RoutineId getId() {
return id;
}
Expand Down Expand Up @@ -527,7 +535,7 @@ public IamMember(String iamMember) {
this.iamMember = iamMember;
}

/** Returns iamMember. */
/** @return Returns iamMember. */
public String getIamMember() {
return iamMember;
}
Expand Down Expand Up @@ -565,37 +573,45 @@ private Acl(Entity entity, Role role) {
this.role = role;
}

/** Returns the entity for this ACL. */
/** @return Returns the entity for this ACL. */
public Entity getEntity() {
return entity;
}

/** Returns the role specified by this ACL. */
/** @return Returns the role specified by this ACL. */
public Role getRole() {
return role;
}

/**
* Returns an Acl object.
*
* @return Returns an Acl object.
* @param entity the entity for this ACL object
* @param role the role to associate to the {@code entity} object
*/
public static Acl of(Entity entity, Role role) {
return new Acl(entity, role);
}

/** Returns an Acl object for a datasetAclEntity. */
/**
* @param datasetAclEntity
* @return Returns an Acl object for a datasetAclEntity.
*/
public static Acl of(DatasetAclEntity datasetAclEntity) {
return new Acl(datasetAclEntity, null);
}

/** Returns an Acl object for a view entity. */
/**
* @param view
* @return Returns an Acl object for a view entity.
*/
public static Acl of(View view) {
return new Acl(view, null);
}

/** Returns an Acl object for a routine entity. */
/**
* @param routine
* @return Returns an Acl object for a routine entity.
*/
public static Acl of(Routine routine) {
return new Acl(routine, null);
}
Expand Down

0 comments on commit 07760b7

Please sign in to comment.