Hi,
not sure if I got your requirements right, but a few ideas:
the static diagrams may make it difficult to see the dynamic options in
camel/activemq
make a recipientlist where you send to various topics suited to your needs
read up on various features of activemq: wildcards, composite destinations, …
be careful with topics in activemq
test it
test harder
A camel exchange can contain any Java object. You could route only your project
id and then look up the content later. Or you can choose to include everything
in the first place. The choice is yours.
You can populate the recipientList for instance by setting a header:
from("direct:a")
.recipientList(header("foo"));
for instance if header „foo" contains „jms:topic:projectA“ your exchange will
be routed to a jms topic named projectA.
You can set your header dynamically based on something in your input data. You
a completely free.
Cheers, Thomas.
> Am 18.03.2016 um 15:51 schrieb camrider <[email protected]>:
>
> I am new to Camel and have immersed myself in lots of tutorials and examples,
> but I still can't seem to get what I want with regards to implementing from
> scratch an activity feed. Camel was recommended in a response to
> http://stackoverflow.com/questions/16861026/need-a-framework-for-a-notification-dashboard-system
> , and an answer says:
> You would first create a topic to which you post messages. Then when a user
> registers for email notifications, you would add an email endpoint for
> him/her. And when they opt-out of Email, you will remove that endpoint.
>
> I would like the last n (say 10) events stored with the user to represent an
> activity feed, but also have an email (optionally) sent on the event if the
> user subscribes to it. For example the system has Projects and Users, and
> Users can choose to follow a Project so they will be notified of a Project
> status change in their feed and optional email message sent.
>
> I have installed JBoss Fuse Integration in Eclipse to try and make some sort
> of diagram of this, but I don't think I can represent the dynamic management
> of endpoints as described in a static diagram. Unless I use a pattern like
> Recipient List? If so then how do I dynamically create the list? With a
> custom processor?
>
> The other thing I want to know is what goes in the message that is being
> routed? Can the original message/event contain only a Project id and then
> Camel components can lookup the object and do queries to find the rest of
> the information, like Project details, followers, and their User details
> like email address? Or should all that information be gathered up front so
> that components can be configured with no need to access external resources
> (like a database)?
>
>
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/Activity-feeds-and-email-notifications-tp5779279.html
> Sent from the Camel - Users mailing list archive at Nabble.com.