1 Reply Latest reply on Aug 4, 2010 9:40 AM by sean.tozer

    seam has a bad documentation point(or is it me?)

    deanhiller2000

      On the seam docs, there is code for caching jpg, css, etc. which is only set to 24 hours.  Shouldn't this really be set to 1 year or infinity basically instead along with a policy that all resources are in a url of


      http://<yoururl>/res<versionOfRelease>/css/*.css


      http://<yoururl>/res<versionOfRelease>/jpg/*.jpg


      I see this as solving two things very nicely


      1. Until I upgrade the product, they are not seeing a cold start once a day from their cache being evicted or once a week, etc.


      2. When I do upgrade the product, I have no worries about their pages pulling the old css files and complaining the new release did not fix some bug when we did fix it but it was getting it from their cache.


      Why does the seam docs have only 24 hours here...(shouldn't it be  1 year which I think is the max for 1.1 http).


           <web:cache-control-filter name="imageCacheControlFilter"
                                regex-url-pattern=".*(\.gif|\.png|\.jpg|\.jpeg)"
                                value="max-age=86400"/>
      



        • 1. Re: seam has a bad documentation point(or is it me?)
          sean.tozer

          I don't really see that as a bad documentation point, it's just a matter of policy. Offhand, I can think of very few sites that maintain a separate release version number in the URL. What if someone bookmarked or hotlinked something under there? I realize these are internal images for the site, but it's still just something that's not usually done.


          That is, the way Seam is set up by default seems to be the more usual, less prone to unexpected behaviours method. I certainly wouldn't advocate changing the default to require using the /res<version>/ directory layout. That'd just be one more potential pitfall for people new to the framework. As it is, it'll work fine without that particular layout, and if the designer wants to go with a system as you're suggesting, they're certainly free to.


          In summary, I think it's just you. :-)