Implement comprehensive WebSocket subscription stability fixes
- Resolved critical issues causing subscriptions to drop after 30-60 seconds due to unconsumed receiver channels. - Introduced per-subscription consumer goroutines to ensure continuous event delivery and prevent channel overflow. - Enhanced REQ parsing to handle both wrapped and unwrapped filter arrays, eliminating EOF errors. - Updated publisher logic to correctly send events to receiver channels, ensuring proper event delivery to subscribers. - Added extensive documentation and testing tools to verify subscription stability and performance. - Bumped version to v0.26.2 to reflect these significant improvements.
This commit is contained in:
@@ -142,8 +142,7 @@ func (l *Listener) HandleMessage(msg []byte, remote string) {
|
||||
if !strings.Contains(err.Error(), "context canceled") {
|
||||
log.E.F("%s message processing FAILED (type=%s): %v", remote, t, err)
|
||||
// Don't log message preview as it may contain binary data
|
||||
|
||||
// Send error notice to client (use generic message to avoid control chars in errors)
|
||||
// Send error notice to client (use generic message to avoid control chars in errors)
|
||||
noticeMsg := fmt.Sprintf("%s processing failed", t)
|
||||
if noticeErr := noticeenvelope.NewFrom(noticeMsg).Write(l); noticeErr != nil {
|
||||
log.E.F(
|
||||
|
||||
Reference in New Issue
Block a user