VaultConfiguration - Class Loading Issue
See original GitHub issueGetting what appears to be a class loading issue when using the latest spring cloud + boot + spring-cloud-starter-vault-config versions:
***************************\nAPPLICATION FAILED TO START\n***************************\n\nDescription:\n\nAn attempt
was made to call a method that does not exist. The attempt was made from the following location:\n\n
org.springframework.cloud.vault.config.VaultConfiguration.createSslConfiguration(VaultConfiguration.java:101)\n\nThe
following method did not exist:
'void org.springframework.vault.support.SslConfiguration.<init>(org.springframework.vault.support.SslConfiguration$KeyStoreConfiguration,org.springframework.vault.support.SslConfiguration$KeyStoreConfiguration, java.util.List, java.util.List)'
The method's class, org.springframework.vault.support.SslConfiguration, is available from the following locations:
jar:file:/app.jar!/BOOT-INF/lib/spring-vault-core-2.3.0.jar!/org/springframework/vault/support/SslConfiguration.class
The class hierarchy was loaded from the following locations:
org.springframework.vault.support.SslConfiguration:
jar:file:/app.jar!/BOOT-INF/lib/spring-vault-core-2.3.0.jar!/\n\n\nAction:\n\nCorrect the classpath of your application
so that it contains a single, compatible version of org.springframework.vault.support.SslConfiguration
Spring Cloud: 2020.0.2
Spring Boot: 2.4.4
Gradle config for vault (org.springframework.cloud:spring-cloud-vault-config:3.0.2 right now):
runtimeOnly 'org.springframework.cloud:spring-cloud-starter-vault-config'
I cannot provide our application, unfortunately. I am confused as to why this constructor is being called, since I am unable to find a version of org.springframework.vault.support.SslConfiguration that has this constructor.
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Spring valut config not loading - Stack Overflow
You didn't specify you Vault properties, but judging by the error you are missing the spring.cloud.vault.host configuration.
Read more >Getting Started | Vault Configuration - Spring
This guide walks you through the process of using Spring Cloud Vault to build an application that retrieves its configuration properties from HashiCorp ......
Read more >Secure Secrets With Spring Cloud Config and Vault
Storing secrets in your code is a bad idea. Learn how to use Spring Cloud Config and HashiCorp Vault to make your app...
Read more >Java Application Demo | Vault - HashiCorp Developer
The demo Java application leverages the Spring Cloud Vault library to communicate with Vault. In the TransitConverter class, the convertToDatabaseColumn method ...
Read more >An Intro to Spring Cloud Vault - Baeldung
In general, migrating to Vault is a very simple process: just add the required libraries and add a few extra configuration properties to...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi,
I just ran into the same issue, and it turns out the
spring-cloud-config-dependencies
BOM (version 3.0.3) defines the version of the spring-vault-core as 2.3.0. That BOM is imported in thespring-cloud-dependencies
BOM (version 2020.0.2) before thespring-cloud-vault-dependencies
BOM (version 3.0.2), and seems to take precedence.Is this worth reporting in the spring cloud config repository, or at the spring cloud dependencies level ?
Edit: I just found out it was already tackled in spring-cloud/spring-cloud-config#1841
Thanks a lot for the update.