Closed
Description
We currently do not batch agent metadata. This causes a fair number of requests and DB load. Our documentation even has a formula for how much DB load a number of metadata would generate.
You can expect (10 * 6 * 2) / 4 or 30 writes per second.
There are a couple of ways we could optimize this:
- Batch metadata on the agent side and only send them when there is new data
- Batch metadata on the coderd side (similar to what we do for agent stats)