-
Notifications
You must be signed in to change notification settings - Fork 342
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Environment
- OS Version: Ubuntu 24.04.3 LTS
- Source or binary build? Binary, Gazebo Sim, version 8.9.0
I have detected a probable memory leak during a development of a plugin for Gazebo.
I have created a Gazebo Plugin to demonstrate the probable memory leak when creating and removing entities using the Entity Component Manager. I noticed an increase in memory usage when I had more complex entities, and entities with child entities. This feature is important for my plugin. Therefore, I created this example to isolate the problem.
Description
- Expected behavior: Memory usage to be constant by the process.
- Actual behavior: Memory usage increased by the process.
Steps to reproduce
- Use the example source code (https://github.com/lomcin/gz_entity_create_plugin_ws) for a plugin that only creates and removes entities in PreUpdate method.
- Read the plugin code (entity_create_plugin), then Run the quickstart command.
- Check the memory usage of gz sim gui, it should be increasing in case of memory leak after 30k iterations.
Output
I did run the code until the entity id was 9218205, just to demonstrate the issue.
As you can see in the first print, I have just started the Gazebo, and I'm watching the memory usage of its processes. 191.1 MB for the gz sim gui.

Then, after 5h and 10 minutes I've got this (345.4 MB for the gz sim gui):

Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
Type
Projects
Status
Inbox