|
November 2003
[
avasseur
]
19:37, Friday, 21 November 2003
Samuel has done a viewlet where he demonstrates how to easily debug an application and its aspects with AspectWerkz from within Eclipse. If you did not yet understood how standard and easy it was from my first annoucement, you have to watch it now ! All is explained step by step. This is a definitely a things to work with.
[
avasseur
]
11:00, Wednesday, 12 November 2003
The latest snapshot of AspectWerkz is now supporting JRockit JVM for on the fly weaving. By using JRockit JMAPI capabilities, AspectWerkz brings AOP one step ahead by officially supporting all major JVM (Sun, IBM, BEA). This allows to hook AspectWerkz in a seamless way to provide dynamic on the fly weaving of Aspects no matter your environment. JRockit could not be supported before due to lack of HotSwap support and a limitation that forbids overriding of java.lang.ClassLoader with a -Xbootclasspath option. Users had to use offline mode until there. The extension will be core part of coming 0.9 AspectWerkz release, so that all VM are supported with the smallest integration cost (Sun, IBM, JRockit). Tests have been made with
The JMAPI JRockit API (management API) allows to add a classPreProcessor mechanism using a java snip or a command line option. It is possible to hook or unhook AspectWerkz programmatically using JMAPI:
JVMFactory.getJVM().getClassLibrary().setClassPreProcessor(
new JRockitPreProcessor());
To launch a JVM with AspectWerkz hooked in for class load time weaving this consists of a single option: /jrockit/bin/java -Xmanagement:class=org.codehaus.aspectwerkz.extension.jrockit.JRockitPreProcessor .... If you are a JRockit fan, please help us and give a try to AspectWerkz online mode by your own. We need your feedback to make it suits your needs. We will provide extensive documentation with the 0.9 release, but for the impatient :
[
avasseur
]
12:14, Monday, 3 November 2003
Last day I realized that using ThreadLocal can be very dangerous when it comes to long running applications and garbage collections. When you read the documentation of the ThreadLocal, you read that the object put in a ThreadLocal context is associated to the thread, and will be garbaged once the thread is dead.
So if you use ThreadLocal to store some object instance there is a high risk to have the object stored in the thread local never garbaged when your app runs inside an app server like WebLogic Server, which manage a pool of working thread - even when the class that created this ThreadLocal instance is garbage collected. To solve this issue, you will probably have to check for it first with a memory profiler tool like JProfiler, and then wrap the value put in the ThreadLocal in a WeakReference. That did not appears to be obvious while reading the javadoc. Isn't it ? |