3 Replies Latest reply on Sep 25, 2011 11:10 AM by Ilya Shaikovsky

    a4j:Queue , grouping requests together

    Adi Katz Novice

      Hello,

       

      I would like my a4j:Queue to submit all requests in the Queue in 1 go instead of seperate requests.

      Very much like it is shown in the online demo:  When typing quickly in the input box a request will be sent

      only once, after requestDelay time has passed.

      In my scenario users are tabbing quickly between input fields changing values and having to wait for the reponse

      after each update is not ideal...

      The application is a kind of online spreadsheet , so all cells must be 'ajaxed'. yet I am trying to avoid the wait time after each user input and achieve more of a "background" update behaviour.

      Any suggestions will be welocomed !

       

      Thanks

      Adi

       

      p.s.

       

      Using RichFaces 3.3.3

        • 1. Re: a4j:Queue , grouping requests together
          Ilya Shaikovsky Master

          use similarityGroupingId on your ajax controls and set it to the same value.

          • 2. Re: a4j:Queue , grouping requests together
            Adi Katz Novice

            Hi Ilya,

             

            Thanks for the answer. I am however facing another issue now : Seems grouping does not work if the components have ajaxSingle set to true.

            Looking at the raw http request with firebug reveals that:

             

            AJAX:EVENTS_COUNT 2

            ajaxSingle input1

             

            Although 2 requests are grouped here the ajaxSingle parameter is sent only for one of the requests and the server respond accordingly.

             

            Can you comment on that ?

             

            Thanks

            Adi

            • 3. Re: a4j:Queue , grouping requests together
              Ilya Shaikovsky Master

              Now it's more clear with the use-case detials. And unfortunatelly not sure that we trying to go in right direction there. Queue treats the request marked with that attribute as completelly "similar". It just replaces one request with another. So it will not works as you expects with ajaxSingle as second field will not be processed. What about to try without ajaxSingle? With all the requests queued and marked similar it should add not much additional processing..?

              1 of 1 people found this helpful