posted 18 years ago
Yes, this kind of cleanup is just what finally is for and us worth doing here. You might want to enclose each close in yet another try-catch so a failure in one won't bypass the others. Because nested try-catch is ugly and you will do this in mnay places you might like a closeAll() method that does not throw exceptions.
This may not help with your lock-up issues. Exceptions from your db class must be causing some nasty problems upstream in the call stack.
A good question is never answered. It is not a bolt to be tightened into place but a seed to be planted and to bear more seed toward the hope of greening the landscape of the idea. John Ciardi