Uploaded image for project: 'Thrift'
  1. Thrift
  2. THRIFT-2390

no close event when connection lost

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.9.2
    • Component/s: Node.js - Library
    • Labels:
      None

      Description

      thrift nodejs lib (master)

      There is no indication that connection lost if reconnect is not setup.
      (There is no "close" event from connection object or RPC error callback)

      File: connection.js:167

      Connection.prototype.connection_gone = function () {
      var self = this;

      // If a retry is already in progress, just let that happen
      if (this.retry_timer || !this.max_attempts)

      { return; }


      Should be changed to

      Connection.prototype.connection_gone = function () {
      var self = this;

      // If a retry is already in progress, just let that happen
      if (this.retry_timer) { return; }

      if(!this.max_attempts)

      { self.emit("close"); return; }

        Attachments

          Activity

            People

            • Assignee:
              jfarrell Jake Farrell
              Reporter:
              gruzovator alexey
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: