Skip to content

Conversation

@zhumin8
Copy link
Contributor

@zhumin8 zhumin8 commented Sep 27, 2022

Adding Spring related dependencies to build files and use static types instead of vapor references.
Benefit of this change:

  • easier to test
  • less code change needed for future changes (e.g. package change of classes).

One caveat is that because gapic-generator-java is brought into googleapis as http_archive code addition to googleapis is also needed to include these libraries. Add below code snippet to WORKSPACE:

SPRING_MAVEN_ARTIFACTS = [
    "org.springframework.boot:spring-boot-starter:2.7.4",
    "com.google.cloud:spring-cloud-gcp-core:3.3.0",
]

maven_install(
    artifacts = PROTOBUF_MAVEN_ARTIFACTS + SPRING_MAVEN_ARTIFACTS,
    generate_compat_repositories = True,
    repositories = [
        "https://repo.maven.apache.org/maven2/",
    ],
)


Updates:

Pending task on spring-cloud-gcp side:

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 4 Code Smells

100.0% 100.0% Coverage
0.0% 0.0% Duplication

@zhumin8 zhumin8 added the spring pr that's related to spring code gen, intend to merge into autoconfig-gen-draft2 branch. label Sep 29, 2022
@zhumin8 zhumin8 marked this pull request as ready for review November 17, 2022 21:57
@zhumin8 zhumin8 requested a review from a team November 17, 2022 21:57
@zhumin8 zhumin8 requested a review from a team as a code owner November 17, 2022 21:57
Copy link
Contributor

@emmileaf emmileaf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yay concrete references! 🎉

Just a couple of small comments added. It looks like some changes here might also conflict with #1091 - I'll update the refactoring approach there if this PR is merged first.

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 5 Code Smells

100.0% 100.0% Coverage
0.0% 0.0% Duplication

Copy link
Contributor

@diegomarquezp diegomarquezp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - great!

@zhumin8 zhumin8 merged commit ed4b39e into autoconfig-gen-draft2 Nov 21, 2022
@zhumin8 zhumin8 deleted the add-spring-dep branch November 21, 2022 15:50
zhumin8 added a commit to GoogleCloudPlatform/spring-cloud-gcp that referenced this pull request Nov 21, 2022
suztomo pushed a commit that referenced this pull request Mar 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

spring pr that's related to spring code gen, intend to merge into autoconfig-gen-draft2 branch.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants