0 Replies Latest reply on May 10, 2007 9:19 AM by Renzo Tomaselli

    missing css from cache

    Renzo Tomaselli Novice

      Hi, while investigating about some random failures in rendering ModalPanel from RichFaces, I came up to the point where it seems that ajax4jsf fails to place the involved css into its cache. The final result on client side is:

      <link href="/AxxBrowser/a4j.res//org/richfaces/renderkit/html/css/modalPanel.xcss/DATA/eAFbJaehBAADeAET.faces" type="text/css" rel="stylesheet">
      1
      </link>
      


      In method org.ajax4jsf.framework.resource.TemplateCSSRenderer.send() a call to responseWriter.close() is performed.
      This is presumed to end up in PrinterWriter.close(), as managed by CacheContent class. This method in turn should set filledOutputWriter = true.
      Unfortunately, the Trinidad implementation of HtmlResponseWriter does not call PrinterWriter.close() within its own close method. This leaves the CacheContent obj with filledOutputWriter = false, and next resource rendering request will return nothing.
      While I feel that this is a Trinidad bug, nevertheless placing just
      context.getWriter().close() after line #82 in file TemplateCSSRenderer should solve this issue.
      All of this refers to snapshot ajax4jsf-1.1.1-20070508.013219-82.jar.