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

Saving timestamp in message header #5

Open
yusenz opened this issue May 16, 2023 · 3 comments
Open

Saving timestamp in message header #5

yusenz opened this issue May 16, 2023 · 3 comments

Comments

@yusenz
Copy link

yusenz commented May 16, 2023

Just a small request, for latency measurement purposes in real time applications, can we have a timestamp in the header? Like, take a unix timestamp at creating c_obj for header and put it into a timestamp field in the header.
Also, would it be possible to take another timestamp after the message is sent to see how long it takes on the sending side to send the message and log it somewhere? I am assuming the sending on zeromq is efficient but it would be better to check it as well. Maybe we can store this timestamp and send it in the next message?

@anjaldoshi
Copy link
Collaborator

Hi Yusen,

I just pushed out a new release for the plugin (0.3.2) that adds the current unix timestamp in milliseconds to all message headers. If you're sending messages between machines, you'll need an independent way of determining the offset between the two system clocks.
I also fixed a bug that was causing the plugin to not bind to zmq sockets properly when reloading a signal chain.
The new version should be be available to download via Plugin Installer in a few minutes. Let me know if you have any other questions.

@yusenz
Copy link
Author

yusenz commented May 22, 2023

Thanks! I will test it soon.

@anjaldoshi
Copy link
Collaborator

anjaldoshi commented May 22, 2023

Cool! Fyi, the timestamp field is a part of the header along-side message_num and type for consistency across continuous, event and spike messages. 8f6d8b1.

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