code: function numberOutstandingRestRequests(category) {
      if (category) {
          return _.filter(restXhrPool, function (xhr) {
              return xhr.girder && xhr.girder[category];
          }).length;
      }
      return _.size(restXhrPool);
  }
docs: /* Get the number of outstanding rest requests.
  :param category: if specified, only count those requests that have
  xhr.girder[category] set to a truthy value.
  :returns: the number of outstanding requests.