Closed cijothomas closed 21 hours ago
Thanks, let's track this potential improvement with benchmark of both memory and throughput while handling this.
From 7/2 SIG meeting: Start with default = 8. In future, we can make it configurable, if we chose to and there is demand.
I think we discussed it earlier - If we plan to start with default size, we can also evaluate using smallvec, to allocate this initial capacity on stack. tokio-tracing is doing something similar for the metrics attributes.
Opening an issue to track this improvement. The change can improve current throughput, benchmark by 10-20% (as they all need ~5 attributes.)