Replace ImplementationNotAccessibleException with RuntimeException
We're defining two custom exception classes in metrics-lib: DescriptorParseException
and ImplementationNotAccessibleException
. The first makes sense to me, because applications might want to catch and handle that. In fact they have to, because it's a checked exception.
But I don't see why we have ImplementationNotAccessibleException
there. It's only thrown in DescriptorSourceFactory
in this method, and it's a runtime exception that applications shouldn't catch anyway. We could easily replace it with a generic RuntimeException
with the same message and have one type less in the API.
I'd say that given it's a runtime exception, we can take it out in 1.8.0. But if that's too soon, let's deprecate it now and take it out in 2.0.0.
Thoughts?