# For Jest Client Implementation\[How to add sslcontext class patch to the httclient-osgi jar

**URL:** <https://discuss.elastic.co/t/for-jest-client-implementation-how-to-add-sslcontext-class-patch-to-the-httclient-osgi-jar/35877>\
**Category:** Elasticsearch\
**Created:** [November 30, 2015, 10:00am UTC](https://discuss.elastic.co/t/for-jest-client-implementation-how-to-add-sslcontext-class-patch-to-the-httclient-osgi-jar/35877 "2015-11-30T10:00:46Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![balubollam](https://avatars.discourse-cdn.com/v4/letter/b/a587f6/32.png) [@balubollam](https://discuss.elastic.co/u/balubollam)\
**Post date:** [November 30, 2015, 10:00am UTC](https://discuss.elastic.co/t/for-jest-client-implementation-how-to-add-sslcontext-class-patch-to-the-httclient-osgi-jar/35877/1 "2015-11-30T10:00:46Z")

</div>

HI Everyone  
I am implementing Jest client for Amazon client client connection.But iam getting this following

error:Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/http/ssl/SSLContexts  
at org.apache.http.conn.ssl.SSLConnectionSocketFactory.getSocketFactory(SSLConnectionSocketFactory.java:172) at io.searchbox.client.config.HttpClientConfig$Builder.build(HttpClientConfig.java:247)  
Caused by: java.lang.ClassNotFoundException: org.apache.http.ssl.SSLContexts

But when i R&D on this i had come to know that \*I need to add patch to the httpcontext-osji using dependencies i.e adding pom.xml Can Any one Please help me out how to add this patch or How to solve this error?

Thanks and regards  
Balaji

---

<div class="post-metadata">

**Author:** ![jiayanju](https://avatars.discourse-cdn.com/v4/letter/j/4491bb/32.png) [@jiayanju](https://discuss.elastic.co/u/jiayanju)\
**Post date:** [December 17, 2015, 5:43pm UTC](https://discuss.elastic.co/t/for-jest-client-implementation-how-to-add-sslcontext-class-patch-to-the-httclient-osgi-jar/35877/2 "2015-12-17T17:43:19Z")

</div>

I also encountered the same problem. In my side It's caused by the jar conflict. There is no org/apache/http/ssl/SSLContexts in lower version http client. So I suggest you checking the jar conflict in your project.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 5, 2017, 11:30pm UTC](https://discuss.elastic.co/t/for-jest-client-implementation-how-to-add-sslcontext-class-patch-to-the-httclient-osgi-jar/35877/3 "2017-07-05T23:30:06Z")

</div>


