The patch fixes the logging issue and also corrects a few typos in comments and access to static constants.
I think the intent was actually to use trace level logging. We're reporting an error, but one that we can recover from. The method doesn't re-throw the exception and the original intent appears to be just to recover silently. Still it's not obvious what the intent is and it needs to be fixed.
Good catch Milosz
Yes, using the trace level should also be acceptable.
On the other hand, I had another look at this and could not see any reasonable exception being thrown. So now I am in favor of removing this try/catch completely, at least in the trunk.
Unfortunately this piece of code is too old too have its history in the SVN.
I noticed the same thing about history in SVN. This code was added when OpenJPA was in the incubator. If the incubator's svn repository is still available we could probably find it there.
I think I agree with you regarding removing the try / catch. Seems to me if we can't detect the version of DB2 we'd want to fail early rather than having an empty forUpdateClause.
Catalina, do you have a recommendation? You've done a lot of work with DB2 and might remember when this code was added.
Milosz & Mike,
That try/catch block seems unnecessary. I am OK with removing that try/catch.