Support Questions
Find answers, ask questions, and share your expertise

Failed to load SSL keystore src/main/resources/cert/trust.jks of type JKS

Failed to load SSL keystore src/main/resources/cert/trust.jks of type JKS

New Contributor

In local its working fine but when deploy into pcf its not loading the certifcate file from location.getting below exception

 

Caused by: org.apache.kafka.common.KafkaException: Failed to load SSL keystore src/main/resources/cert/trust.jks of type JKS
2021-03-24T00:22:50.301+05:30 [APP/PROC/WEB/0] [ERR] at org.apache.kafka.common.security.ssl.SslFactory$SecurityStore.load(SslFactory.java:330)
2021-03-24T00:22:50.301+05:30 [APP/PROC/WEB/0] [ERR] at org.apache.kafka.common.security.ssl.SslFactory.createSSLContext(SslFactory.java:226)
2021-03-24T00:22:50.301+05:30 [APP/PROC/WEB/0] [ERR] at org.apache.kafka.common.security.ssl.SslFactory.configure(SslFactory.java:135)
2021-03-24T00:22:50.302+05:30 [APP/PROC/WEB/0] [ERR] ... 22 more
2021-03-24T00:22:50.302+05:30 [APP/PROC/WEB/0] [ERR] Caused by: java.io.FileNotFoundException: src/main/resources/cert/trust.jks (No such file or directory)
2021-03-24T00:22:50.302+05:30 [APP/PROC/WEB/0] [ERR] at java.io.FileInputStream.open0(Native Method)
2021-03-24T00:22:50.302+05:30 [APP/PROC/WEB/0] [ERR] at java.io.FileInputStream.open(FileInputStream.java:195)
2021-03-24T00:22:50.302+05:30 [APP/PROC/WEB/0] [ERR] at java.io.FileInputStream.<init>(FileInputStream.java:138)
2021-03-24T00:22:50.302+05:30 [APP/PROC/WEB/0] [ERR] at java.io.FileInputStream.<init>(FileInputStream.java:93)
2021-03-24T00:22:50.302+05:30 [APP/PROC/WEB/0] [ERR] at org.apache.kafka.common.security.ssl.SslFactory$SecurityStore.load(SslFactory.java:323)
2021-03-24T00:22:50.302+05:30 [APP/PROC/WEB/0] [ERR] ... 24 more