camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From conflue...@apache.org
Subject [CONF] Apache Camel > Camel 3.0 - Message Store
Date Tue, 19 Feb 2013 15:47:00 GMT
<html>
<head>
    <base href="https://cwiki.apache.org/confluence">
            <link rel="stylesheet" href="/confluence/s/2042/9/1/_/styles/combined.css?spaceKey=CAMEL&amp;forWysiwyg=true"
type="text/css">
    </head>
<body style="background: white;" bgcolor="white" class="email-body">
<div id="pageContent">
<div id="notificationFormat">
<div class="wiki-content">
<div class="email">
    <h2><a href="https://cwiki.apache.org/confluence/display/CAMEL/Camel+3.0+-+Message+Store">Camel
3.0 - Message Store</a></h2>
    <h4>Page <b>edited</b> by             <a href="https://cwiki.apache.org/confluence/display/~christian.ohr">Christian
Ohr</a>
    </h4>
        <br/>
                         <h4>Changes (1)</h4>
                                 
    
<div id="page-diffs">
                    <table class="diff" cellpadding="0" cellspacing="0">
    
            <tr><td class="diff-snipped" >...<br></td></tr>
            <tr><td class="diff-unchanged" >This section intends to demonstrate
the usage of a Message Store by providing hypotethical code snippets, e.g. <br> <br></td></tr>
            <tr><td class="diff-changed-lines" ><span class="diff-changed-words">{code:<span
class="diff-added-chars"style="background-color: #dfd;">title=</span>AggregatorExample.java}</span>
<br></td></tr>
            <tr><td class="diff-unchanged" >... <br>from(...) <br></td></tr>
            <tr><td class="diff-snipped" >...<br></td></tr>
    
            </table>
    </div>                            <h4>Full Content</h4>
                    <div class="notificationGreySide">
        <div class='panelMacro'><table class='noteMacro'><colgroup><col
width='24'><col></colgroup><tr><td valign='top'><img src="/confluence/images/icons/emoticons/warning.gif"
width="16" height="16" align="absmiddle" alt="" border="0"></td><td><b>Work
in progress</b><br />The page intends to collect all ideas and proposals around
the idea of a Message Store as a architectural concept in Camel. No implementation has started
yet. You can participate by sharing your input here or post it to the dev mailing list.</td></tr></table></div>

<p>For the initial brainstorming on the dev mailing list, please check <a href="http://camel.465427.n5.nabble.com/DISCUSS-Message-Store-td5721454.html"
class="external-link" rel="nofollow">this thread</a>.</p>

<h4><a name="Camel3.0-MessageStore-FromtheCamel3.0ideaspage"></a>From the
Camel 3.0 ideas page</h4>

<p>(+1: hadrian, claus)<br/>
We should make this EIP easier to use for end users, but offering a better public API. And
also have a pluggable message store, with filters that can filter what should be stored. As
well pluggable marshallers so people can marshal data from Exchange into a format the message
store can store (BLOB, XML, JSon etc.).<br/>
A Message Store could provide transparent persistence to various EIP patterns (or used directly).
Implementations would handle the mapping to the underlying database or file system or NoSQL
or memory or whatever.<br/>
Message Store implementations are already there in various places, using different approaches,
like in Stream Caching (only file system), AggregationRepository or IdempotentRepository.
A Message Store is requested for in other places like Reliable stream resequencing (CAMEL-949)
or Persistent Dead Letter Queue (CAMEL-4575).</p>

<h3><a name="Camel3.0-MessageStore-Summary"></a>Summary</h3>

<p>In Camel 2.x, a <b>Message Store</b> is not a "first class citizen" in
the sense of a architectural concept, which can be applied consistently whereever needed.<br/>
Camel 3.0 should introduce a unified, generic, pluggable Message Store that consolidates the
different approaches and allows to similarly parameterize persistence to various EIP patterns.
<br/>
It should be usable independently of EIP patterns as well. <br/>
Implementations would handle the mapping to the underlying persistence layer, which can be
InMemory, RDBMS, NoSQL-based etc. and can be chosen based on the requirements towards reliability
(survive system shutdowns with losing messages) and scalability (reduce memory consumption
when processing many/big messages). </p>

