@Override public void updateServerAddress(Application application,String dockerManagerIP,String serverPort,String serverManagerPort){
  String suffixCloudUnit=application.getSuffixCloudUnitIO();
  JedisPool pool=null;
  Jedis jedis=null;
  try {
    pool=new JedisPool(new JedisPoolConfig(),redisIp,Integer.parseInt(redisPort),3000);
    jedis=pool.getResource();
    String subNameSpace=concatSubNameSpace(application);
    String key=subNameSpace + suffixCloudUnit;
    String frontend="frontend:" + key.toLowerCase();
    jedis.lset(frontend,1,"http://" + dockerManagerIP + ":"+ serverPort);
    String frontendServerManager="frontend:manager-" + key.toLowerCase();
    jedis.lset(frontendServerManager,1,"http://" + dockerManagerIP + ":"+ serverManagerPort);
  }
 catch (  JedisConnectionException|UnsupportedEncodingException e) {
    logger.error("HipacheRedisUtils Exception",e);
  }
 finally {
    if (jedis != null) {
      pool.destroy();
    }
  }
}

@ Override public void updateServerAddress ( Application application , String dockerManagerIP , String serverPort , String serverManagerPort ) { String suffixCloudUnit = application . getSuffixCloudUnitIO ( ) ; JedisPool pool = null ; Jedis jedis = null ; try { pool = new JedisPool ( new JedisPoolConfig ( ) , redisIp , Integer . parseInt ( redisPort ) , 3000 ) ; jedis = pool . getResource ( ) ; String subNameSpace = concatSubNameSpace ( application ) ; String key = subNameSpace + suffixCloudUnit ; String frontend = "frontend:" + key . toLowerCase ( ) ; jedis . lset ( frontend , 1 , "http://" + dockerManagerIP + ":" + serverPort ) ; String frontendServerManager = "frontend:manager-" + key . toLowerCase ( ) ; jedis . lset ( frontendServerManager , 1 , "http://" + dockerManagerIP + ":" + serverManagerPort ) ; } catch ( JedisConnectionException | UnsupportedEncodingException e ) { logger . error ( "HipacheRedisUtils Exception" , e ) ; } finally { if ( jedis != null ) { pool . destroy ( ) ; } } }
update the server address
