docs: function () {
          var data = this._conn._data;
  
          // if no requests are in progress, poll
          if (this._conn.authenticated && this._requests.length === 0 &&
              data.length === 0 && !this._conn.disconnecting) {
              Strophe.info("no requests during idle cycle, sending " +
                           "blank request");
              data.push(null);
          }
  
          if (this._conn.paused) {
              return;
          }
  
          if (this._requests.length < 2 && data.length > 0) {
              var body = this._buildBody();
              for (var i = 0; i < data.length; i++) {
                  if (data[i] !== null) {
                      if (data[i] === "restart") {
                          body.attrs({
                              to: this._conn.domain,
                              "xml:lang": "en",
                              "xmpp:restart": "true",
                              "xmlns:xmpp": Strophe.NS.BOSH
                          });
                      } else {
                          body.cnode(data[i]).up();
                      }
                  }
              }
              delete this._conn._data;
              this._conn._data = [];
              this._requests.push(
                  new Strophe.Request(body.tree(),
                                      this._onRequestStateChange.bind(
                                          this, this._conn._dataRecv.bind(this._conn)),
                                      body.tree().getAttribute("rid")));
              this._throttledRequestHandler();
          }
  
          if (this._requests.length > 0) {
              var time_elapsed = this._requests[0].age();
              if (this._requests[0].dead !== null) {
                  if (this._requests[0].timeDead() >
                      Math.floor(Strophe.SECONDARY_TIMEOUT * this.wait)) {
                      this._throttledRequestHandler();
                  }
              }
  
              if (time_elapsed > Math.floor(Strophe.TIMEOUT * this.wait)) {
                  Strophe.warn("Request " +
                               this._requests[0].id +
                               " timed out, over " + Math.floor(Strophe.TIMEOUT * this.wait) +
                               " seconds since last activity");
                  this._throttledRequestHandler();
              }
          }
      }