<!-- If you need to report a security issue please visit https://github.com/apache/dubbo/security/policy -->

- [x] I have searched the [issues](https://github.com/apache/dubbo/issues) of this repository and believe that this is not a duplicate.

### Environment

* Dubbo version: 3.0.5-SNAPSHOT

### Steps to reproduce this issue

1. Start provider and consumer use `triple` protocol.
2. Consumer invoke timeout interface.
3. Provider throw `ClosedChannelException`
```
java.nio.channels.ClosedChannelException
	at io.netty.handler.codec.http2.AbstractHttp2StreamChannel$Http2ChannelUnsafe.write(AbstractHttp2StreamChannel.java:916)
	at io.netty.channel.DefaultChannelPipeline$HeadContext.write(DefaultChannelPipeline.java:1367)
	at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:717)
	at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:709)
	at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:792)
	at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:702)
	at io.netty.channel.DefaultChannelPipeline.write(DefaultChannelPipeline.java:1015)
	at io.netty.handler.codec.http2.AbstractHttp2StreamChannel.write(AbstractHttp2StreamChannel.java:480)
	at org.apache.dubbo.rpc.protocol.tri.command.QueuedCommand$AbstractQueuedCommand.run(QueuedCommand.java:56)
	at org.apache.dubbo.rpc.protocol.tri.WriteQueue.flush(WriteQueue.java:67)
	at io.netty.util.concurrent.AbstractEventExecutor.safeExecute$$$capture(AbstractEventExecutor.java:164)
	at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java)
	at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:472)
	at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:500)
	at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989)
	at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
	at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
	at java.lang.Thread.run(Thread.java:748)
[WARN][2021-12-22 15:40:12.099][NettyServerWorker-3-1][org.apache.dubbo.rpc.protocol.tri.ServerOutboundTransportObserver.lambda$onMetadata$0(ServerOutboundTransportObserver.java:42)ogger{50}]  [DUBBO] send header error endStream=true, dubbo version: 3.0.5-SNAPSHOT, current host: 10.128.49.130
```
4. When invoke timeout client will close channel.
https://github.com/apache/dubbo/blob/0765b612cb89fa22a40c3043e955552c8e941160/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/TripleClientRequestHandler.java#L57-L58

Pls. provide [GitHub address] to reproduce this issue.

### Expected Behavior

<!-- What do you expect from the above steps？-->

### Actual Behavior

<!-- What actually happens? -->

If there is an exception, please attach the exception trace:

```
Just put your stack trace here!
```

new ServiceMetadata(), null);
        url = url.setServiceModel(consumerModel);
        invoker = Mockito.mock(Invoker.class);
        Mockito.when(invoker.getUrl()).thenReturn(url);
        connection = Mockito.mock(Connection.class);
        writeMethodCalledTimes.set(0);
    }
    @Test
    public void testNewClientStream() throws Exception {
        Method echoMethod = IGreeter.class.getDeclaredMethod("echo", String.class);
        RpcInvocation rpcInvocation = new RpcInvocation(consumerModel, echoMethod, IGreeter.class.getName(), url.getProtocolServiceKey(), new Object[]{"ECHO"});
        rpcInvocation.setInvoker(invoker);
        Request request = new Request(1);
        request.setData(rpcInvocation);
        
        AbstractClientStream stream = AbstractClientStream.newClientStream(request, connection);
        Assertions.assertTrue(stream instanceof UnaryClientStream);
        UnaryClientStream unaryClientStream = (UnaryClientStream) stream;
        Assertions.assertEquals(unaryClientStream.getConnection(), connection);
        Assertions.assertEquals(unaryClientStream.getConsumerModel(), consumerModel);
        Assertions.assertEquals(unaryClientStream.getMethodName(), echoMethod.getName());
        Assertions.assertEquals(unaryClientStream.getUrl(), url);
        Assertions.assertEquals(unaryClientStream.getRequestId(), request.getId());
        Assertions.assertEquals(unaryClientStream.getRpcInvocation(), rpcInvocation);
        Assertions.assertEquals(unaryClientStream.getCompressor(), Compressor.NONE);
        Assertions.assertEquals(unaryClientStream.getDeCompressor(), Compressor.NONE);
        Assertions.assertEquals(stream.getScheme(), HTTP_SCHEME);
        Assertions.assertEquals(stream.getAcceptEncoding(), "gzip");
        Assertions.assertFalse(stream.getCancellationContext().getListeners().isEmpty());
        Assertions.assertTrue(stream.getMultipleSerialization() instanceof DefaultMultipleSerialization);