Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Update DEVELOPMENT.md #3126

Merged
merged 4 commits into from
Aug 29, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 27 additions & 31 deletions gapic-generator-java/DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,24 +99,12 @@ To generate a production GAPIC API:

Replace the following section in googleapis
```
_gapic_generator_java_version = "2.13.0"

maven_install(
artifacts = [
"com.google.api:gapic-generator-java:" + _gapic_generator_java_version,
],
#Update this False for local development
fail_on_missing_checksum = True,
repositories = [
"m2Local",
"https://repo.maven.apache.org/maven2/",
]
)
_gapic_generator_java_version = "2.43.0"

http_archive(
name = "gapic_generator_java",
strip_prefix = "sdk-platform-java-%s" % _gapic_generator_java_version,
urls = ["https://github.com/googleapis/sdk-platform-java/archive/v%s.zip" % _gapic_generator_java_version],
strip_prefix = "sdk-platform-java-test-grpc",
zhumin8 marked this conversation as resolved.
Show resolved Hide resolved
urls = ["https://github.com/googleapis/sdk-platform-java/archive/refs/heads/test-grpc.zip"],
)

# gax-java is part of sdk-platform-java repository
Expand All @@ -129,20 +117,8 @@ To generate a production GAPIC API:

to
```
_gapic_generator_java_version = "2.15.4-SNAPSHOT"

maven_install(
artifacts = [
"com.google.api:gapic-generator-java:" + _gapic_generator_java_version,
],
#Update this False for local development
fail_on_missing_checksum = False,
repositories = [
"m2Local",
"https://repo.maven.apache.org/maven2/",
]
)

_gapic_generator_java_version = "2.43.1-SNAPSHOT"

local_repository(
name = "gapic_generator_java",
path = "/absolute/path/to/your/local/sdk-platform-java",
Expand All @@ -155,9 +131,29 @@ To generate a production GAPIC API:
)
```

Note: At the time of writing, the gapic-generator version was `2.13.0`. Update the version to the latest version in the pom.xml
Note: At the time of writing, the gapic-generator version was `2.43.0`. Update the version to the latest version in the pom.xml

Then update `fail_on_missing_checksum = False` in this `maven_install` target:

```
maven_install(
artifacts = [
"com.google.api:gapic-generator-java:" + _gapic_generator_java_version,
"com.google.protobuf:protobuf-javalite:3." + _protobuf_version,
] + PROTOBUF_MAVEN_ARTIFACTS +
IO_GRPC_GRPC_JAVA_ARTIFACTS,
generate_compat_repositories = True,
override_targets = IO_GRPC_GRPC_JAVA_OVERRIDE_TARGETS,
#Update this False for local development
fail_on_missing_checksum = True,
repositories = [
"m2Local",
"https://repo.maven.apache.org/maven2/",
]
)
```

3. Build the new target.
4. Build the new target.

You can generate any client library based on the protos within googleapis.
You just need the name of the service within the `java_gapic_assembly_gradle_pkg`
Expand Down
Loading