3 Replies Latest reply on Apr 22, 2007 7:46 PM by shane.bryzak

    Conversation Id in custom servlet

    dustismo

      Hello,
      I have a custom servlet that serves custom generated graphs (many of them per page). I notice that every time there is a request to the servlet a new conversation is created, even though I am passing the conversationId to the servlet.

      My page code looks like:

      <h:graphicImage value="/media/wggraph?gsMan=wgGraphs&amp;ugid=#{graph.id}&amp;conversationId=#{conversation.id}" />
      


      Am I doing something wrong? Or will there always be a new conversation created everytime a servlet is accessed?

      thanks,
      Dustin

        • 1. Re: Conversation Id in custom servlet
          shane.bryzak

          Are you using the ContextFilter? And is your conversation-id-parameter really "conversationId", or is it something else? (e.g. "cid")

          • 2. Re: Conversation Id in custom servlet
            dustismo

            Yes, I am using the context filter (I am able to access seam components in the servlet). I believe that my conversation id is 'cid' but I tried that as well with the same results.

            The conversations do not persist beyond the servlet access (i.e. there are not 20 extra conversations listed on the debug.seam page). Just that the next conversation id started is +20 of the previous conversation. Perhaps this is expected? Or is there someway I can find out why the cid is not getting picked up by the context filter?

            thanks,
            Dustin

            • 3. Re: Conversation Id in custom servlet
              shane.bryzak

              You could set a breakpoint in Manager.restoreConversation() and see if your conversation ID is in fact a) in the parameter list and b) has a correctly named parameter (should be equal to whatever Manager.conversationIdParameter is set to).