Actually, now that I take a closer look, it seems to me that the io.dropwizard.jackson.Discoverable mechanism is totally unnecessary. A much simpler mechanism is to create a Jackson module that registers your subtypes and then simply register the module in your application's initialize(Bootstrap) method via bootstrap.getObjectMapper().registerModule(new MyConfigClassModule());
This alternate Jacksom module approach has multiple advantages. Fiirst, it eliminates the need to create any META-INF/services classes (which I find to be annoying and cumbersome, especially if/when I rename config classes). Second, it relies completely on Jackson -- there is nothing Dropwizard-specific about it. Third, while I am not sure about this, it creates the potential to eliminate the org.apache.maven.plugins.shade.resource.ServiceResourceTransformer requirement (forgetting to include thisis a not-uncommon mistake for Dropwizard beginners).
There is one disadvantage: the need to explicitly register any config class module that you want to use. The current mechanism "just works" out-of-the-box, which is a better end-user experience. One way around this would be to also make the module mechanism "just work" -- perhaps by looking at a file called META-INF/services/com.fasterxml.jackson.databind.Module and then explicitly instantiating an instance (via a default constructor) for every class listed there and registering it as a Jackson module. It keeps the org.apache.maven.plugins.shade.resource.ServiceResourceTransformer requirement but gives a better end-user experience.
Am I missing something?
Ron