Skip to content

Conversation

@ZhengXinCN
Copy link
Collaborator

log gateleen key event consumer counter

@mcweba mcweba requested a review from hiddenalpha November 10, 2025 12:52
@mcweba
Copy link
Collaborator

mcweba commented Nov 10, 2025

Could you please create an issue describing the intention of this feature? I did not yet fully review the changes but I don't like the way the now every eventBus.publish is forced to be a trackable publish causing also some overhead while processing. I would suggest to keep the default behaviour as it was before and provide a way to overwrite it when wanted.

@ZhengXinCN ZhengXinCN requested a review from mcweba November 19, 2025 06:55
@ZhengXinCN
Copy link
Collaborator Author

@mcweba I added a switch which can set by eventbus, default disabled.

@ZhengXinCN ZhengXinCN requested a review from Kusig November 19, 2025 06:58
RequestLogger.logRequest(vertx.eventBus(), request, status, buffer);
}
vertx.eventBus().publish(SAVE_LISTENER_ADDRESS, listenerStorageUri);
trackableEventPublish.publish(SAVE_LISTENER_ADDRESS, listenerStorageUri);
Copy link
Member

@hiddenalpha hiddenalpha Nov 21, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume it is by intent to DUPLICATE that publication here? All other places do a REPLACE of the call. Except this one, which now does TWO calls.

     vertx.eventBus().publish(SAVE_LISTENER_ADDRESS, listenerStorageUri);
+    trackableEventPublish.publish(SAVE_LISTENER_ADDRESS, listenerStorageUri);

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, I removed it already, but don't know it doesn't marked it as outdated

if (body.containsKey(KEY_REPLY_ADDRESS)) {
String replyAddr = body.getString(KEY_REPLY_ADDRESS);
vertx.eventBus().send(replyAddr, null);
handler.handle(body.getString(KEY_DATA));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume it is by intent to call
vertx.eventBus().send(replyAddr, null)
only if trackerEnabled == true?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, there 2 things need to check to use reply:

  1. function enabled
  2. there is a reply address attached.

because when trackerEnabled == true, may still received some events which published by other when tracker is not enabled yet

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

Successfully merging this pull request may close these issues.

4 participants