-
Notifications
You must be signed in to change notification settings - Fork 971
[C/Java] Align event logging between Java and C #1091
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ring name resolution.
…e event log string using the same names and/or values.
…mage_entry_delete to aeron_receive_channel_endpoint_entry_delete, because it is where endpoint is disconnected thus loosing channel URI info.
…ommands and pass channel_length before channel.
…n from the method.
…laring it each time.
…ailable on Windows.
mjpt777
reviewed
Nov 25, 2020
mjpt777
reviewed
Nov 25, 2020
mjpt777
reviewed
Nov 25, 2020
mjpt777
reviewed
Nov 25, 2020
mjpt777
reviewed
Nov 25, 2020
mjpt777
reviewed
Nov 25, 2020
mjpt777
reviewed
Nov 25, 2020
mjpt777
reviewed
Nov 25, 2020
mjpt777
reviewed
Nov 25, 2020
mjpt777
reviewed
Nov 25, 2020
|
In general, looks good. |
|
@mjpt777 All found issues were fixed. |
# Conflicts: # aeron-driver/src/main/c/agent/aeron_driver_agent.c # aeron-driver/src/test/c/agent/aeron_driver_agent_test.cpp
mjpt777
reviewed
Nov 25, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes in this PR:
Align event initialization between C and Java code, i.e. add support using special words like
all,adminas well as event names or numerical codes.For example using the following comma-separated list of events
CMD_IN_REMOVE_COUNTER,33,NAME_RESOLUTION_NEIGHBOR_ADDED,CMD_OUT_ERROR,FRAME_OUTto setAERON_EVENT_LOGoraeron.event.logproperty will enableCMD_IN_REMOVE_COUNTER,CMD_OUT_EXCLUSIVE_PUBLICATION_READY,FRAME_OUT,NAME_RESOLUTION_NEIGHBOR_ADDEDandCMD_OUT_ERRORevents.Support legacy mask-based logging event initialization for the C driver, i.e.:
0xffff- the same asall(enables all events).0x1- enables allCMD_INevents (e.g.CMD_IN_ADD_PUBLICATION,CMD_IN_REMOVE_SUBSCRIPTIONetc.).0x2- enables allCMD_OUTevents (e.g.CMD_OUT_PUBLICATION_READY,CMD_OUT_ERRORetc.).0x4- enablesFRAME_INevent.0x8,0x10- enablesFRAME_OUTevent.0x80- enablesUNTETHERED_SUBSCRIPTION_STATE_CHANGEevent.0x8FenablesFRAME_IN,FRAME_OUTandUNTETHERED_SUBSCRIPTION_STATE_CHANGEevents.Enable individual logging of the
CMD_IN/CMD_OUTevents in the C driver. Despite using a single hook for the in/out events the logging is only done if a particular event is enabled, i.e. a runtimeO(1)check if performed and if it fails logging call is a no op.Add logging for the name resolution neighbor added/removed to the Java driver.
Add logging for the IpcPublication cleanup to the Java driver.
Add all missing events to the C driver, i.e.:
REMOVE_PUBLICATION_CLEANUPREMOVE_SUBSCRIPTION_CLEANUPREMOVE_IMAGE_CLEANUPSEND_CHANNEL_CREATIONRECEIVE_CHANNEL_CREATIONSEND_CHANNEL_CLOSERECEIVE_CHANNEL_CLOSENAME_RESOLUTION_NEIGHBOR_ADDEDNAME_RESOLUTION_NEIGHBOR_REMOVEDFormat logging header the same way as in Java and use nano clock in the C driver.
Remove obsolete events from the C driver agent:
AERON_RAW_LOG_MAP_OP(0x20)AERON_RAW_LOG_CLOSE_OP(0x40)AERON_DYNAMIC_DISSECTOR_EVENT(0x100)AERON_RAW_LOG_FREE_OP(0x200)Fixes #1072