/** * 创建认证信息 * @return */ private List<AuthInfo> buildAuthInfo() { List<AuthInfo> info = new ArrayList<AuthInfo>(); String scheme = registryConfig.getParameter("scheme"); //如果存在多个认证信息,则在参数形式为为addAuth=user1:paasswd1,user2:passwd2 String addAuth = registryConfig.getParameter("addAuth"); if (StringUtils.isNotEmpty(addAuth)) { String[] addAuths = addAuth.split(","); for (String singleAuthInfo : addAuths) { info.add(new AuthInfo(scheme, singleAuthInfo.getBytes())); } } return info; } }
/** * 创建认证信息 * @return */ private List<AuthInfo> buildAuthInfo() { List<AuthInfo> info = new ArrayList<AuthInfo>(); String scheme = registryConfig.getParameter("scheme"); //如果存在多个认证信息,则在参数形式为为addAuth=user1:paasswd1,user2:passwd2 String addAuth = registryConfig.getParameter("addAuth"); if (StringUtils.isNotEmpty(addAuth)) { String[] addAuths = addAuth.split(","); for (String singleAuthInfo : addAuths) { info.add(new AuthInfo(scheme, singleAuthInfo.getBytes())); } } return info; } }
rootPath = CONTEXT_SEP; preferLocalFile = !CommonUtils.isFalse(registryConfig.getParameter(PARAM_PREFER_LOCAL_FILE)); ephemeralNode = !CommonUtils.isFalse(registryConfig.getParameter(PARAM_CREATE_EPHEMERAL)); if (LOGGER.isInfoEnabled()) { LOGGER.info(
rootPath = CONTEXT_SEP; preferLocalFile = !CommonUtils.isFalse(registryConfig.getParameter(PARAM_PREFER_LOCAL_FILE)); ephemeralNode = !CommonUtils.isFalse(registryConfig.getParameter(PARAM_CREATE_EPHEMERAL)); if (LOGGER.isInfoEnabled()) { LOGGER.info(
this.scanPeriod = CommonUtils.parseInt(registryConfig.getParameter("registry.local.scan.period"), scanPeriod); Runnable task = new Runnable() {
this.scanPeriod = CommonUtils.parseInt(registryConfig.getParameter("registry.local.scan.period"), scanPeriod); Runnable task = new Runnable() {
/** * 创建认证信息 * @return */ private List<AuthInfo> buildAuthInfo() { List<AuthInfo> info = new ArrayList<AuthInfo>(); String scheme = registryConfig.getParameter("scheme"); //如果存在多个认证信息,则在参数形式为为addAuth=user1:paasswd1,user2:passwd2 String addAuth = registryConfig.getParameter("addAuth"); if (StringUtils.isNotEmpty(addAuth)) { String[] addAuths = addAuth.split(","); for (String singleAuthInfo : addAuths) { info.add(new AuthInfo(scheme, singleAuthInfo.getBytes())); } } return info; } }
rootPath = CONTEXT_SEP; preferLocalFile = !CommonUtils.isFalse(registryConfig.getParameter(PARAM_PREFER_LOCAL_FILE)); ephemeralNode = !CommonUtils.isFalse(registryConfig.getParameter(PARAM_CREATE_EPHEMERAL)); if (LOGGER.isInfoEnabled()) { LOGGER.info(
this.scanPeriod = CommonUtils.parseInt(registryConfig.getParameter("registry.local.scan.period"), scanPeriod); Runnable task = new Runnable() {