I keep getting:
Exception in thread "main" java.lang.NoSuchMethodError: org.apache.http.conn.ssl.SSLConnectionSocketFactory.<init>(Ljavax/net/ssl/SSLContext;Ljavax/net/ssl/HostnameVerifier;)V
at com.amazonaws.http.conn.ssl.SdkTLSSocketFactory.<init>(SdkTLSSocketFactory.java:56)
at com.amazonaws.http.apache.client.impl.ApacheConnectionManagerFactory.getPreferredSocketFactory(ApacheConnectionManagerFactory.java:87)
at com.amazonaws.http.apache.client.impl.ApacheConnectionManagerFactory.create(ApacheConnectionManagerFactory.java:65)
at com.amazonaws.http.apache.client.impl.ApacheConnectionManagerFactory.create(ApacheConnectionManagerFactory.java:58)
at com.amazonaws.http.apache.client.impl.ApacheHttpClientFactory.create(ApacheHttpClientFactory.java:50)
at com.amazonaws.http.apache.client.impl.ApacheHttpClientFactory.create(ApacheHttpClientFactory.java:38)
at com.amazonaws.http.AmazonHttpClient.<init>(AmazonHttpClient.java:253)
at com.amazonaws.AmazonWebServiceClient.<init>(AmazonWebServiceClient.java:145)
at com.amazonaws.AmazonWebServiceClient.<init>(AmazonWebServiceClient.java:136)
at com.amazonaws.AmazonWebServiceClient.<init>(AmazonWebServiceClient.java:121)
at com.amazonaws.services.elasticmapreduce.AmazonElasticMapReduceClient.<init>(AmazonElasticMapReduceClient.java:175)
at com.amazonaws.services.elasticmapreduce.AmazonElasticMapReduceClient.<init>(AmazonElasticMapReduceClient.java:155)
at ExtractRelatedPairs.main(ExtractRelatedPairs.java:30)
Visual description which illustrates all the added jars (on the left) and their version for inspection.
Despite the fact that all needed jars are added, tried all the different jars and versions, even tried to change project's settings to work with 1.6 1.7 instead of 1.8...
Any ideas?
Assuming your project is built with Maven, adding this to your pom.xml
should take care of that issue:
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>4.5.2</version>
</dependency>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With