apache / apache/eventmesh

[Question] After runtime crashes and reconnects, TCP and GRPC will resend subscription information, but HTTP does not

Open
#4,592 5 comments 0 reactions 0 assignees View on GitHub
question Stale
Dominant language
Java
Stars
1.8k
Forks
658
Avg merge
11h 29m
Merged PRs (30d)
52

Description

### Search before asking

- [X] I had searched in the [issues](https://github.com/apache/eventmesh/issues?q=is%3Aissue) and found no similar issues.

### Question

Both tcp and grpc will resend the subscription information after the runtime is disconnected. Why doesn't http resend the subscription information?And after testing, it was indeed found that when keeping sub started and restarting the runtime, sending events through pub again, only grpc and tcp sub can be consumed again, while http
sub cannot consume events.

---
tcp和grpc都会在runtime断开连接后重新发送订阅信息,为什么http不重新发送订阅信息?并且经过测试也确实发现,当保持sub启动,而重启runtime后,再次通过pub发送事件,仅有grpc和tcp的sub可以再次消费,而http sub无法消费事件。

![image](https://github.com/apache/eventmesh/assets/122422744/8994b01b-c48d-456e-9147-c1efeaca46ae)
(org.apache.eventmesh.client.grpc.consumer.EventMeshGrpcConsumer#heartBeat)

![image](https://github.com/apache/eventmesh/assets/122422744/babf38e9-086a-46e9-babb-ca8c3b83750b)
(org.apache.eventmesh.client.http.consumer.EventMeshHttpConsumer#heartBeat)

![image](https://github.com/apache/eventmesh/assets/122422744/35e48f16-7047-4cab-9cd8-73cc59f18f7d)
(org.apache.eventmesh.client.tcp.impl.cloudevent.CloudEventTCPSubClient#reconnect)
(org.apache.eventmesh.client.tcp.impl.eventmeshmessage.EventMeshMessageTCPSubClient#reconnect)

Contributor guide

Open the contributing guide

Research direction

Compare org.apache.eventmesh.client.http.consumer.EventMeshHttpConsumer#heartBeat with org.apache.eventmesh.client.grpc.consumer.EventMeshGrpcConsumer#heartBeat and the TCP client reconnect methods named in the issue. Restart the runtime while a subscription remains active, publish an event again, and verify that the HTTP subscriber receives it as TCP and gRPC subscribers do.

Written by the indexing model from the issue text.

Assessment

Tech stack
grpc, java
Domain
distributed-systems, networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.