Return-Path: Delivered-To: apmail-harmony-commits-archive@www.apache.org Received: (qmail 94611 invoked from network); 29 May 2007 12:30:38 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 29 May 2007 12:30:38 -0000 Received: (qmail 73420 invoked by uid 500); 29 May 2007 12:30:42 -0000 Delivered-To: apmail-harmony-commits-archive@harmony.apache.org Received: (qmail 73405 invoked by uid 500); 29 May 2007 12:30:42 -0000 Mailing-List: contact commits-help@harmony.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@harmony.apache.org Delivered-To: mailing list commits@harmony.apache.org Received: (qmail 73393 invoked by uid 99); 29 May 2007 12:30:42 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 29 May 2007 05:30:42 -0700 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 29 May 2007 05:30:37 -0700 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 58DFE71416E for ; Tue, 29 May 2007 05:30:16 -0700 (PDT) Message-ID: <29451633.1180441816358.JavaMail.jira@brutus> Date: Tue, 29 May 2007 05:30:16 -0700 (PDT) From: "Tim Ellison (JIRA)" To: commits@harmony.apache.org Subject: [jira] Updated: (HARMONY-2195) How to use aspects for tracing MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HARMONY-2195?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Tim Ellison updated HARMONY-2195: --------------------------------- Component/s: (was: Classlib) Contributions > How to use aspects for tracing > ------------------------------ > > Key: HARMONY-2195 > URL: https://issues.apache.org/jira/browse/HARMONY-2195 > Project: Harmony > Issue Type: Improvement > Components: Contributions > Reporter: Sian January > Priority: Trivial > Attachments: buildxmlpatch.txt, Tracing.aj > > > I'm creating this JIRA to store information and related files for how to use AspectJ for tracing in the class libraries. Instructions below for adding tracing to the math module: > 1. Download AspectJ from http://www.eclipse.org/aspectj/downloads.php > 2. Copy aspectjrt.jar to /depends/jars/aspectj/ > 3. Copy aspectjtools.jar and aspectjrt.jar to ANT_HOME/lib and if using Eclipse add both of these to your ant runtime configuration (Window > Preferences > Ant > Runtime > Add...) > 4. Edit build file to use iajc* instead of javac and include aspect class files (or apply the buildxmlpatch.txt to build.xml in the math module) > 5. Write a tracing aspect (or copy the one attached to modules\math\src\main\java\org\apache\harmony\tracing) > 6. Re-build the module > 7. Make sure to add aspectjrt.jar to the runtime classpath of whatever program you are running. > * - iajc isn't incremental like javac in ant, it will always do a total rebuild. Also if you switch from using iajc back to javac you will need to do a clean before you do a rebuild. > Please also note that it's not possible to use this kind of tracing for any classes that are depended on by the AspectJ runtime or there will be errors initializing the classes because of circular dependencies. However I think most modules apart from luni should be safe. Also it's important to not trace methods that are called (directly or indirectly) by your tracing methods otherwise you will end up in an endless loop. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.