Facing "com.solacesystems.jms.ConfigurationException: Unable to load trust store" in OCP4.x (K8s)

Options
Pavithra
Pavithra Member Posts: 7 ✭✭

Hi Team

I have developed a spring boot application which reads message from solace queue and store it to a DB. My app works fine in local IDE, physical linux VMs and even in testbox podman containers.

However, below exception occurs when I try to deploy the same in OpenShift container platform (4.x).

I load the solace trust & key store as secret via k8s deployment. But I validated, the keystore is not corrupted.

I wanted to check if anyone faced similar issue…

——- Exception details——-

Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [jakarta.jms.Connection]: Factory method 'connection' threw exception with message: Unable to load trust store: /apps/certs/solace.p12
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:171)
at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:655)
... 40 common frames omitted
Caused by: com.solacesystems.jms.ConfigurationException: Unable to load trust store: /apps/certs/solace.p12
at com.solacesystems.jms.SolConnection.<init>(SolConnection.java:172)
at com.solacesystems.jms.SolConnection.<init>(SolConnection.java:91)
at com.solacesystems.jms.SolConnectionFactoryImpl.createConnection(SolConnectionFactoryImpl.java:112)
at com.sc.rdc.ods.config.BeanConfig.connection(BeanConfig.java:41)
at com.sc.rdc.ods.config.BeanConfig$$SpringCGLIB$$0.CGLIB$connection$0(<generated>)
at com.sc.rdc.ods.config.BeanConfig$$SpringCGLIB$$2.invoke(<generated>)
at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:258)
at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:331)
at com.sc.rdc.ods.config.BeanConfig$$SpringCGLIB$$0.connection(<generated>)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.base/java.lang.reflect.Method.invoke(Unknown Source)
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:139)
... 41 common frames omitted

Answers

  • Pavithra
    Pavithra Member Posts: 7 ✭✭
    edited March 5 #2
    Options

    The directory which holds the certs are out side to my class path but it has full permission for owner and other to read the file.

    Is there a way to find the RCA and fix it… Seeking advice from solace expertise.

    😥

    @hong @Tamimi