Did you create the secret manually by base64 encoding the trust store yourself? Some base64 encoding tools insert extra bytes to pad the data and that could be the issue here. Try running the following command to create the secret instead:
kubectl create secret generic elasticsearch-truststore-secret --from-file=truststore.jks -n dev
It's hard to debug your issue because it happens in a different application. I don't think it's a problem with the way ECK generates certificates as I have managed to run a local Spark job using an ECK-managed Elasticsearch cluster and its certificates. In theory, that should work the same way inside a Kubernetes cluster as well. A couple of things you could check are:
@charith-elastic, Thanks for the tips, I achieved to solve my problem !
It was a wrong path to the location of my truststore file.
I set the wrong following configuration in spark
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.