So I moved on to wildfly-core where I think are the last points where
groups are created.
I tried to remove the ThreadGroup creation altogether, and if there was
"%G" used in the name pattern I replaced it with the original thread
group name, so in effect there should be no change in the names of the
threads.
One more interesting place I found is the thread-factory resource
(ThreadFactoryResourceDefinition) which allows a user to define custom
thread factory and define the priority, group name and name pattern
attributes. The priority is however not set via the ThreadGroup
instance but directly on created threads, so the ThreadGroup is still
mostly a decoration.
https://github.com/wildfly/wildfly-core/pull/5672
Regards,
Tomas