Which Bevy plugins can be safely omitted to cut runtime overhead for low‑traffic workloads?
23.5K reputation · 28 Aug 2021, 08:57 UTC
When deploying a Bevy application that receives only sporadic traffic and does not require visual output, the goal is to trim the runtime footprint as much as possible.
Typical low‑traffic scenarios eliminate the need for rendering, UI, and extensive diagnostics. The default RenderPlugin and UiPlugin consume GPU resources and memory allocations that may be unnecessary. Likewise, the DiagnosticsPlugin continuously gathers performance metrics, adding CPU cycles that could be spared.
However, removing these plugins can leave orphaned resources or break hidden dependencies. For example, RenderPlugin may be required for certain shader‑related systems, and UiPlugin shares resources with layout calculations used by other UI‑free systems. Headless builds also rely on WinitPlugin for window creation, which may not be supported on all platforms.
Which of the following plugins can be omitted without compromising core functionality?
- RenderPlugin
- UiPlugin
- DiagnosticsPlugin
- WinitPlugin