On Mon, Jan 16, 2012 at 11:08 PM, Chris Colman
<chr...@stepaheadsoftware.com> wrote:
> Forget that last bit about wicketstuff not using the 'wicket' namespace
> for its resources. I was confused by some old files in the browser cache
> from Dec 2011.

/resources/ in 1.4 is the same as /wicket/resource/ in 1.5
Which project exactly in wicketstuff do you mean ?

>
> ________________________________
>
> From: Chris Colman [mailto:chr...@stepaheadsoftware.com]
> Sent: Tuesday, 17 January 2012 8:49 AM
> To: users@wicket.apache.org
> Subject: Controlling URL of static cacheable resources
>
> I'm trying to make static resources have a distinguishable part of their
> URL near the beginning of the URL to enable easy configuration of third
> party filters that need to ignore requests for static resources and just
> proceed along the filter chain.
>
> I've looked up the operation of
> org.apache.wicket.request.resource.caching.IResourceCachingStrategy#deco
> rateUrl but it appears that it only has the ability to make changes near
> the end of the resource URL after all the major segments of the URL have
> already been set ie., after this part
>
> /wicket/resource/org.apache.wicket.... rest of pathname.ClassName
>
> What I am trying to do is get all static resources to end up with a
> distinguishable URL that starts off something like:
>
> /wicket/resource/static/pathname.ClassName
>
> so I can configure a filter to ignore /wicket/resource/static/*
>
> In BasicResourceReferenceHandler.mapHandler() perhaps after adding the
> resource identifier segment:
>
> segments.add(getContext().getResourceIdentifier());
>
> it could append an extra segment for static resources:
>
> final IResource resource = reference.getResource();
>
> // if static resource
> if (resource instanceof IStaticCacheableResource)
> {
> segments.add("static");
> }
>
> And so end up with /wicket/resource/static/org.apache.wicket ...
>
>
>
> I also observed that Wicketstuff resources don't use the /wicket
> namespace prefix. They just start out at
>
> /resources/org.name.project.MyClass.script.js
>
> So they'd need a separate ignore entry in the filter.
>
>
> Yours sincerely,
>
> Chris Colman
>
> Pagebloom Team Leader,
> Step Ahead Software
>
>
> pagebloom - your business & your website growing together
>
> Sydney:           (+61 2) 9656 1278     Canberra: (+61 2) 6100 2120
> Email: chr...@stepahead.com.au <mailto://chr...@stepahead.com.au>
> Website:
> http://www.pagebloom.com <blocked::http://www.pagebloom.com/>
> http://develop.stepaheadsoftware.com
> <blocked::http://develop.stepaheadsoftware.com/>
>
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to