[
https://issues.apache.org/jira/browse/CAMEL-5581?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13452028#comment-13452028
]
Claudio Corsi commented on CAMEL-5581:
--------------------------------------
The reason that I added this suggestion was that if I wanted to retrieve some
data from a hbase repository but want to also log the original exchange after
processing the hbase information then in this case I am unable to do just that.
The hbase component does not provide the ability to forward any data from the
in-message to the out-message except for the hbase specific data. You are
limited to what is retrieved from hbase and any other data is lost along the
way.
There are ways that can be used to forward that information using for instance
the dynamic router pattern to route the message to its destination based on the
hbase result but this does not provide an ability to propagate the hbase data
to the destination unless you add all of that information on the required end
point string returned.
Looking at the content enricher pattern, I see the use of this technique but in
the prior case. Looking at the aggregation strategy example. This technique
will try to combine to results into one but it does not seem to allow for the
ability to use data from the in-coming exchange to be used by the aggregating
exchange. You would need to create a Processor that uses the exchange in-coming
message to setup a call to hbase and use the results in conjunction with the
in-message to generate the out-message that will be forwarded to the resulting
endpoint. Your suggestion would require that the aggregate resource exchange
instance would have to use a general endpoint. If you are using a really large
hbase set of data. You would want to minimize the size of the returned data.
I do not see how that can be done unless you create multiple endpoints which
will clutter the application.
I might be wrong in my assessment and will look at this further and thanks for
the feedback. It is greatly appreciated.
> Add an ExchangeStrategy to the HBase Component.
> -----------------------------------------------
>
> Key: CAMEL-5581
> URL: https://issues.apache.org/jira/browse/CAMEL-5581
> Project: Camel
> Issue Type: Improvement
> Components: camel-hbase
> Affects Versions: 2.10.1, 2.11.0
> Reporter: Claudio Corsi
> Assignee: Claus Ibsen
> Priority: Minor
> Fix For: 2.11.0, 2.10.2
>
> Attachments: hbase-exchange-strategy.patch
>
>
> The current hbase component does not provide the ability to forward of the
> exchange information except for the associated hbase data.
> This improvement adds the concept of an ExchangeStrategy that users can
> extend and allow them to include information from the current exchange
> in-coming message to the out-going message.
> I have a default implementation that does nothing that can be extended by a
> user. This default implementation can be extended in the future such that
> users will then not be required to add missing methods.
--
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