We missed a few optimizations in the SERVER-75529 refactor:
- use str::stream when constructing from a DatabaseName
- eliminate a string allocation used only for validation
use fmt::format instead of str::stream for all string building
We missed a few optimizations in the SERVER-75529 refactor: