Petals SE Camel

Add ConsumesExt MONIT traces

Details

  • Type: Improvement Request Improvement Request
  • Status: Open Open
  • Priority: Major Major
  • Resolution: Unresolved
  • Affects Version/s: 0.5.0
  • Fix Version/s: 0.5.1, 1.4.0-BC
  • Component/s: None
  • Security Level: Public
  • Description:

    The idea is to have MONIT traces for flows starting from Camel (when it consumes something in the bus).

    Not sure this can be done easily because we have to plug into Camel's infrastructure...

  • Environment:
    -

Issue Links

Activity

Hide
Christophe DENEUX added a comment - Tue, 20 Sep 2016 - 17:12:28 +0200 - edited

Postponed to 1.2.1

Show
Christophe DENEUX added a comment - Tue, 20 Sep 2016 - 17:12:28 +0200 - edited Postponed to 1.2.1
Hide
Victor NOËL added a comment - Tue, 13 Oct 2015 - 10:28:19 +0200

One of the most problematic things arrising with this issue is the following:

  • Currently, when using Camel as a BC for incoming external events (i.e., having a route with a from that is not from petals), the flow are initialised at the moment the Petals service is called by the Camel SE.
  • So whatever happens before in the Camel SE (such as processing, execution, logging, etc), is NOT associated by the Camel SE to the current flow.

The solution would thus be to:

  • Detect that a route is starting but not from Petals
  • To initialise the flow just before and log the ConsumesExt MONIT trace.

This is not easy, as we have to plug in Camel infrastructure.
This is maybe not desired as it goes a bit agains SOA principles by doing the bindings to external events inside Camel instead of isolating it in a dedicated service.
This is maybe better if we can do it anyway because Camel is really helpful in many tricky situation where we need to interact with systems other than those supported by the Petals BC.

Show
Victor NOËL added a comment - Tue, 13 Oct 2015 - 10:28:19 +0200 One of the most problematic things arrising with this issue is the following:
  • Currently, when using Camel as a BC for incoming external events (i.e., having a route with a from that is not from petals), the flow are initialised at the moment the Petals service is called by the Camel SE.
  • So whatever happens before in the Camel SE (such as processing, execution, logging, etc), is NOT associated by the Camel SE to the current flow.
The solution would thus be to:
  • Detect that a route is starting but not from Petals
  • To initialise the flow just before and log the ConsumesExt MONIT trace.
This is not easy, as we have to plug in Camel infrastructure. This is maybe not desired as it goes a bit agains SOA principles by doing the bindings to external events inside Camel instead of isolating it in a dedicated service. This is maybe better if we can do it anyway because Camel is really helpful in many tricky situation where we need to interact with systems other than those supported by the Petals BC.
Hide
Victor NOËL added a comment - Thu, 1 Oct 2015 - 09:31:37 +0200

Reopening because there is more work to do

Show
Victor NOËL added a comment - Thu, 1 Oct 2015 - 09:31:37 +0200 Reopening because there is more work to do
Hide
Victor NOËL added a comment - Thu, 1 Oct 2015 - 09:31:27 +0200

A preliminary fix is in v0.5.1 (and thus will be in 1.0.0 at least).

Show
Victor NOËL added a comment - Thu, 1 Oct 2015 - 09:31:27 +0200 A preliminary fix is in v0.5.1 (and thus will be in 1.0.0 at least).
Hide
Victor NOËL added a comment - Wed, 30 Sep 2015 - 15:27:31 +0200

A first shot has been committed in https://github.com/petalslink/petals-se-camel/commit/da06d89edcef18a20dbe9fba39bf355bd2793514 and https://github.com/petalslink/petals-se-camel/commit/134af0dbd1e4e51b22af3eb6fb5cde1c26d3f5a2 (for Petals 4.3.x).

For now it considers that if there is no flow attributes available in the execution context, it means that we are acting as a BC.
A warning is logged to keep some traces of that assumption and then ConsumesExtFlow... MONIT traces are logged (ConsumesFlow... in Petals 4.3.x) around the call to the Petals service.

Show
Victor NOËL added a comment - Wed, 30 Sep 2015 - 15:27:31 +0200 A first shot has been committed in https://github.com/petalslink/petals-se-camel/commit/da06d89edcef18a20dbe9fba39bf355bd2793514 and https://github.com/petalslink/petals-se-camel/commit/134af0dbd1e4e51b22af3eb6fb5cde1c26d3f5a2 (for Petals 4.3.x). For now it considers that if there is no flow attributes available in the execution context, it means that we are acting as a BC. A warning is logged to keep some traces of that assumption and then ConsumesExtFlow... MONIT traces are logged (ConsumesFlow... in Petals 4.3.x) around the call to the Petals service.
Hide
Victor NOËL added a comment - Tue, 29 Sep 2015 - 17:07:58 +0200

We could at least initialize the a flow if there is no flow attributes presently available (most certainly because the exchange never entered in Camel from Petals) when the exchange is sent from Camel to Petals.

We should log a warning in that case to be sure we don't overlook another problem: this wouldn't solve this issue, but at least it would make it less problematic (see for example PETALSSECAMEL-10 for a case where it would be nice).

Show
Victor NOËL added a comment - Tue, 29 Sep 2015 - 17:07:58 +0200 We could at least initialize the a flow if there is no flow attributes presently available (most certainly because the exchange never entered in Camel from Petals) when the exchange is sent from Camel to Petals. We should log a warning in that case to be sure we don't overlook another problem: this wouldn't solve this issue, but at least it would make it less problematic (see for example PETALSSECAMEL-10 for a case where it would be nice).

People

Dates

  • Created:
    Tue, 22 Sep 2015 - 09:42:11 +0200
    Updated:
    Wed, 12 Apr 2023 - 10:08:53 +0200