<p>Side note: Spring Integration provides a <a href="http://static.springsource.org/spring-integration/reference/htmlsingle/#message-store"
class="external-link" rel="nofollow">corresponding concept</a>.</p>

<h3><a name="Camel3.0-MessageStore-Listofproposedfeatures"></a>List of proposed
features</h3>

<div class='panelMacro'><table class='noteMacro'><colgroup><col width='24'><col></colgroup><tr><td
valign='top'><img src="/confluence/images/icons/emoticons/warning.gif" width="16" height="16"
align="absmiddle" alt="" border="0"></td><td><b>Work in progress</b><br
/>At some time we probably need to assign priorities as to what is indispensable for Camel
3.0 and what could be delivered in a later patch release</td></tr></table></div>

<ul>
	<li>Generically, entries in a Message Store can be created, updated, read and deleted.</li>
	<li>Ability to temporarily store exchanges for the following EIPs:
	<ul>
		<li>Aggregator, Multicast, RecipientList, Splitter : alternative to AggregationRepository,
making it eventually obsolete</li>
		<li>Streaming Resequencer (CAMEL-949)</li>
		<li>Stream Caching <img class="emoticon" src="/confluence/images/icons/emoticons/help_16.gif"
height="16" width="16" align="absmiddle" alt="" border="0"/></li>
		<li>Claim check <img class="emoticon" src="/confluence/images/icons/emoticons/help_16.gif"
height="16" width="16" align="absmiddle" alt="" border="0"/></li>
	</ul>
	</li>
	<li>Ability to store exchanges for a defined period of time
	<ul>
		<li>Idempotent Consumer</li>
		<li>Dead Letter Queue (CAMEL-4575)</li>
		<li>Destination for the Tracer</li>
	</ul>
	</li>
	<li>Ability to permanently store exchanges (e.g. for audit trails)</li>
	<li>Provide a certain level of manual retry. That is to get the original message from
the store and feed it back in the originating route.</li>
	<li>Flexibility to specify what part of an exchange should be stored (e.g. what exchange
properties and message headers) and in which format (e.g. object serialization, JSON, using
encryption)</li>
	<li>Possibility to provide a filter condition to determine which exchanges should be
stored (e.g. only failed exchanges, only with a certain message header)</li>
	<li>Polling Consumer to randomly access a message store</li>
	<li>Producer to write an exchange into a message store</li>
</ul>


<h3><a name="Camel3.0-MessageStore-Examples"></a>Examples</h3>

<p>This section intends to demonstrate the usage of a Message Store by providing hypotethical
code snippets, e.g.</p>

<div class="code panel" style="border-width: 1px;"><div class="codeHeader panelHeader"
style="border-bottom-width: 1px;"><b>AggregatorExample.java</b></div><div
class="codeContent panelContent">
<pre class="code-java">
...
from(...)
   .aggregate()
       .correlationExpression(header(id))
       .aggregationStrategy(myStrategy)
       .completionTimeout(10000)
       .messageStore(myStore)
...
</pre>
</div></div>

    </div>
        <div id="commentsSection" class="wiki-content pageSection">
        <div style="float: right;">
            <a href="https://cwiki.apache.org/confluence/users/viewnotifications.action"
class="grey">Change Notification Preferences</a>
        </div>
        <a href="https://cwiki.apache.org/confluence/display/CAMEL/Camel+3.0+-+Message+Store">View
Online</a>
        |
        <a href="https://cwiki.apache.org/confluence/pages/diffpagesbyversion.action?pageId=30754294&revisedVersion=9&originalVersion=8">View
Changes</a>
                |
        <a href="https://cwiki.apache.org/confluence/display/CAMEL/Camel+3.0+-+Message+Store?showComments=true&amp;showCommentArea=true#addcomment">Add
Comment</a>
            </div>
</div>
</div>
</div>
</div>
</body>
</html>

Mime
View raw message