I saw lots of questions and explanations regarding empty catch clauses but I was never actually sure what "empty" means.
Is a catch clause like this empty? It clearly isn't empty for the eye because there is one line of code. But the catch is not really handled. Instead the error is just logged.
try {
// do some work
} catch (SomeException e) {
logger.error("Some error", e);
}
I see this fairly often because there are a lot exceptions where you just can't do something about it if it fails. The consequence is that the error is not fully swallowed but at least logged.
So the question is: Is this bad code if you "just" log the error and don't do anything about?