I have the application.properties, which is located in the resources
apllication.properties
hsm.provider=software hsm.name=TestHsm h
Okay, i solved it with the top answer of this Question. I put the variables and @Values in the signature of the constructor and not as class variables.