Skip to content

Commit ef10a56

Browse files
menghanlejona86
authored andcommitted
Revert "To adhere with protocol the server should send RST_STREAM on observing timeout on a strea, (#1130)"
This reverts commit 6d0e6b0.
1 parent 2d949be commit ef10a56

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

transport/http2_client.go

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -560,12 +560,9 @@ func (t *http2Client) CloseStream(s *Stream, err error) {
560560
}
561561
s.state = streamDone
562562
s.mu.Unlock()
563-
if se, ok := err.(StreamError); ok {
563+
if _, ok := err.(StreamError); ok {
564564
rstStream = true
565565
rstError = http2.ErrCodeCancel
566-
if se.Code == codes.DeadlineExceeded {
567-
rstError = http2.ErrCodeInternal
568-
}
569566
}
570567
}
571568

transport/http2_server.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -741,9 +741,6 @@ func (t *http2Server) WriteStatus(s *Stream, st *status.Status) error {
741741
}
742742
t.stats.HandleRPC(s.Context(), outTrailer)
743743
}
744-
if statusCode == codes.DeadlineExceeded {
745-
t.controlBuf.put(&resetStream{s.id, http2.ErrCodeInternal})
746-
}
747744
t.closeStream(s)
748745
t.writableChan <- 0
749746
return nil

0 commit comments

Comments
 (0)