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

RSRpcService.scan() throws an OutOfOrderScannerNext if the scan has a retriable failure

    XMLWordPrintableJSON

Details

    Description

      while fixing HBASE-13651 I noticed that if we have a failure inside the RSRpcService.scan(), when the request has a hasNextCallSeq() the nextCallSeq is incremented and not rolledback, which means that the client retry will send a request with a nextCallSeq not up to date, which result in an OutOfOrderScannerNextException.

      if (rows > 0) {
        if (request.hasNextCallSeq()) {
          if (request.getNextCallSeq() != rsh.nextCallSeq) {
            throw new OutOfOrderScannerNextException(...)
          }
          // Increment the nextCallSeq value which is the next expected from client.
          rsh.nextCallSeq++;
        }
      }
      try {
        ...scan code...
      }
      

      after the scanner heartbeat patches HBASE-13090, we seems to be able to recover from that OutOfOrder exception, but the error show up anyway.

      After a discussion with saint.ack@gmail.com we ended up saying that decrementing the callSeq on exception seems to be fine. but we had the open question about having that nextCallSeq to be atomic, if that was supposed to prevent concurrent requests with the same id. any thoughts?

      Attachments

        1. HBASE-13662-v1.patch
          10 kB
          Matteo Bertozzi
        2. HBASE-13662-v0.patch
          8 kB
          Matteo Bertozzi

        Issue Links

          Activity

            People

              mbertozzi Matteo Bertozzi
              mbertozzi Matteo Bertozzi
              Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: