plugins/org.apache.karaf.eik.app/src/main/java/org/apache/karaf/main/OracleJDBCLock.java [196:223]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    public boolean isAlive() throws Exception {
        if ((lockConnection == null) || (lockConnection.isClosed())) { 
            LOG.severe("Lost lock!");
            return false; 
        }
        PreparedStatement statement = null;
        boolean result = true;
        try { 
            long time = System.currentTimeMillis();
            statement = lockConnection.prepareStatement(statements.getLockUpdateStatement(time));
            int rows = statement.executeUpdate();
            if (rows < 1) {
                result = false;
            }
        } catch (Exception ex) {
            LOG.severe("Error occured while testing lock: " + ex + " " + ex.getMessage());
            return false;
        } finally {
            if (statement != null) {
                try {
                    statement.close();
                } catch (Exception ex1) {
                    LOG.severe("Error occured after testing lock: " + ex1.getMessage());
                }
            }
        }
        return result;
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



plugins/org.apache.karaf.eik.app/src/main/java/org/apache/karaf/main/MySQLJDBCLock.java [192:219]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    public boolean isAlive() throws Exception {
        if ((lockConnection == null) || (lockConnection.isClosed())) { 
            LOG.severe("Lost lock!");
            return false; 
        }
        PreparedStatement statement = null;
        boolean result = true;
        try { 
            long time = System.currentTimeMillis();
            statement = lockConnection.prepareStatement(statements.getLockUpdateStatement(time));
            int rows = statement.executeUpdate();
            if (rows < 1) {
                result = false;
            }
        } catch (Exception ex) {
            LOG.severe("Error occured while testing lock: " + ex + " " + ex.getMessage());
            return false;
        } finally {
            if (statement != null) {
                try {
                    statement.close();
                } catch (Exception ex1) {
                    LOG.severe("Error occured after testing lock: " + ex1.getMessage());
                }
            }
        }
        return result;
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



plugins/org.apache.karaf.eik.app/src/main/java/org/apache/karaf/main/DefaultJDBCLock.java [160:187]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    public boolean isAlive() throws Exception {
        if ((lockConnection == null) || (lockConnection.isClosed())) {
            LOG.severe("Lost lock!");
            return false;
        }
        PreparedStatement statement = null;
        boolean result = true;
        try {
            long time = System.currentTimeMillis();
            statement = lockConnection.prepareStatement(statements.getLockUpdateStatement(time));
            int rows = statement.executeUpdate();
            if (rows < 1) {
                result = false;
            }
        } catch (Exception ex) {
            LOG.severe("Error occured while testing lock: " + ex + " " + ex.getMessage());
            return false;
        } finally {
            if (statement != null) {
                try {
                    statement.close();
                } catch (Exception ex1) {
                    LOG.severe("Error occured after testing lock: " + ex1.getMessage());
                }
            }
        }
        return result;
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



