intermediate change
This commit is contained in:
@ -1075,12 +1075,16 @@ func (t *http2Client) controller() {
|
|||||||
}
|
}
|
||||||
isPingSent := false
|
isPingSent := false
|
||||||
keepalivePing := &ping{data: [8]byte{}}
|
keepalivePing := &ping{data: [8]byte{}}
|
||||||
|
cchan := t.controlBuf.get()
|
||||||
|
wchan := nil
|
||||||
for {
|
for {
|
||||||
select {
|
select {
|
||||||
case i := <-t.controlBuf.get():
|
case i := <-cchan:
|
||||||
t.controlBuf.load()
|
t.controlBuf.load()
|
||||||
select {
|
wchan = t.writableChan
|
||||||
case <-t.writableChan:
|
cchan = nil
|
||||||
|
continue
|
||||||
|
case <-wchan:
|
||||||
switch i := i.(type) {
|
switch i := i.(type) {
|
||||||
case *windowUpdate:
|
case *windowUpdate:
|
||||||
t.framer.writeWindowUpdate(true, i.streamID, i.increment)
|
t.framer.writeWindowUpdate(true, i.streamID, i.increment)
|
||||||
@ -1100,11 +1104,10 @@ func (t *http2Client) controller() {
|
|||||||
default:
|
default:
|
||||||
grpclog.Printf("transport: http2Client.controller got unexpected item type %v\n", i)
|
grpclog.Printf("transport: http2Client.controller got unexpected item type %v\n", i)
|
||||||
}
|
}
|
||||||
t.writableChan <- 0
|
wchan <- 0
|
||||||
|
wchan = nil
|
||||||
|
cchan = t.controlBuf.get()
|
||||||
continue
|
continue
|
||||||
case <-t.shutdownChan:
|
|
||||||
return
|
|
||||||
}
|
|
||||||
case <-timer.C:
|
case <-timer.C:
|
||||||
t.mu.Lock()
|
t.mu.Lock()
|
||||||
ns := len(t.activeStreams)
|
ns := len(t.activeStreams)
|
||||||
|
Reference in New Issue
Block a user