code: private static String addToProperties(String key,String value ) {
  		
      	if(!value.contains(PLACEHOLDER_PREFIX)){
      		allProperties.put(key, value);
      		return value;
      	}
      	
      	String[] segments = value.split("\\$\\{");
  		String seg;
  		
  		StringBuilder finalValue = new StringBuilder();
  		for (int i = 0; i < segments.length; i++) {
  			seg = StringUtils.trimToNull(segments[i]);
  			if(StringUtils.isBlank(seg))continue;
  			
  			if(seg.contains(PLACEHOLDER_SUFFIX)){	
  				String refKey = seg.substring(0, seg.indexOf(PLACEHOLDER_SUFFIX)).trim();
  				//其他非${}的占位符如：{{host}}
  				String withBraceString = null;
  				if(seg.contains("{")){
  					withBraceString = seg.substring(seg.indexOf(PLACEHOLDER_SUFFIX)+1);
  				}
  				
  				//如果包含默认值，如：${host:127.0.0.1}
  				String defaultValue = null;
  				if(refKey.contains(":")){
  					String[] tmpArray = refKey.split(":");
  					refKey = tmpArray[0];
  					defaultValue = tmpArray[1];
  				}
  				
  				String refValue = getProperty(refKey);
  				if(StringUtils.isBlank(refValue)){
  					refValue = defaultValue;
  				}
  				finalValue.append(refValue);
  				
  				if(withBraceString != null){
  					finalValue.append(withBraceString);
  				}else{
  					String[] segments2 = seg.split("\\}");
  					if(segments2.length == 2){
  						finalValue.append(segments2[1]);
  					}
  				}
  			}else{
  				finalValue.append(seg);
  			}
  		}
  		
  		allProperties.put(key, finalValue.toString());
  		
  		return finalValue.toString();
  	}
docs: 如果替换包含占位符则替换占位符
  @param key
  @return