Issue Type: Bug Bug
Assignee: Sebastien Blanc
Components: examples
Created: 04/Jul/13 1:28 PM
Description:

I have run into an issue trying to integrate the latest java-sender 0.1.0 release with the quickstart-backend.

After modifying the 'defaultJavaSender.sendTo' in the sendLeads method to use the extra'masterSecret' param and changing the import to use the 'org.jboss.aerogear' namespace, the war compiled and installed successfully.

I then created some Leads and then pushed the 'Send Lead' button but in the console I got the following exception:

19:04:14,755 ERROR [org.jboss.aerogear.controller.log] (http--0.0.0.0-8080-1) AG_CONTROLLER000005: Exception Message: 'loader constraint violation: when resolving method 
"org.jboss.resteasy.client.core.executors.ApacheHttpClient4Executor.<init>(Lorg/apache/http/client/HttpClient;Lorg/apache/http/protocol/HttpContext;)V" the class loader (instance of org/jboss/modules/ModuleClassLoader) of the current class, org/jboss/aerogear/unifiedpush/resteasy/RestEasyClient, and the class loader (instance of org/jboss/modules/ModuleClassLoader) for resolved class, 
org/jboss/resteasy/client/core/executors/ApacheHttpClient4Executor, have different Class objects for the type org/apache/http/client/HttpClient used in the signature': java.lang.LinkageError: loader constraint violation: when resolving method 
"org.jboss.resteasy.client.core.executors.ApacheHttpClient4Executor.<init>(Lorg/apache/http/client/HttpClient;Lorg/apache/http/protocol/HttpContext;)V" the class loader (instance of org/jboss/modules/ModuleClassLoader) of the current class, org/jboss/aerogear/unifiedpush/resteasy/RestEasyClient, and the class loader (instance of org/jboss/modules/ModuleClassLoader) for resolved class, 
org/jboss/resteasy/client/core/executors/ApacheHttpClient4Executor, have different Class objects for the type org/apache/http/client/HttpClient used in the signature
	at org.jboss.aerogear.unifiedpush.resteasy.RestEasyClient.submitPayload(RestEasyClient.java:85) [java-sender-0.1.0.jar:0.1.0]

After a quick search some people suggested of duplicate libs, checked the WEB-INF folder and found some duplicate jars provided by the server already (e.g. jax-rs) mainly because of the transitive deps of the java-sender
https://gist.github.com/cvasilak/d2b7a60e93bf7bf31b1d

so I exclude them from the pom file and redeploy. But then I got another exception of a missing class

org.apache.http.auth.Credentials

Not sure where the problem lies..

You can find the changes on my 'java.sender' branch here:

https://github.com/cvasilak/aerogear-push-quickstart-backend/tree/java.sender

Thanks

Project: AeroGear Push
Priority: Major Major
Reporter: Christos Vasilakis
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira