gz-transport icon indicating copy to clipboard operation
gz-transport copied to clipboard

Throttle based on custom clock

Open osrf-migration opened this issue 4 years ago • 0 comments

Original report (archived issue) by Louise Poubel (Bitbucket: chapulina, GitHub: chapulina).


Summary

It's currently possible to throttle a publisher's update rate by setting the SetMsgsPerSec option. But the implementation is currently always using wall time.

Motivation

It would be useful to be able to throttle based on custom clocks, so a simulator could throttle based on the current simulation time, for example.

Describe alternatives you've considered

Throttling from outside Ignition Transport, preventing the call to Publish.

Additional context

The Clock class is being used to timestamp logs with custom time. The same class could be used for throttling.

osrf-migration avatar Aug 02 '19 21:08 osrf-migration