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

Spring cloud GCP data spanner fails with spring boot 3.4.X #3487

Open
vvahtola opened this issue Jan 21, 2025 · 1 comment
Open

Spring cloud GCP data spanner fails with spring boot 3.4.X #3487

vvahtola opened this issue Jan 21, 2025 · 1 comment
Labels

Comments

@vvahtola
Copy link

When trying to start a spring boot 3.4.X -based app that uses spring cloud gap data spanner to configure spanner functionality, the following error prevents the app from starting:


An attempt was made to call a method that does not exist. The attempt was made from the following location:
com.google.cloud.spring.autoconfigure.spanner.SpannerTransactionManagerAutoConfiguration$DatabaseClientTransactionManagerConfiguration.spannerTransactionManager(SpannerTransactionManagerAutoConfiguration.java:68)

The following method did not exist:

'void org.springframework.boot.autoconfigure.transaction.TransactionManagerCustomizers.customize(org.springframework.transaction.PlatformTransactionManager)'

The calling method's class, com.google.cloud.spring.autoconfigure.spanner.SpannerTransactionManagerAutoConfiguration$DatabaseClientTransactionManagerConfiguration, was loaded from the following location:

jar:file:/Users/.../.m2/repository/com/google/cloud/spring-cloud-gcp-autoconfigure/5.10.0/spring-cloud-gcp-autoconfigure-5.10.0.jar!/com/google/cloud/spring/autoconfigure/spanner/SpannerTransactionManagerAutoConfiguration$DatabaseClientTransactionManagerConfiguration.class

The called method's class, org.springframework.boot.autoconfigure.transaction.TransactionManagerCustomizers, is available from the following locations:

jar:file:/Users/.../.m2/repository/org/springframework/boot/spring-boot-autoconfigure/3.4.1/spring-boot-autoconfigure-3.4.1.jar!/org/springframework/boot/autoconfigure/transaction/TransactionManagerCustomizers.class

The called method's class hierarchy was loaded from the following locations:

org.springframework.boot.autoconfigure.transaction.TransactionManagerCustomizers: file:/Users/.../.m2/repository/org/springframework/boot/spring-boot-autoconfigure/3.4.1/spring-boot-autoconfigure-3.4.1.jar

Action:

Correct the classpath of your application so that it contains compatible versions of the classes com.google.cloud.spring.autoconfigure.spanner.SpannerTransactionManagerAutoConfiguration$DatabaseClientTransactionManagerConfiguration and org.springframework.boot.autoconfigure.transaction.TransactionManagerCustomizers


Downgrading the app to use spring boot 3.3.7 allows the app to run.

br,
VVV

@zhumin8
Copy link
Contributor

zhumin8 commented Jan 21, 2025

The current released versions are not compatible with spring boot 3.4.x yet.
We are working on a new version in #3411, and will be released soon after the release of Spring Boot 3.4.2.

I would recommend waiting for this release and report back to us if this is still an issue. Otherwise, you can also test out from the feature branch.

cc. @diegomarquezp

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants