Description
Is this a possible security vulnerability?
- This is NOT a possible security vulnerability
Describe the bug
The only implementation of PolarisDiagnostics
is a rather wrapper around Guava's Preconditions
. Instance(s) of PolarisDiagnostics
are carried around in a bunch of places. Just carrying around this instance to wrap the common Preconditions
is unnecessary and leads to a lot of rather unnecessary code.
Replacing PolarisDiagnostics(Impl)
with plain calls to Preconditions
simplifies the code base in a lot of places.
RuntimeException
s can always be caught properly at the service level or even below and handled accordingly. If finer grained handling is necessary, it's better to have implicit/injected tracing mechanisms in place, which is more robust and clearer than manual implementations.
The change should also use the opportunity and replace the rather cryptic messages with messages that provide meaningful information to users and ideally also actionable information.
NB: This change would also remove the last usage of the Jetbrains-annotations dependency.