5 Replies Latest reply on Jan 9, 2009 8:25 PM by Nick Belaevski

    a4j:mediaOutput, multiple db-connections

    Max Laenzlinger Newbie

      Hello,

      Problem is my browser-session generates sometimes more than 1 db connection when i use (multiple?) a4j:mediaOutput, but not always. Could it be that this component makes a new thread(session)? Or is my code wrong? I prepare 2 logos as first elements on my pages as byteArray (sess.prepareLogos) before i call kind of getters to them (sess.getLogoLeft, sess.getLogoRight), so when getting the Logos i not go to the database.

      Thanks very much for ideas/thougts.

      <h:outputText value="#{sess.prepareLogos}"></h:outputText>
      <a4j:mediaOutput align="left" element="img" cacheable="false" session="true" createContent="${sess.getLogoLeft}" value="null" mimeType="image" id="wrwrwerw"/>
      <a4j:mediaOutput align="right" element="img" cacheable="false" session="true" createContent="${sess.getLogoRight}" value="null" mimeType="image" id="werwerr"/>