GitHub user igarashitm opened a pull request:

    https://github.com/apache/camel/pull/1585

    CAMEL-11054 Create SPI for Log EIP to enable other components to inte…

    …rcept/enrich logged messages
    
    # PLEASE DO NOT MERGE - this is continued from 
https://github.com/apache/camel/pull/1559
    
    Hi @davsclaus , @objectiser , 
    
    Here is an outline sketch for the CAMEL-11054. Let's start from here:
    * adds `addCamelLoggerListener()`/`getCamelLoggerListeners()` on 
`CamelContext`
    * `CamelLogger` holds a list of `CamelLoggerListener`
    * for Log EIP, `LogDefinition` copies `CamelLoggerListener`s from 
`CamelContext` to `CamelLogger`
    * for Log Component, `LogEndpoint` copies `CamelLoggerListener`s from 
`CamelContext` to `CamelLogger`
    * `CamelLoggerListener#onLog()` to receive a log event and return an 
enriched log message
    
    Questions:
    * do we want to extract `enrich()` from `onLog()` so it could be done 
separately?
    * do we want separated handler like `onWarn()`, `onInfo()` and etc. rather 
than `onLog()`?
    * any other event we want to handle in `CamelLoggerListener`?
    * As both of Log EIP and Component use `CamelLogger`, it's easy to add it 
on both of them. Is it OK or do we want it only on Log EIP?
    
    Any comment would be appreciated!

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/igarashitm/camel CAMEL-11054

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/camel/pull/1585.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1585
    
----

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to