Comments on: Aspect Oriented Programming (AOP) in PL/SQL – Is it hot? Is it cool? Or utterly useless? Friends of Oracle and Java Wed, 27 May 2015 22:00:57 +0000 hourly 1 By: Lucas Jellema Tue, 07 Mar 2006 13:01:46 +0000 Gerwin,

The jury is still out. I do not believe that you should rush in, take my prototype imlpementation and start using it for real. What I hope to achieve is get smart people thinking about the concept of AOP applied
to a PL/SQL development environment. AOP can be very powerful. Whether the PL/SQL
technology can be AOP-enabled in a viable way is still a question. For AOP to work, there needs to be a blance between development taks and developer’s and project manager’s mentality on the one hand and supporting tools and technology on the other.

However, having said all that, there is no reason why we could not start with AOP for very simple things like logging or debugging. The proof of the pudding…

By: Lucas Jellema Tue, 07 Mar 2006 12:57:27 +0000 About a year ago, a series of posts – all referencing this article (Ansi SQL-AOP 2015 Released) – discussed SQL and AOP.

It seems this was just a strange sort of joke however.

By: GerwinT Tue, 07 Mar 2006 07:27:42 +0000 The title of this post interested me. After reading it I understand the concept of AOP. In the title you ask: “Is it Hot? Is it Cool or is it utterly useless?” The concept itselve looks usefull to me. However I still wonder whether your implementation of this concept within PL/SQL is usefull or not. Can you answer this question?

By: Lucas Jellema Sun, 05 Mar 2006 21:14:38 +0000 Andrej,

Thanks for your comment. Good to hear from you again.

Like I say in the article, what I am doing here is compile time AOP – or even slightly before compile time, as the source itself is altered. What I mention but do not show in code is that it is not very hard to define the aspects to apply external to the code. So that aspect (no pun intended) is covered. However, as you saw in the examples, it will be impossible to change an aspect and not recompile the advised code (as is the case with Java’s Compile Time AOP solutions. What I have not worked out in a very neat fashion, is how to define the aspects outside of the AOP Processor.

All in all, I wanted to get people – like yourself – thinking about ways forward with PL/SQL. Many good ideas and concepts are being developed in other arenas, like the Java arena, that may very well be applicable to PL/SQL programming as well. Expect my article on Dependency Injection in PL/SQL later this week (I am not kidding you).

By: Andrej Sat, 04 Mar 2006 16:47:00 +0000 This seems more like adding macros than aop to plsql (also very useable). The power of aop is that you can externally specify where to add the extra functionality. I think it will be very hard to add aop to plsql. As you mention, because of wrapping you can’t apply the aspects to the source code, so you’d have to manipulate the pcode generated by oracle. For java you have some good bytecode manipulating libraries, I’m not aware of anything similar for plsql. Plus, you can also compile plsql to platform dependent code, which makes pcode manipulation almost impossible.