coder / coder/websocket

Feature Request: Enable half-closed with CloseWrite

Abierto
#507 6 comentarios 0 reacciones 0 asignados Ver en GitHub
enhancement
Lenguaje dominante
Go
Estrellas
5.5k
Forks
372
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

I'm writing a TCP reverse proxy over Websocket and I'm trying to use this library.

However, it provides no way to close the write side only. That's needed to indicate end of stream (EOF), which gets mapped to a FIN on the TCP connection to the origin.

Looking at the code, I see that Close() runs the full handhsake. Perhaps CloseWrite could just send the close message with the normal status, but not wait for the response. And the code should not close the connection when receiving the close message. It should only do that on the explicit Close() or CloseWrite() call by the application code.

Guía de contribución

No hay ninguna guía de contribución indexada para este repositorio

Línea de trabajo

Start by tracing the existing Close() handshake and the code that handles received close messages. Define how an explicit CloseWrite() should signal the write-side EOF without waiting for a response or closing the connection, while preserving full closure through Close(); verify the behavior with focused WebSocket and TCP-proxy tests.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
go
Área
networking
Tipo de issue
Nueva funcionalidad
Dificultad
4/5
Tiempo estimado
3-5 días
Estado de actividad
Estancado
Claridad
Bastante claro
Aptitud para principiantes
42/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.