manishsat / typica

Automatically exported from code.google.com/p/typica
Apache License 2.0
0 stars 0 forks source link

Typica -1.7.2 compatibility with Apache 4.0 beta liraries #107

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Using the latest Typica.jar file
1. Instantiate Jec2 [Jec2 jec2 = new Jec2(sAWSKey, sAWSSecretKey);]
2. Try retrieving the number of instances running using [int instanceCount = 
jec2.describeInstances(new String[0]).size()]
3. Or any other related tasks. I believe they will give the same error.

What is the expected output? What do you see instead?
The number of instances running under my account but I get the error message 
attached below. My platform is typica-1.7.2 on CentOS 5.4 machine running JDK 6 
Update 18 

Please use labels and text to provide additional information.

The library requires several apache libraries which are in beta and according 
to this link, 
http://svn.apache.org/repos/asf/httpcomponents/httpclient/tags/4.0-beta1/RELEASE
_NOTES.txt, it appears various classes have been changed or removed.

So am left wondering if may be apache shall fix this or you could look into it.

Below is the error log that I got after running my program. Thanks.

Exception in thread "Thread-0" java.lang.ClassCastException: java.lang.String 
cannot be cast to org.apache.http.HttpHost
    at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:367)
    at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:555)
    at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:487)
    at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:465)
    at com.xerox.amazonws.common.AWSQueryConnection.makeRequest(AWSQueryConnection.java:474)
    at com.xerox.amazonws.ec2.Jec2.makeRequestInt(Jec2.java:2357)
    at com.xerox.amazonws.ec2.Jec2.runInstances(Jec2.java:651)
    at mascotinit.EC2.LaunchEC2Instance(EC2.java:147)
    at mascotinit.LaunchNodeClass.run(LaunchNodeClass.java:27)
    at java.lang.Thread.run(Thread.java:619)

Original issue reported on code.google.com by silaslab...@gmail.com on 15 Sep 2010 at 1:36

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Got same issue for typica 1.7 & 1.7.2 with httpclient 4.2.* 
Had to downgrade to typica 1.6 to make it work.

Original comment by aziz.kez...@gmail.com on 19 Apr 2014 at 10:44