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

PHP TSocket Write Timeout

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Duplicate
    • 0.2
    • 0.7
    • PHP - Library
    • None
    • Fedora 8, 64bit, php 5.2.4

    Description

      TException: TSocket: Could not write 48 bytes localhost:9160

      The error comes out often from TSocket#write($buf), row 279 at line 292:

      while (strlen($buf) > 0) {
      $got = @fwrite($this->handle_, $buf);
      if ($got === 0 || $got === FALSE) {
      $md = stream_get_meta_data($this->handle_);
      if ($md['timed_out'])

      { throw new TException('TSocket: timed out writing '.strlen($buf).' bytes from '. $this->host_.':'.$this->port_); }

      else

      { // HERE throw new TException('TSocket: Could not write '.strlen($buf).' bytes '. $this->host_.':'.$this->port_); }

      }
      $buf = substr($buf, $got);
      }

      I found a similar issue in reading TSocket, described here: https://issues.apache.org/jira/browse/THRIFT-347

      Attachments

        Activity

          People

            nicktelford Nicholas Telford
            loretoparisi Loreto Parisi
            Votes:
            2 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: