Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Java] [Joynr 1.19.8] Restart consumer application and then it can't receive broadcast information #91

Open
lftxhl opened this issue Apr 29, 2022 · 2 comments

Comments

@lftxhl
Copy link

lftxhl commented Apr 29, 2022

Hi,
operate as follow steps:
1.start a provider service and a consumer service
2.consumer service subscribe to provider's broadcast
3.restart consumer service
4.use provider service publish a broadcast information then consumer service will print the following log

2022-04-29 11:05:40,446 [DEBUG] HivemqMqttClient: (clientHash=5b69d40d, GBID=gwmsoagbid1, bidirectional): Received publication: topic: Hw7dWStkSjWXrc53EbAIRg/systemMessage, size: 528, qos: AT_LEAST_ONCE, retain: false, expiryInterval: 120. 2022-04-29 11:05:40,447 [DEBUG] MqttMessagingSkeleton: <<< INCOMING FROM gwmsoagbid1 <<< messageId: SUjiE8_-TZOMkwJiMBByZg, type: m, sender: Hw7dWStkSjWXrc53EbAIRg, recipient: Hw7dWStkSjWXrc53EbAIRg/systemMessage, expiryDate: 1651201660441, size: 528 2022-04-29 11:05:40,448 [ERROR] CcMessageRouter: ERROR SENDING: aborting send. Error: Failed to route multicast publication: No recipient found for given message: messageId: SUjiE8_-TZOMkwJiMBByZg, type: m, sender: Hw7dWStkSjWXrc53EbAIRg, recipient: Hw7dWStkSjWXrc53EbAIRg/systemMessage, expiryDate: 1651201660441, size: 528

the consumer's receiverid is not change,so I think it should receive the broadcast information rather than print error log

@lftxhl
Copy link
Author

lftxhl commented May 17, 2022

anyone here?

@ostkamp
Copy link
Contributor

ostkamp commented Sep 22, 2022

The consumer service proxy must subscribe again after restart in order to be able to get and process publications from provider.
If the consumer services runtime is using same MQTT clientId as before after restart, it´s runtime might get publications sent by the provider which where queued at MQTT broker or sent later even if the consumer has not subscribed to broadcast after restart. This can be prevented by using cleanSession=true. In this case MQTT subscription which got established during first run of consumer service to implement the non-filtered joynr broadcast subscription as Multicast subscription via MQTT will get deleted. Of course using another not yet used clientId will also establish a fresh connection with no active subscriptions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants