cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marc Salvetti <m...@notremanou.net>
Subject Re: issues with images matcher
Date Mon, 11 Apr 2005 09:32:41 GMT
Hello,

Just to conclude the thread,
the problem wasn't a matching problem, but a more complex issue as the 
server (resin)  was answering with an error 304 to any request for the 
images after the first one. 304 means the client already have the images 
(which wasn't always the case)
Since then my only solution had been to move from resin to tomcat, so i 
think there is still a bug between the caching system of resin and the 
caching system of cocoon.

Best regards,

Marc


My problem

Marc Salvetti a écrit :

> I tried it already, doesn't solve my pb :-(
>
> actually, i'm even wondering if the pb is a matcher pb, because the 
> images where loading correctly with the additional /x/ in the path 
> yesterday, but today they don't load again !
> but i still don't know where to start tracking the pb (access.log says 
> the images are processed by cocoon)
> this is getting really annoying as the website is supposed to be 
> online by the end of the week...
>
> Anyone get more ideas ??
>
> Cheers,
>
> Marc
>
> Daniel McOrmond a écrit :
>
>>Marc,
>>
>>Just use two matchers, like this:
>>
>><map:pipeline>
>> <map:match pattern="images/*.gif">
>>  <map:read mime-type="images/gif" src="resources/images/{1}.gif"/>
>> </map:match>
>> <map:match pattern="**/images/*.gif">
>>  <map:read mime-type="images/gif" src="resources/images/{2}.gif"/>
>> </map:match>
>></map:pipeline>
>>
>>-Daniel
>>
>>
>>On Tue, 22 Mar 2005 10:27:41 +0700, Marc Salvetti <marc@notremanou.net> wrote:
>>  
>>
>>>Daniel, thanks for the answer,
>>>
>>>indeed this solution is working for all images on pages not on root level.
>>>Still, if an image is on the root level, i need to add this fake path to
>>>have it work because the first / isn't always interpreted
>>>
>>>so i have to use in my images "/cfm/x/images/myimage.gif" where "cfm" is
>>>my sitemap prefix, and "x" doesn't exist...
>>>still not very clean :-\
>>>
>>>Marc
>>>
>>>Daniel McOrmond a écrit :
>>>
>>>    
>>>
>>>>Marc,
>>>>
>>>>You might try adding a slash between your wildcard characters and the
>>>>string, like this:
>>>>
>>>><map:match pattern="**/images/**">
>>>>
>>>>This is how I've seen it done, and it's always worked properly for me.
>>>>
>>>>-Daniel
>>>>
>>>>
>>>>On Mon, 21 Mar 2005 15:22:01 +0700, Marc Salvetti <marc@notremanou.net>
wrote:
>>>>
>>>>
>>>>      
>>>>
>>>>>Hello,
>>>>>i'm having a weird problem with the loading of images.
>>>>>
>>>>>i use theses 3 matchers in the sitemap for loading gif and jpg :
>>>>>
>>>>>     <map:match pattern="**images/*.gif">
>>>>>       <map:read src="images/{2}.gif" mime-type="image/gif"/>
>>>>>     </map:match>
>>>>>
>>>>>     <map:match pattern="**images/*.jpg">
>>>>>       <map:read src="images/{2}.jpg" mime-type="image/jpeg"/>
>>>>>     </map:match>
>>>>>
>>>>>     <map:match pattern="**photos/**.jpg">
>>>>>       <map:read src="photos/{2}.jpg" mime-type="image/jpeg"/>
>>>>>     </map:match>
>>>>>
>>>>>on my local computer (windows, tomcat 5, cocoon 2.1.5.1) everything
>>>>>works fine, the images are loaded normally whatever the path.
>>>>>
>>>>>on the server (linux, resin, cocoon 2.1.5.1) it's getting really weird.
>>>>>no images would load under the normal path (usually images/*.gif or
>>>>>/cfm/images/*.gif)
>>>>>i had to hack by adding a fake directory (/cfm/x/images/*.gif) to have
>>>>>most of the images loading correctly.
>>>>>however, this hack seems not to be working with some images (i couldn't
>>>>>understand why some work and not the others)
>>>>>
>>>>>i noticed also that requesting the images with firefox or ie makes a
>>>>>difference somehow (maybe ie stripping a / somewhere, i don't know) or
>>>>>another caching pb... i don't know.
>>>>>for example in ie :
>>>>>http://www.cf-mekong-4test.net/cfm//photos/map_cv.jpg loads the image
>>>>>http://www.cf-mekong-4test.net/cfm/x/photos/map_cv.jpg doesn't load the
>>>>>image (but get the size of an old version of the image !)
>>>>>http://www.cf-mekong-4test.net/cfm/a/photos/map_cv.jpg doesn't load
>>>>>http://www.cf-mekong-4test.net/cfm/bb/photos/map_cv.jpg loads the image
!!
>>>>>
>>>>>can someone give me a hint about that, i'm pretty lost here :-(
>>>>>
>>>>>thanks,
>>>>>
>>>>>Marc
>>>>>
>>>>>---------------------------------------------------------------------
>>>>>To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>>>>>For additional commands, e-mail: users-help@cocoon.apache.org
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>        
>>>>>
>>>>---------------------------------------------------------------------
>>>>To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>>>>For additional commands, e-mail: users-help@cocoon.apache.org
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>      
>>>>
>>>---------------------------------------------------------------------
>>>To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>>>For additional commands, e-mail: users-help@cocoon.apache.org
>>>
>>>
>>>    
>>>
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>>For additional commands, e-mail: users-help@cocoon.apache.org
>>
>>
>>
>>
>>  
>>
> --------------------------------------------------------------------- 
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org For 
> additional commands, e-mail: users-help@cocoon.apache.org 



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message