Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-12609

Consider bandwidth throttling in ReplicationSource.readAllEntriesToReplicateOrNextFile

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Incomplete
    • 0.98.8
    • None
    • Replication
    • None

    Description

      The push size in ReplicationSource.shipEdits is controlled by 'replicationQueueSizeCapacity' and 'replicationQueueNbCapacity'. When the push size is much bigger than throttler's bandwidth(replication throttler is enabled), ReplicationSource will have a outgoing bandwidth peak followed by a period of sleep controlled by the throttler. How about considering bandwidth throttling in ReplicationSource.readAllEntriesToReplicateOrNextFile? such as the following code:

             // Stop if too many entries or too big
            long bandwidth = this.conf.getLong("replication.source.per.peer.node.bandwidth", 0);
            if ((bandwidth > 0 && currentSize > bandwidth) ||  // ==> also consider bandwidth throttling
                currentSize >= this.replicationQueueSizeCapacity ||
                 entries.size() >= this.replicationQueueNbCapacity) {
               break;
             }
      

      Then, ReplicationSource will have more steady outgoing bandwidth.

      Attachments

        Activity

          People

            Unassigned Unassigned
            cuijianwei Jianwei Cui
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: