You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Torsten Curdt <tc...@apache.org> on 2005/03/16 11:00:52 UTC
auto-reloading of java classes
I was just browsing the TreeProcessor code to
see where to hook in the subscribe and unsubscribe
to the fam notifications.
...and I am wondering if it might make
sense to change the sitemap reloading
mechanism.
Right now we are checking the last-modified
information for a sitemap.xconf change and
reload if there is any change.
What we want now is to *also* reload if any
of the files in the classpath has changed.
...which can be checked with a fam.
So either we could only subscribe the
TreeProcessor for classpath changes notifications
or let the fam check for the sitemap xconf as well.
Not sure. For n sitemaps the DelayedSource
approach might be a bit more scaleable.
Although I am not sure if thousands of
sitemaps are really a real world scenario.
WDYGT?
As for the fam integeration: IIUC we could
just add the subcribe to the SitemapLanguage
where the ClassLoader is being created. The
notification will then set a boolean we can
check in TreeProcessor.buildConcreteProcessor()
...or did I miss something? ConcreteProcessor,
ChildProcessor ...a lot of stuff in there :)
What I am still missing is a place the
unsubscribe the classpath from the fam.
I also had a look into the current
ClassLoaderFactory. It's Source-based
while the fam in jci is file based :-/
...I mean: we could come up with a Source-
base fam. But not sure. Feels a bit like
FS to support remote locations here.
WDYGT?
cheers
--
Torsten
Re: auto-reloading of java classes
Posted by Torsten Curdt <tc...@apache.org>.
Carsten Ziegeler wrote:
> I don't know which way is best, but whatever is done in this area,
> please make it configurable, so that all this checking can be turned off
> in production.
Of course :)
cheers
--
Torsten
Re: auto-reloading of java classes
Posted by Carsten Ziegeler <cz...@apache.org>.
I don't know which way is best, but whatever is done in this area,
please make it configurable, so that all this checking can be turned off
in production.
Carsten
Torsten Curdt wrote:
> I was just browsing the TreeProcessor code to
> see where to hook in the subscribe and unsubscribe
> to the fam notifications.
>
> ...and I am wondering if it might make
> sense to change the sitemap reloading
> mechanism.
>
> Right now we are checking the last-modified
> information for a sitemap.xconf change and
> reload if there is any change.
>
> What we want now is to *also* reload if any
> of the files in the classpath has changed.
> ...which can be checked with a fam.
>
> So either we could only subscribe the
> TreeProcessor for classpath changes notifications
> or let the fam check for the sitemap xconf as well.
>
> Not sure. For n sitemaps the DelayedSource
> approach might be a bit more scaleable.
> Although I am not sure if thousands of
> sitemaps are really a real world scenario.
>
> WDYGT?
>
> As for the fam integeration: IIUC we could
> just add the subcribe to the SitemapLanguage
> where the ClassLoader is being created. The
> notification will then set a boolean we can
> check in TreeProcessor.buildConcreteProcessor()
> ...or did I miss something? ConcreteProcessor,
> ChildProcessor ...a lot of stuff in there :)
>
> What I am still missing is a place the
> unsubscribe the classpath from the fam.
>
> I also had a look into the current
> ClassLoaderFactory. It's Source-based
> while the fam in jci is file based :-/
>
> ...I mean: we could come up with a Source-
> base fam. But not sure. Feels a bit like
> FS to support remote locations here.
>
> WDYGT?
>
> cheers
> --
> Torsten
>
--
Carsten Ziegeler - Open Source Group, S&N AG
http://www.s-und-n.de
http://www.osoco.org/weblogs/rael/
Re: auto-reloading of java classes
Posted by Pier Fumagalli <pi...@betaversion.org>.
On 16 Mar 2005, at 10:00, Torsten Curdt wrote:
> I was just browsing the TreeProcessor code to
> see where to hook in the subscribe and unsubscribe
> to the fam notifications.
>
> ...and I am wondering if it might make
> sense to change the sitemap reloading
> mechanism.
>
> Right now we are checking the last-modified
> information for a sitemap.xconf change and
> reload if there is any change.
>
> What we want now is to *also* reload if any
> of the files in the classpath has changed.
> ...which can be checked with a fam.
I assume you mean any of the resources loaded by the FAM classloader
(resource or .class file), right? Not anything that is in my
classpath...
Right?
Pier (classloading junkie!)