RE: Caching DirectoryGenerator.

2002-07-12 Thread Vadim Gritsenko

> From: ROSSEL Olivier [mailto:[EMAIL PROTECTED]]
> 
> I am currently using DirectoryGenerator.
> My concern is that it is probably a non-cacheable component, so each
time
> a request is made, each time a listing of my directory is made.
> 
> Of course, files in my directory change once in a century, so the
> DirectoryGenerator almost always gives the same result.
> 
> If there is no caching system, I would like to make a kind of
home-made
> caching strategy, using a separate file which timestamp would keep
> track of the modification in my directories (== I 'touch' this file
> each time I write something in my directories), so I check
> this timestamp against the last time the DirectoryGenerator
> was accessed, make a test and send a cached DirectoryGenerator result
> instead of launching the component.
> 
> Is it possible to make that in current architecture?
> Is it possible to tune the caching strategy (with actions, for
example).

Unfortunately, no.

But you can create CacheableDirectoryGenerator, which is not complex at
all in your case.


PS IIRC, DirectoryGenerator is (or will) being refactored in the 2.1
scratchpad. At least, there were talks about it.


Vadim



-
Please check that your question  has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail:   <[EMAIL PROTECTED]>




Caching DirectoryGenerator.

2002-07-12 Thread ROSSEL Olivier

I am currently using DirectoryGenerator.
My concern is that it is probably a non-cacheable component, so each time
a request is made, each time a listing of my directory is made.

Of course, files in my directory change once in a century, so the
DirectoryGenerator almost always gives the same result.

If there is no caching system, I would like to make a kind of home-made
caching strategy, using a separate file which timestamp would keep
track of the modification in my directories (== I 'touch' this file
each time I write something in my directories), so I check
this timestamp against the last time the DirectoryGenerator
was accessed, make a test and send a cached DirectoryGenerator result
instead of launching the component.

Is it possible to make that in current architecture?
Is it possible to tune the caching strategy (with actions, for example).

-
Please check that your question  has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail:   <[EMAIL PROTECTED]>