Commit 66a0f063 66a0f063e2c6e67fe276ae9f8cdadb585f259a4e by Christian Gerdes

Age and RT will be calculated even if an exception occurs during

getData()
1 parent 9d2e5988
...@@ -360,8 +360,8 @@ public class OraMon { ...@@ -360,8 +360,8 @@ public class OraMon {
360 } 360 }
361 // We do have the lock. Do the rest in a try catch everything and if we catch anything, re throw the catch but always release the lock. 361 // We do have the lock. Do the rest in a try catch everything and if we catch anything, re throw the catch but always release the lock.
362 Statement stmt = null; 362 Statement stmt = null;
363 long startTSns = System.nanoTime();
363 try { 364 try {
364 long startTSns = System.nanoTime();
365 getDataCalls++; 365 getDataCalls++;
366 if(conn == null) open(); 366 if(conn == null) open();
367 if(conn.isClosed()) open(); 367 if(conn.isClosed()) open();
...@@ -455,6 +455,8 @@ public class OraMon { ...@@ -455,6 +455,8 @@ public class OraMon {
455 } catch (Exception e2) { 455 } catch (Exception e2) {
456 // Dont care 456 // Dont care
457 } 457 }
458 lastFetchTSns = System.nanoTime();
459 lastRTns = lastFetchTSns - startTSns;
458 throw (e); 460 throw (e);
459 } finally { 461 } finally {
460 lock.unlock(); 462 lock.unlock();
......