GoogleCloudPlatform / spring-cloud-gcp

New home for Spring Cloud GCP development starting with version 2.0.
Apache License 2.0
410 stars 303 forks source link

The Spring Autogen Script should automatically remove the modules that aren't in the libraries-bom #2176

Open mpeddada1 opened 11 months ago

mpeddada1 commented 11 months ago

Recently, the com.google.cloud:google-cloud-game-servers library was removed from libraries-bom. However, running the Generate Spring Auto-Configurations job results in the following error, requiring a manual removal of the module in https://github.com/GoogleCloudPlatform/spring-cloud-gcp/pull/2175:

Error:    The project com.google.cloud:google-cloud-game-servers-spring-starter:4.7.3-SNAPSHOT-preview (/home/runner/work/spring-cloud-gcp/spring-cloud-gcp/spring-cloud-previews/google-cloud-game-servers-spring-starter/pom.xml) has 1 error
Error:      'dependencies.dependency.version' for com.google.cloud:google-cloud-game-servers:jar is missing. @ com.google.cloud:google-cloud-game-servers-spring-starter:${project.parent.version}-preview, /home/runner/work/spring-cloud-gcp/spring-cloud-gcp/spring-cloud-previews/google-cloud-game-servers-spring-starter/pom.xml, line 19, column 17

This line in the generate.sh script has some logic to get the list of libraries from the monorepo given a [LIBRARIES_BOM version]. However, this happens a little late in the job cycle: https://github.com/GoogleCloudPlatform/spring-cloud-gcp/blob/736fcdcb6af258481c60a45e548baec3ecc3af72/.github/workflows/generateAutoConfigs.yaml#L80 Specifically, after the Compile auto-gen libraries step

Potential Solution: We may need to add some logic to the generate.sh script to determine which modules are currently absent from the libraries-bom and delete them spring-cloud-gcp-previews.

mpeddada1 commented 8 months ago

Downgraded to P3 as we haven't noticed too many instances of this so far (apart from google-cloud-game-servers)

blakeli0 commented 3 months ago

We could use the libraries list from generation_config.yaml now.