cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Simone Gianni <>
Subject Re: Javaflow in 2.2 and the continuation class loader
Date Tue, 01 Aug 2006 23:21:58 GMT

Torsten Curdt wrote:

> The most important one you guys missed: jci :)
> The idea is that you either have jar getting statically instrumented
> via ant task or maven plugin (there is currently work on the way to
> support instrumentation through the maven2 compiler plugin ...but
> still a fair amount to do as we need to port all existing compilers to
> jci) ...or you have source code and use the file monitor that either
> listens on file changes in your eclipse class directory or even
> compiles your java source files from source.
> That's the setup I've demonstrated in Amsterdam. (I've actually still
> have that setup on disk)

Currently this is not happening : the ReloadingClassLoader is there, and
it manages Jci stores, but could not get how to actually configure a
JavaflowResourceStore in it so that my javaflow classes/sources gets
compiled/reloaded and most important enhanced.

> At the moment I might not have too much time I can spend to help. (
> ) But I am happy to guide you
> through to get this working as good as I can.
Maurizio can have some time to sort this out and I'll be aside him, so
quick questions are :
- From a user point of view, how do we specify packages to be enhanced?
... Use the flow class package by default?
... What if the user have (and we have :) ) a helper class which extends
AbstractContinuable as well since it needs to send some pages but is not
in the same pakage as each javaflow class since it's shared among them?
Ho do we enhance that too?
- How do we say to the JavaInterpreter that a certain class or package
has already been enhanced with ant/maven and so the normal classloader
should be used? Is there a way to determine it automagically?
- How do we register a JavaflowResourceStore in the
ReloadingClassLoader? (so that we can also subscribe to events and
reload the methods only when it changes)?

Just give us pointers and hints, we'll take care of details if we manage
to :)

In the meanwhile i recovered the two basic javaflow samples (Calculator
and Form) so that we have something to test with, I'm committing them now.

> > Shouldn't be there a CocoonContinuationClassLoader that mimics the
> > jakarta common ContinuationClassLoader behaviour but enhancing classes
> > that extends AbstractContinuable?

> I am not really a big fan of the AbstractContinuable marker
> class/interface anymore. Well, was never really. I would prefer to
> separate the classes via package path or class name convention.

I do agree, but currently IMMO breaking compatibility completely with
old applications is not a good idea. Maybe we should provide a
"LegacyJavaflowClassloader" as well, which takes care of the old
AbstractContinuable marker (and also make the transition between
"doSomething" and "something" a bit softer) raising warnings as it has
been made for the components in the sitemap.

Also I think that a class that extends AbstractContinuable should be
enhanced anyway because it could call a sendPageAndWait somewhere and
simply generate exceptions.


Simone Gianni

View raw message