The upside of this approach is that it is more future proof when we add more type forwarding attributes. The downside is that it requires slightly more "heavy" lifting during assembly scanner initialization.
Base PR
This PR
The frozen set creation takes the majority of the time
@bording and I discussed an alternative to https://github.com/Particular/NServiceBus/pull/7081 that discovers forwarded types and includes those in scanning. Unfortunately it is not possible to reflect the type forwarding attributes because they get erased. You can only access the information by using the metadata reader.
The upside of this approach is that it is more future proof when we add more type forwarding attributes. The downside is that it requires slightly more "heavy" lifting during assembly scanner initialization.
Base PR
This PR
The frozen set creation takes the majority of the time
what if we'd change it to a HashSet