summaryrefslogtreecommitdiffstats
path: root/sandbox/rfeng
diff options
context:
space:
mode:
authorrfeng <rfeng@13f79535-47bb-0310-9956-ffa450edef68>2008-08-06 06:19:25 +0000
committerrfeng <rfeng@13f79535-47bb-0310-9956-ffa450edef68>2008-08-06 06:19:25 +0000
commit5a72ea787bcc11690a47a78b333709e0b9b111bb (patch)
treeea59ed4e624a7e5d0ad561c87936d2b7307771e5 /sandbox/rfeng
parentb345ace31d62072eeaa27a2027f7e1a8da23c2ce (diff)
Update to aspectj 1.6.1
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@683127 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sandbox/rfeng')
-rw-r--r--sandbox/rfeng/aop-logging/pom.xml21
-rw-r--r--sandbox/rfeng/aop-logging/src/main/java/org/apache/tuscany/sca/aspectj/TracingAspect.java10
-rw-r--r--sandbox/rfeng/aop-logging/src/test/java/org/apache/tuscany/sca/aspectj/MyTracingAspect.java4
3 files changed, 25 insertions, 10 deletions
diff --git a/sandbox/rfeng/aop-logging/pom.xml b/sandbox/rfeng/aop-logging/pom.xml
index a08af87a44..1c14ac250b 100644
--- a/sandbox/rfeng/aop-logging/pom.xml
+++ b/sandbox/rfeng/aop-logging/pom.xml
@@ -22,22 +22,29 @@
<parent>
<groupId>org.apache.tuscany.sca</groupId>
<artifactId>tuscany-modules</artifactId>
- <version>1.0-incubating-SNAPSHOT</version>
+ <version>1.4-SNAPSHOT</version>
+<!--
<relativePath>../pom.xml</relativePath>
+-->
</parent>
<artifactId>tuscany-aop-logging</artifactId>
<name>Apache Tuscany AOP-based Logging and Tracing</name>
<dependencies>
<dependency>
- <groupId>aspectj</groupId>
+ <groupId>org.aspectj</groupId>
<artifactId>aspectjrt</artifactId>
- <version>1.5.3</version>
+ <version>1.6.1</version>
+ </dependency>
+ <dependency>
+ <groupId>org.aspectj</groupId>
+ <artifactId>aspectjlib</artifactId>
+ <version>1.6.1</version>
</dependency>
<dependency>
- <groupId>aspectj</groupId>
+ <groupId>org.aspectj</groupId>
<artifactId>aspectjweaver</artifactId>
- <version>1.5.3</version>
+ <version>1.6.1</version>
<scope>test</scope>
</dependency>
</dependencies>
@@ -59,14 +66,14 @@
<!-- I hit a bug in maven-surefire-plugin
http://jira.codehaus.org/browse/SUREFIRE-128 -->
<!--
- <argLine>-ea -Xmx128m -javaagent:&quot;${settings.localRepository}/aspectj/aspectjweaver/1.5.3/aspectjweaver-1.5.3.jar&quot;</argLine>
+ <argLine>-ea -Xmx128m -javaagent:&quot;${settings.localRepository}/aspectj/aspectjweaver/1.6.1/aspectjweaver-1.6.1.jar&quot;</argLine>
-->
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>aspectj-maven-plugin</artifactId>
- <version>1.0-beta-2</version>
+ <version>1.0</version>
<configuration>
<complianceLevel>1.5</complianceLevel>
<!--
diff --git a/sandbox/rfeng/aop-logging/src/main/java/org/apache/tuscany/sca/aspectj/TracingAspect.java b/sandbox/rfeng/aop-logging/src/main/java/org/apache/tuscany/sca/aspectj/TracingAspect.java
index 91489bae7d..7a6e4c5ded 100644
--- a/sandbox/rfeng/aop-logging/src/main/java/org/apache/tuscany/sca/aspectj/TracingAspect.java
+++ b/sandbox/rfeng/aop-logging/src/main/java/org/apache/tuscany/sca/aspectj/TracingAspect.java
@@ -35,15 +35,19 @@ public abstract class TracingAspect {
@Pointcut("")
protected abstract void entry();
- @Pointcut("call(* java..*.*(..))")
+ /** ignore join points outside this scope - use within(..) */
+ @Pointcut("")
+ protected abstract void withinScope();
+
+ @Pointcut("withinScope() && call(* java..*.*(..))")
protected void exit() {
}
- @Pointcut("entry() && !cflowbelow(entry())")
+ @Pointcut("withinScope() && entry() && !cflowbelow(entry())")
void start() {
}
- @Pointcut("cflow(entry()) && !exit() && !cflowbelow(exit()) && !within(org.apache.tuscany.sca.aspectj.*Aspect)")
+ @Pointcut("withinScope() && cflow(entry()) && !cflowbelow(exit()) && !within(org.apache.tuscany.sca.aspectj.*Aspect)")
void trace() {
}
diff --git a/sandbox/rfeng/aop-logging/src/test/java/org/apache/tuscany/sca/aspectj/MyTracingAspect.java b/sandbox/rfeng/aop-logging/src/test/java/org/apache/tuscany/sca/aspectj/MyTracingAspect.java
index a6e9f90518..4babfcca65 100644
--- a/sandbox/rfeng/aop-logging/src/test/java/org/apache/tuscany/sca/aspectj/MyTracingAspect.java
+++ b/sandbox/rfeng/aop-logging/src/test/java/org/apache/tuscany/sca/aspectj/MyTracingAspect.java
@@ -41,6 +41,10 @@ public class MyTracingAspect extends TracingAspect {
@Pointcut("execution(* org.apache.tuscany.sca.aspectj.TracingTestCase.testAOP(..))")
protected void entry() {
}
+
+ @Pointcut("within(org.apache.tuscany.sca..*)")
+ protected void withinScope() {
+ }
@Override
protected void logEnter(StaticPart jp) {