Currently, misconfigured hops sometimes throw either a NullPointerException, a HopperException or an IllegalArgumentException (or something else entirely). We should try to unify the exception types we use.
Proposal: only throw HopperExceptions for cases where ConflictResolution.THROW is used. All other problems should throw other types of exceptions. IMHO we should go with IllegalArgumentException when we can statically determine that a hop is misconfigured. Other problems should raise the proper exception that is encountered at runtime.
Discuss!
Currently, misconfigured hops sometimes throw either a
NullPointerException, aHopperExceptionor anIllegalArgumentException(or something else entirely). We should try to unify the exception types we use.Proposal: only throw
HopperExceptions for cases whereConflictResolution.THROWis used. All other problems should throw other types of exceptions. IMHO we should go withIllegalArgumentExceptionwhen we can statically determine that a hop is misconfigured. Other problems should raise the proper exception that is encountered at runtime.Discuss!