abdera-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dan Diephouse" <dan.diepho...@mulesource.com>
Subject Re: Refactoring AbstractProvider to make it open for extension
Date Fri, 04 Jul 2008 18:28:57 GMT
Could you file a JIRA with a patch? It sounds interesting and I do see the
issues that you mention.

On Fri, Jul 4, 2008 at 1:43 PM, Sergio Bossa <sergio.bossa@gmail.com> wrote:

> Hi all,
> I'm working on a large project which will extensively use Apache Abdera.
> We will have to support the OpenSearch (OS from now on) specification,
> so while trying to enhance Abdera support for OS, I saw that the
> AbstractProvider class, which is the core of the whole server
> infrastructure, is poorly implemented as a bunch of "if" statements
> depending on the TargetType for actual request processing.
> This makes very hard to add request processing features to the
> AbstractProvider, because it forces you to modify the class itself by
> adding more and more "if" statements.
> That said, I've refactored the AbstractProvider class, removed all
> "if" statements and added the concept of "RequestProcessor", a
> strategy-like interface to implement for request processing logic: by
> doing so, adding request processing logic is just a matter of
> implementing an interface and registering it under a given TargetType.
> I've tested my work against all Abdera unit tests and everything works
> fine.
> What do you think about that?
> If you think it could be useful, I'd be more than happy to contribute it.
> Cheers,
> Sergio B.
> --
> Sergio Bossa
> Software Passionate, Java Technologies Specialist and Open Source
> Enthusiast.
> Blog : http://sbtourist.blogspot.com
> Sourcesense - making sense of Open Source : http://www.sourcesense.com
> Pro-netics s.p.a. : http://www.pronetics.it

Dan Diephouse
http://mulesource.com | http://netzooid.com/blog

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message