1 Reply Latest reply on Sep 1, 2011 4:58 PM by cbrock

    sendRepeatingWith

    eman123

      what is the benifit of doing this:

      .sendRepeatingWith(dispatcher, TimeUnit.MILLISECONDS, 2000);

       

      vs having my appliation poll my web server every 2 seconds?

       

      it seems that when I use .sendRepeatingWith it keeps a connection open and every 2 seconds it closes and reconnects.  it seems I would get the same performance in GWT using a timer and every 2 seconds make an RPC call, right?  or am I missing something about the way this works?

       

      Thanks.

        • 1. Re: sendRepeatingWith
          cbrock

          The advantage is the timer will be auto-killed if the session dies or the client disconnects, so you don't have to worry about self-managing that.