core/configuration-service/src/main/java/org/hawkular/metrics/sysconfig/ConfigurationService.java
public void init(RxSession session) {
        this.session = session;
        findConfigurationGroup = session.getSession()
                .prepare("SELECT name, value FROM sys_config WHERE config_id = ?")
                .setConsistencyLevel(ConsistencyLevel.LOCAL_QUORUM);

        findConfigurationValue = session.getSession()
                .prepare("SELECT value FROM sys_config WHERE config_id = ? AND name= ?")
                .setConsistencyLevel(ConsistencyLevel.LOCAL_QUORUM);

        updateConfigurationValue = session.getSession().prepare(
                "INSERT INTO sys_config (config_id, name, value) VALUES (?, ?, ?)")
                .setConsistencyLevel(ConsistencyLevel.LOCAL_QUORUM);

        deleteConfigurationValue = session.getSession().prepare(
                "DELETE FROM sys_config WHERE config_id =? and name = ?")
                .setConsistencyLevel(ConsistencyLevel.LOCAL_QUORUM);

        deleteConfiguration = session.getSession().prepare(
                "DELETE FROM sys_config WHERE config_id = ?")
                .setConsistencyLevel(ConsistencyLevel.LOCAL_QUORUM);
    }
public void init(RxSession session) {
        this.session = session;
        findConfigurationGroup = session.getSession()
                .prepare("SELECT name, value FROM sys_config WHERE config_id = ?")
                .setConsistencyLevel(ConsistencyLevel.LOCAL_QUORUM);

        findConfigurationValue = session.getSession()
                .prepare("SELECT value FROM sys_config WHERE config_id = ? AND name= ?")
                .setConsistencyLevel(ConsistencyLevel.LOCAL_QUORUM);

        updateConfigurationValue = session.getSession().prepare(
                "INSERT INTO sys_config (config_id, name, value) VALUES (?, ?, ?)")
                .setConsistencyLevel(ConsistencyLevel.LOCAL_QUORUM);

        deleteConfigurationValue = session.getSession().prepare(
                "DELETE FROM sys_config WHERE config_id =? and name = ?")
                .setConsistencyLevel(ConsistencyLevel.LOCAL_QUORUM);

        deleteConfiguration = session.getSession().prepare(
                "DELETE FROM sys_config WHERE config_id = ?")
                .setConsistencyLevel(ConsistencyLevel.LOCAL_QUORUM);
    }
public void init ( RxSession session ) { this . session = session ; findConfigurationGroup = session . getSession ( ) . prepare ( "SELECT name, value FROM sys_config WHERE config_id = ?" ) . setConsistencyLevel ( ConsistencyLevel . LOCAL_QUORUM ) ; findConfigurationValue = session . getSession ( ) . prepare ( "SELECT value FROM sys_config WHERE config_id = ? AND name= ?" ) . setConsistencyLevel ( ConsistencyLevel . LOCAL_QUORUM ) ; updateConfigurationValue = session . getSession ( ) . prepare ( "INSERT INTO sys_config (config_id, name, value) VALUES (?, ?, ?)" ) . setConsistencyLevel ( ConsistencyLevel . LOCAL_QUORUM ) ; deleteConfigurationValue = session . getSession ( ) . prepare ( "DELETE FROM sys_config WHERE config_id =? and name = ?" ) . setConsistencyLevel ( ConsistencyLevel . LOCAL_QUORUM ) ; deleteConfiguration = session . getSession ( ) . prepare ( "DELETE FROM sys_config WHERE config_id = ?" ) . setConsistencyLevel ( ConsistencyLevel . LOCAL_QUORUM ) ; }
eventually I would like service initialization async.
eventually I would like service initialization async .