Return-Path: Delivered-To: apmail-camel-dev-archive@www.apache.org Received: (qmail 78262 invoked from network); 12 Apr 2010 10:08:07 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 12 Apr 2010 10:08:07 -0000 Received: (qmail 97689 invoked by uid 500); 12 Apr 2010 10:08:07 -0000 Delivered-To: apmail-camel-dev-archive@camel.apache.org Received: (qmail 97572 invoked by uid 500); 12 Apr 2010 10:08:07 -0000 Mailing-List: contact dev-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@camel.apache.org Delivered-To: mailing list dev@camel.apache.org Received: (qmail 97559 invoked by uid 500); 12 Apr 2010 10:08:06 -0000 Delivered-To: apmail-activemq-camel-dev@activemq.apache.org Received: (qmail 97555 invoked by uid 99); 12 Apr 2010 10:08:05 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Apr 2010 10:08:05 +0000 X-ASF-Spam-Status: No, hits=-1265.7 required=10.0 tests=ALL_TRUSTED,AWL X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Apr 2010 10:08:04 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o3CA7ido024314 for ; Mon, 12 Apr 2010 06:07:44 -0400 (EDT) Message-ID: <11638460.1421271066864036.JavaMail.jira@thor> Date: Mon, 12 Apr 2010 06:07:44 -0400 (EDT) From: "Jim Talbut (JIRA)" To: camel-dev@activemq.apache.org Subject: [jira] Commented: (CAMEL-2563) The Trace mechanism is inflexible and inefficient - specifically it doesn't enable custom tracing around a node. In-Reply-To: <78257883.18211269005150642.JavaMail.jira@brutus.apache.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: ae95407df07c98740808b2ef9da0087c [ https://issues.apache.org/activemq/browse/CAMEL-2563?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=58793#action_58793 ] Jim Talbut commented on CAMEL-2563: ----------------------------------- Claus, Just noticed that you removed the exceptionFromProcess handling to capture an exception during a process and make that available to the trace and I'm wondering why. I put that in there because the tracer is occuring before the exception is handled (and added to the exchange), so I don't think there is any way to know that a process has failed without it - have I got that wrong? > The Trace mechanism is inflexible and inefficient - specifically it doesn't enable custom tracing around a node. > ---------------------------------------------------------------------------------------------------------------- > > Key: CAMEL-2563 > URL: https://issues.apache.org/activemq/browse/CAMEL-2563 > Project: Apache Camel > Issue Type: Improvement > Components: camel-core > Affects Versions: 2.3.0 > Environment: All. > Reporter: Jim Talbut > Assignee: Claus Ibsen > Priority: Minor > Fix For: 2.3.0 > > Attachments: tracechanges.diff, tracechanges.diff, tracechanges.diff, tracechanges.diff, tracechanges.diff > > Original Estimate: 2 days > Remaining Estimate: 2 days > > What it won't let me do: > I want to be able to correlate the "out" trace with the "in" trace, in one database row without commiting the row until the route has completed. > This requires a JPA transaction to exist around each of the nodes that are called. > I'm finding that the transaction has ended by the time of the "out" trace. > Inefficiencies: > 1. It causes the construction of the new Exchange object and a bunch of String objects that I don't want. > 2. It causes the invocation of a new route, that is unnecessary. > I think it would be better to: > 1. Pass the class to use as the TraceInterceptor into Tracer. > 2. Break the existing TraceInterceptor into two, a base class that tracks the RouteNodes and a subclass that implements traceExchange. > 3. Change traceExchange so that it returns an Object and pass that Object in to the call to traceExchange for "out" traces. > 4. Give the Tracer a payload object that can be used to pass information to the TraceInterceptor. > 5. Change the various trace* functions to take in and return a payload Object. > Custom users could then dervice from TraceInterceptor and override the trace* functions as necessary (probably just traceExchange). > I'm working on a patch. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira