Reduce footprint when tagging spans via prototype pattern (#4318)
### Motivation: Reduce footprint when tagging spans with the deprecated API: `AbstractSpan#tag(String, String)`. ### Modifications: - Adopt [prototype pattern](https://en.wikipedia.org/wiki/Prototype_pattern) to create `Tag`, prevent from creating too many `StringTag` instances and `GC`ed. - Replace `AbstractSpan#tag(String, String)` with `AbstractSpan#tag(AbstractTag, String)`. ### Result: - Footprint is reduced.
Showing
想要评论请 注册 或 登录