I was aware of the bean declaration convention but besides requiring an extra bean definition for this to work OOTB, if that's already been set, my own bean declaration will have no effect. Because the randomUUID() call is so expensive and because performance is critical here, I want to make sure beyond all doubt that a fast UUID generator is in use, no matter what might already have been set.

I've tried to find an alternative but MessageHeaders is very limiting and it's declared final, so the only way around the randomUUID() is by that static IdGenerator field.