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

Publish 10 world stats msgs/sec instead of 5 #1163

Merged
merged 2 commits into from
Nov 9, 2021

Conversation

adlarkin
Copy link
Contributor

@adlarkin adlarkin commented Nov 4, 2021

Signed-off-by: Ashton Larkin [email protected]

Addresses #1109 (comment)

Summary

The changes made in #1109 and gazebosim/gz-gui#306 result in the GUI listening to the world stats topic to receive play/pause confirmations from the server. The publisher of this topic is currently publishing 5 msgs/second, but I think it would be good to publish at a higher rate to decrease response times between a GUI play/pause button press and server confirmation.

Test it

Use these changes with #1109 and try pressing play/pause/step in the GUI. The GUI response times should be a little faster now.

Checklist

  • Signed all commits for DCO
  • Added tests
  • Added example and/or tutorial
  • Updated documentation (as needed)
  • Updated migration guide (as needed)
  • codecheck passed (See contributing)
  • All tests passed (See test coverage)
  • While waiting for a review on your PR, please help review another open pull request to support the maintainers

Note to maintainers: Remember to use Squash-Merge

@adlarkin adlarkin requested a review from nkoenig November 4, 2021 16:59
@adlarkin adlarkin requested a review from chapulina as a code owner November 4, 2021 16:59
@github-actions github-actions bot added 🌱 garden Ignition Garden 🏯 fortress Ignition Fortress labels Nov 4, 2021
Copy link
Contributor

@chapulina chapulina left a comment

Choose a reason for hiding this comment

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

I'm afraid we may be tweaking this hardcoded value often. We could consider exposing this as an option on ServerConfig, and optionally as a command line option, but that may be overkill. Defaulting to something that makes the GUI usable makes sense to me.

@adlarkin
Copy link
Contributor Author

adlarkin commented Nov 4, 2021

I'm afraid we may be tweaking this hardcoded value often. We could consider exposing this as an option on ServerConfig, and optionally as a command line option, but that may be overkill. Defaulting to something that makes the GUI usable makes sense to me.

It would be nice to remove hardcoded values whenever possible. We can make this adjustable on ServerConfig, or at least add a comment in the code that explains why 10 is used. Would it be worth making either of these additions/changes before merging this PR?

@codecov
Copy link

codecov bot commented Nov 4, 2021

Codecov Report

Merging #1163 (145b177) into ign-gazebo6 (4e879a8) will increase coverage by 0.02%.
The diff coverage is 100.00%.

Impacted file tree graph

@@               Coverage Diff               @@
##           ign-gazebo6    #1163      +/-   ##
===============================================
+ Coverage        63.69%   63.72%   +0.02%     
===============================================
  Files              256      256              
  Lines            20116    20116              
===============================================
+ Hits             12813    12819       +6     
+ Misses            7303     7297       -6     
Impacted Files Coverage Δ
src/SimulationRunner.cc 93.92% <100.00%> (+1.01%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4e879a8...145b177. Read the comment docs.

@chapulina
Copy link
Contributor

Would it be worth making either of these additions/changes before merging this PR?

I'd say at least the comment would be a good idea. I'm fine exposing the parameter in a later PR. We may want to think a bit more about how to expose these "small" options, so that we don't bloat ServerConfig and the command line options

@adlarkin
Copy link
Contributor Author

adlarkin commented Nov 4, 2021

I'd say at least the comment would be a good idea.

I left a comment in 145b177. We should wait to merge this until gazebosim/gz-gui#306 and #1163 are merged in order for the comment to make sense with the git history.

I'm fine exposing the parameter in a later PR. We may want to think a bit more about how to expose these "small" options, so that we don't bloat ServerConfig and the command line options

I've opened an issue for this (#1164). We can have the discussion there.

@chapulina chapulina merged commit ee8c3fd into ign-gazebo6 Nov 9, 2021
@chapulina chapulina deleted the adlarkin/world_stats_pub_rate branch November 9, 2021 02:13
WilliamLewww pushed a commit to WilliamLewww/ign-gazebo that referenced this pull request Dec 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏯 fortress Ignition Fortress 🌱 garden Ignition Garden
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants