+++ Johan Compagner [wicket-users] [Tue, Nov 06, 2007 at 05:40:37PM +0100]:
> On 11/5/07, Andrew MacKenzie <[EMAIL PROTECTED]> wrote:
> > Wicket 1.2
> > I've created my own implmentation of AbstractResourceStream to fetch the
> > content for some pages from another location (they are generated by
> > another site).
> >
> > One thing I'm not sure of is how often wicket will re-fetch this
> > resource from my code.  I notice a "lastModifiedTime()" function I have
> > to implement, and I wonder if wicket uses that to determine a timeout?
> > Does wicket do caching here or should I?
> wicket doesn't do the caching of the result of the AbstractResourceStream
> Wicket only passes that lastmodifiedtime to the browser, which should on
> his turn do the caching.
I'm good with that...

> So if you are sure that your stuff doesn't have to be updated a lot then
> you should cache it For every different client/browser we will call the
> data.
Well, I've got it up and running, but it appears that Wicket is caching
'something' because it is only requesting the content once (the first time
it's hit).  Even if the requests come from different browsers. 

Is there any documentation on how the resources are stored and used?  Can I
force wicket to 'refresh' content?

I've tried both deployment and development mode, and they seem to behave
the same.

Here's my code from the Application for reference (maybe I'm setting this
up incorrectly?):

CompoundResourceStreamLocator locator = (CompoundResourceStreamLocator)
    getResourceSettings().getResourceStreamLocator();
locator.add(0, new MyResourceLocator());

Remember, wicket 1.2.

-- 
// Andrew MacKenzie  |  http://www.edespot.com
// GPG public key: http://www.edespot.com/~amackenz/public.key
// "If my theory of relativity is proven successful, Germany will claim
//  me as a German and France will declare that I am a citizen of the
//  world. Should my theory prove untrue, France will say that I am a
//  German and Germany will declare that I am a Jew."
//     -- Albert Einstein

Attachment: pgpAKSsB1WHN9.pgp
Description: PGP signature

Reply via email to