-
Bug
-
Resolution: Fixed
-
Major
-
None
-
None
-
None
-
-
Yes
-
Empty show more show less
-
RC 1, RC 2
Cause and proposed fix
When a request is interrupted (by the browser), containers typically throw a subclass of IOException (Tomcat throws a org.apache.catalina.connector.ClientAbortException, Jetty throws an org.mortbay.jetty.EofException, ...). We already treat this in a few places: (look for catch (IOException) snippet)
- info.magnolia.rendering.engine.RenderingFilter#doFilter
- info.magnolia.rendering.engine.RenderingFilter#handleResourceRequest
- info.magnolia.cms.servlets.ClasspathSpool#streamSingleFile
We could do the exact same thing in CacheFilter. We already catch all exceptions; checking if it's an IO and swallowing it there isn't perfect or ideal, but at least it'll be consistent with the rest. (In this specific case we need to make we still unlock the cache if needed).
After discussions, we decided to do this in UseCache instead, thus avoiding accidentally swallowing IOExceptions coming from further down the chain.
Proposed improvements
Centralize and avoid code duplication; would allow for smarter/more complete handling of this. See MAGNOLIA-5113.
Symptoms
bundle (integration tests) occasionally fail because of the following error:
[INFO] [talledLocalContainer] 2013-06-13 06:31:55,647 ERROR info.magnolia.module.cache.filter.CacheFilter : A request started to cache but failed with an exception (IOException: Broken pipe). [url=http://localhost:8088/magnoliaTestPublic/.resources/defaultLoginForm/css/fonts/DINWebPro.woff], [key=DefaultCacheKey{uri='/.resources/defaultLoginForm/css/fonts/DINWebPro.woff', serverName='localhost', locale='en', channel='desktop', params={}', secure='false'}]
[WARNING] [talledLocalContainer] 2013-06-13 06:31:55.676:WARN::/magnoliaTestPublic/.resources/defaultLoginForm/css/fonts/DINWebPro.woff
[WARNING] [talledLocalContainer] java.lang.RuntimeException: org.mortbay.jetty.EofException
This sometimes also happens locally now...
- duplicates
-
MAGNOLIA-3566 Cache filter should ignore ClientAbortException
- Closed
- is related to
-
MAGNOLIA-5113 Generalize/centralize treatment of broken pipe / ClientAbortException / etc
- Closed
- links to