« September 2005 | Main | January 2006 »

December 21, 2005

Something you *don't* want to see...

For once, this is not a post about AspectJ!

Not wanting to name names, but I was using the woolwich cashpoint in southampton airport terminal building last night. I put my card into the machine, entered my pin, selected the amount of cash I wanted to withdraw.... whirr, whirr, whirr, clunk. Blank screen for several seconds, then the cash machine started rebooting! The boot sequence of a cash machine that has your card in it is not something you want to see. The thing that surprised me as the cash machine slowly came back into life is that is was running on.......... OS/2 Warp!!! There's an operating system I haven't seen in a long time. Making some educated guesses, that probably means the operator is a "blue" company, and that the back end was probably CICS running on Z/OS - which gives me some comfort as the 2PC probably worked and I won't be charged for the cash I never got (though I'm still going to check my statement ;)).

I never got my card back of course (the machine swallowed it for good - which if you think about it is all you can safely design it to do, since if the user has walked away in disgust in the interim period, spitting the card back out wouldn't exactly be safe). So I had to call my bank and cancel the card. It should take about 3 working days to get me a new one they reckon. So I have no card and no cash in the run-up to Christmas :(.

And yes, this is a true story, not just a ploy to get you to buy the round this Christmas!!

Posted by adrian at 10:01 AM [permalink] | Comments (2)

AspectJ 1.5.0 is here at last!

It was a long road....

But I'm delighted to say that AspectJ 1.5.0 final has now shipped. You can get a copy of the command line compiler and tools from the AspectJ downloads page. You can also get AspectJ 5 integrated into the final releases of :

AspectJ 5 breaks new ground for the world of AOP in a number of areas including (afaik - please correct me if this is not the case):

  • The first AOP language to fully support Java 5
  • The first implementation of generic aspects (using type parameters in pointcuts, advice, and ITDs in addition to regular generics features)
  • The first aspect language to provide a full reflection API (AjTypeSystem)
  • The first aspect language to offer code-style, annotation-style (@AspectJ) and XML based configuration with the same weaver and semantics

Now that the code is finally released, I'm finally able to spend more time talking about some of the new features. Ron Bodkin highlighted one new "hidden nugget" in AspectJ 5 in his blog entry. Here's another one: What do you do the night before a release? Update the docs of course! So one of the things I spent Monday night doing was updating the popular AspectJ "quick reference" to include all of the AspectJ 5 features. Time to download the AspectJ 5 quick reference and update the copy on your wall. It is on your wall isn't it ;)

Posted by adrian at 09:50 AM [permalink] | Comments (0)

December 15, 2005

Lots of new toys...

AspectJ 5 RC1, AJDT 1.2.1 RC1, and AJDT 1.3.0 RC1

It's been a really busy last few weeks for me. Yesterday we finally made it to RC1 of AspectJ 5 (a release that has been a long time coming). This enabled AJDT to also put out RC1 releases for Eclipse 3.0 and 3.1. From a purely technical perspective, AspectJ 5 has been the hardest (and most technically interesting) thing that I've worked on in my career to date. It's a full update to the AspectJ language for Java 5 (but it also has lots of improvements over 1.2.1 for folks on JDK 1.4 or 1.3 as well). The edited highlights of the release include:

  • Full generics support in pointcuts and inter-type declarations
  • Generic aspects (this is a really cool language feature that opens up a lot of possibilities - I'll write more about this and the other features over the next few weeks). My favourite quote from Andy (Clement) on this one... "implementing generic aspects is rocket science" :)
  • Full support for varargs, autoboxing, and covariance in pointcut expressions and join point matching
  • A new aspect instantiation model, pertypewithin
  • A whole new syntax, the "@AspectJ" annotation-based syntax for those stuck with tools that can't cope with the AspectJ keywords (are you reading Rob? ;) )
  • Dramatically improved load-time weaving support
  • A full reflection API, the AjTypeSystem - it's like the java.lang.reflect package but understands the AspectJ type system and can give details of pointcuts, advice, itds, and so on as well as methods and fields etc..
  • A weaver tools API, that amongst other things, opens up the AspectJ pointcut parsing and matching engine for third-party integration. We exploit this to good effect in...

Spring 2.0 M1

Last week was The Spring Experience conference in Miami. What a great event and an amazing atmosphere - it really was something to be part of. We used the event to announce and release Spring 2.0 M1 (we also used the days right before the conference to finish 2.0 M1 - no trips to the beach for I21!). Spring 2.0 has significantly improved ease-of-use for AOP, and is much more powerful at the same time thanks to much closer integration with AspectJ.

The news of Spring 2.0 has spawned two of the most active threads on TSS in a long time:

Here's a summary of the Spring 2.0 AOP enhancements - there's much more to write about all this soon...

  • Spring AOP is remaining as a proxy-based framework offering the ability to advise bean method execution. The facilities that Spring AOP offers are complementary to AspectJ in that they offer runtime control of advice on a per-instance basis, for beans managed by the Spring container.
  • The configuration of Spring AOP is dramatically simplified in Spring 2.0 using the new XML schema support. Configuration of transactions is simplified even further. Spring 2.0 remains fully backwards compatible of course.
  • Spring 2.0 adds the ability to use the AspectJ 5 pointcut language when configuring Spring advisors and aspects (you can write an AspectJ pointcut expression directly in the xml file). This still uses the Spring AOP proxy framework (not AspectJ) to implement the advice behaviour, but it uses AspectJ 5 to parse and match the pointcut expressions. This gives Spring users the option to use a powerful and flexible pointcut language (that understands generics, varargs, covariance, annotations, and so on) that works consistently across both Spring and AspectJ. It also means that Spring pointcut expressions can refer to pointcuts in compiled AspectJ libraries when using Spring and AspectJ together.
  • Spring 2.0 adds support for @AspectJ aspects (aspects written using the AspectJ 5 annotations such as @Aspect). If you have an @AspectJ style aspect, Spring can support it using the Spring AOP framework. You then have the choice to seamlessly switch from Spring AOP to AspectJ based weaving if you find you need greater performance or features that go beyond the capabilities of the Spring AOP framework.
  • Spring 2.0 ships with a new jar, spring-aspects.jar, which will contain a number of AspectJ aspects for working with the Spring framework. Use of these is entirely optional of course. The first of these is a "BeanConfigurer" aspect that enables Spring to dependency inject domain objects simply by annotating them with "@Configurable" (the annotation is @SpringConfigured in CVS, but we plan on changing the name). We believe the ability to dependency inject domain objects (created using the new operator, or by your ORM mapping tool for example) is a big step forward for folks who want to embrace richer domain models (and from TSE last week, I can tell you that there certainly seem to be a good number of them).
  • Spring AOP as a framework is not growing beyond its original boundaries. Instead we've simplified the configuration and enabled the use of the AspectJ pointcut language and even @AspectJ aspects. Instead of replacing Spring AOP with AspectJ, or growing the capabilities of Spring AOP beyond its current bounds, we believe in providing a seamless roadmap from using the out-of-the-box Spring aspects (such as the transaction management support), thru writing your own Spring aspects and advisors, and onto AspectJ aspects, without any jarring discontinuities. Thus you can use as little or as much of the capabilities as you need, and as your requirements change there will be a solution available to support you.

    Posted by adrian at 10:24 AM [permalink] | Comments (0)