refresh_(retryAttempt = 0) {
    // Create a unique object identity for this request.
    const marker = {};
    this.lastRefreshToken_ = marker;
    /**
     * @param{?Object|undefined} result Object obtained from getProfiles.
     * @param{string=} error Error message returned on failure.
     */
    const handleResponse = (result, error) => {
      if (marker != this.lastRefreshToken_) return;  // Superseded.
      if (error && typeof retryAttempt === 'number' &&
          retryAttempt < this.MAX_RETRY_COUNT_) {
        goog.Timer.callOnce(
            goog.bind(this.refresh_, this, retryAttempt + 1),
            2 * ee.data.Profiler.DELAY_BEFORE_REFRESH_);
        return;
      }
      this.profileError_ = error || null;
      this.profileData_ =
          error ? ee.data.Profiler.getEmptyProfile_(this.format_) : result;
      this.lastRefreshToken_ = null;
      this.dispatchEvent(ee.data.Profiler.EventType.STATE_CHANGED);
      this.dispatchEvent(ee.data.Profiler.EventType.DATA_CHANGED);
    };

    const ids = goog.object.getKeys(this.profileIds_);
    if (ids.length === 0) {
      // Shortcut: no input, so no output.
      handleResponse(
          ee.data.Profiler.getEmptyProfile_(this.format_), undefined);
    } else {
      const getProfilesFn = this.showInternal_ ? 'Profile.getProfilesInternal' :
                                               'Profile.getProfiles';
      const profileValue = ee.ApiFunction._apply(getProfilesFn, {
        'ids': ids,
        'format': this.format_.toString(),
      });
      profileValue.getInfo(handleResponse);
      this.dispatchEvent(ee.data.Profiler.EventType.STATE_CHANGED);
    }
  }
Fetches a new combined profile asynchronously and fires events when done.
@param {number=} retryAttempt current refresh attempt, if retryAttempt is
less than MAX_RETRY_COUNT_ the profile refresh is retried.
@private