I'm struggling to make my spring boot application start, it presents this error at boot:
***************************
APPLICATION FAILED TO START
***************************
Description:
An attempt was made to call a method that does not exist. The attempt was made from the following location:
com.google.api.services.sqladmin.SQLAdmin$Builder.chooseEndpoint(SQLAdmin.java:7296)
The following method did not exist:
'boolean com.google.api.client.http.HttpTransport.isMtls()'
The method's class, com.google.api.client.http.HttpTransport, is available from the following locations:
jar:file:/Users/benz/.m2/repository/com/google/http-client/google-http-client/1.35.0/google-http-client-1.35.0.jar!/com/google/api/client/http/HttpTransport.class
The class hierarchy was loaded from the following locations:
com.google.api.client.http.HttpTransport: file:/Users/benz/.m2/repository/com/google/http-client/google-http-client/1.35.0/google-http-client-1.35.0.jar
Action:
Correct the classpath of your application so that it contains a single, compatible version of com.google.api.client.http.HttpTransport
Let me specify that this application has two configurations:
After a big update, the Cloud profile doesn't work anymore due to this problem.
From what I read, it could be a dependency problem that must be resolved through maven.
[INFO] +- com.google.firebase:firebase-admin:jar:6.16.0:compile
[INFO] | +- com.google.api-client:google-api-client:jar:1.30.10:compile
[INFO] | | +- com.google.oauth-client:google-oauth-client:jar:1.31.0:compile
[INFO] | | \- com.google.http-client:google-http-client-jackson2:jar:1.36.0:compile
[INFO] | +- com.google.api-client:google-api-client-gson:jar:1.30.10:compile
[INFO] | | \- com.google.http-client_:google-http-client-gson:jar:1.36.0:compile
[INFO] | +- com.google.http-client:google-http-client:jar:1.35.0:compile
As far as I can see, here's the only http-client that is repeating. I've tried to downgrade the firebase-admin
library, but it's dependencies remained at the same version number.
Probably I'm doing something wrong. Does somebody have an idea on how to solve this problem? I've lost many hours...with no luck...
Thank you
This method was included in the google-http-java-client
among other changes to add support for mtls. This is the relevant commit.
This code was released on version 1.38.0
of the library.
That library version seems to be compatible with your firebase-admin
version.
Please, try to include the following as a first level Maven dependency:
<dependency>
<groupId>com.google.http-client</groupId>
<artifactId>google-http-client</artifactId>
<version>1.38.0</version>
</dependency>
Probably you can use a more recent version of google-http-client
as well.