You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by doug5791 <to...@uwgb.edu> on 2014/03/31 23:51:32 UTC

Camel-Hazelcast: Configuring Consumer

I have a route that fills a Hazelcast IList "hlist" already running. The next
thing I would like to do is set up an additional route (seperate class) that
uses the Camel Hazelcast Consumer; listening for additions to the Hazelcast
instance already running and then continue to other endpoints.

I have followed the documentation  here
<http://camel.apache.org/hazelcast-component.html#>   for using the list
consumer. It mentions that there are header variables, but does not explain
how/when to use them.

When trying to run the below route, I receive "Exception in thread "main"
java.lang.NoSuchMethodError:
com.hazelcast.core.IList.addItemListener(Lcom/hazelcast/core/ItemListener;Z)V"
: 

fromF("hazelcast:%shlist", HazelcastConstants.LIST_PREFIX)
					.log("String...")
					    .choice()
					   
.when(header(HazelcastConstants.LISTENER_ACTION).isEqualTo(HazelcastConstants.ADDED))
					    	.log("...added")
					    	.to("hazelcast:seda:end")
					    	
					    .otherwise()
					    	.log("...failed to add!");

Any clarification or further implementation is appreciated,

-Doug



--
View this message in context: http://camel.465427.n5.nabble.com/Camel-Hazelcast-Configuring-Consumer-tp5749580.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Camel-Hazelcast: Configuring Consumer

Posted by doug5791 <to...@uwgb.edu>.
Thank you! Downgrading from Hazelcast 3.1.5 -> 2.6 solved the problem. The help you gave me was beyond valuable.

-Douglas Tober

From: Willem.Jiang [via Camel]<ma...@n5.nabble.com>
Sent: ‎Monday‎, ‎March‎ ‎31‎, ‎2014 ‎11‎:‎28‎ ‎PM
To: Douglas Tober<ma...@uwgb.edu>

Can you downgrade the Hazelcast to 2.6 which is tests with camel-2.12.x?


--
Willem Jiang

Red Hat, Inc.
Web: http://www.redhat.com
Blog: http://willemjiang.blogspot.com (English)
http://jnn.iteye.com (Chinese)
Twitter: willemjiang
Weibo: 姜宁willem



On April 1, 2014 at 11:30:48 AM, doug5791 ([hidden email]) wrote:

>
>
> These are the Hazelcast entries in my classpath, do you think that having
> the Java Hazelcast jars (top two highlighted) included is messing with it?
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Camel-Hazelcast-Configuring-Consumer-tp5749580p5749586.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>



________________________________
If you reply to this email, your message will be added to the discussion below:
http://camel.465427.n5.nabble.com/Camel-Hazelcast-Configuring-Consumer-tp5749580p5749591.html
To unsubscribe from Camel-Hazelcast: Configuring Consumer, click here<http://camel.465427.n5.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=5749580&code=dG9iZWRhMjFAdXdnYi5lZHV8NTc0OTU4MHwxNzM2OTQ0MzM3>.
NAML<http://camel.465427.n5.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble:email.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble:email.naml-instant_emails%21nabble:email.naml-send_instant_email%21nabble:email.naml>




--
View this message in context: http://camel.465427.n5.nabble.com/Camel-Hazelcast-Configuring-Consumer-tp5749580p5749670.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Camel-Hazelcast: Configuring Consumer

Posted by Willem Jiang <wi...@gmail.com>.
Can you downgrade the Hazelcast to 2.6 which is tests with camel-2.12.x?


--  
Willem Jiang

Red Hat, Inc.
Web: http://www.redhat.com
Blog: http://willemjiang.blogspot.com (English)
http://jnn.iteye.com (Chinese)
Twitter: willemjiang  
Weibo: 姜宁willem



On April 1, 2014 at 11:30:48 AM, doug5791 (tobeda21@uwgb.edu) wrote:
>  
>  
> These are the Hazelcast entries in my classpath, do you think that having
> the Java Hazelcast jars (top two highlighted) included is messing with it?
>  
>  
>  
> --
> View this message in context: http://camel.465427.n5.nabble.com/Camel-Hazelcast-Configuring-Consumer-tp5749580p5749586.html  
> Sent from the Camel - Users mailing list archive at Nabble.com.
>  


Re: Camel-Hazelcast: Configuring Consumer

Posted by doug5791 <to...@uwgb.edu>.
<http://camel.465427.n5.nabble.com/file/n5749586/classpath.png> 

These are the Hazelcast entries in my classpath, do you think that having
the Java Hazelcast jars (top two highlighted) included is messing with it?



--
View this message in context: http://camel.465427.n5.nabble.com/Camel-Hazelcast-Configuring-Consumer-tp5749580p5749586.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Camel-Hazelcast: Configuring Consumer

Posted by Willem Jiang <wi...@gmail.com>.
Can you double check the hazelcast jars in your class path?
I bet the jars’ versions were massed. 

--  
Willem Jiang

Red Hat, Inc.
Web: http://www.redhat.com
Blog: http://willemjiang.blogspot.com (English)
http://jnn.iteye.com (Chinese)
Twitter: willemjiang  
Weibo: 姜宁willem



On April 1, 2014 at 8:53:26 AM, doug5791 (tobeda21@uwgb.edu) wrote:
> I have a route that fills a Hazelcast IList "hlist" already running. The next
> thing I would like to do is set up an additional route (seperate class) that
> uses the Camel Hazelcast Consumer; listening for additions to the Hazelcast
> instance already running and then continue to other endpoints.
>  
> I have followed the documentation here
> for using the list
> consumer. It mentions that there are header variables, but does not explain
> how/when to use them.
>  
> When trying to run the below route, I receive "Exception in thread "main"
> java.lang.NoSuchMethodError:
> com.hazelcast.core.IList.addItemListener(Lcom/hazelcast/core/ItemListener;Z)V"  
> :
>  
> fromF("hazelcast:%shlist", HazelcastConstants.LIST_PREFIX)
> .log("String...")
> .choice()
>  
> .when(header(HazelcastConstants.LISTENER_ACTION).isEqualTo(HazelcastConstants.ADDED))  
> .log("...added")
> .to("hazelcast:seda:end")
>  
> .otherwise()
> .log("...failed to add!");
>  
> Any clarification or further implementation is appreciated,
>  
> -Doug
>  
>  
>  
> --
> View this message in context: http://camel.465427.n5.nabble.com/Camel-Hazelcast-Configuring-Consumer-tp5749580.html  
> Sent from the Camel - Users mailing list archive at Nabble.com.
>