use of com.sohu.cache.entity.AppDesc in project cachecloud by sohutv.
the class ImportAppCenterTest method testCheckWrongFormatAppInstanceInfo5.
/**
* 应用实例详情格式有问题5
*/
@Test
public void testCheckWrongFormatAppInstanceInfo5() {
// 应用信息
AppDesc appDesc = new AppDesc();
appDesc.setName("carlosfu5");
// 实例信息
String appInstanceInfo = "10.10.53.162:ab:1024";
ImportAppResult importAppResult = importAppCenter.check(appDesc, appInstanceInfo);
logger.info("importAppResult: {}", importAppResult);
}
use of com.sohu.cache.entity.AppDesc in project cachecloud by sohutv.
the class ImportAppCenterTest method testCheckNotRunInstance.
/**
* 已经存在实例信息
*/
@Test
public void testCheckNotRunInstance() {
// 应用信息
AppDesc appDesc = new AppDesc();
appDesc.setName("carlosfu7");
// 实例信息
String appInstanceInfo = "10.10.53.162:6399:1024";
ImportAppResult importAppResult = importAppCenter.check(appDesc, appInstanceInfo);
logger.info("importAppResult: {}", importAppResult);
}
use of com.sohu.cache.entity.AppDesc in project cachecloud by sohutv.
the class ImportAppCenterTest method testImport.
@Test
public void testImport() {
// 应用信息
AppDesc appDesc = new AppDesc();
appDesc.setName("my-old-sentinel");
appDesc.setIntro("my-old-sentinel desc");
appDesc.setOfficer("付磊");
appDesc.setCreateTime(new Date());
appDesc.setPassedTime(new Date());
appDesc.setIsTest(1);
appDesc.setType(ConstUtils.CACHE_TYPE_REDIS_CLUSTER);
appDesc.setMemAlertValue(80);
appDesc.setStatus(2);
appDesc.setUserId(1);
appDesc.setVerId(1);
// 实例信息
String appInstanceInfo = "10.10.53.159:7000:512\n" + "10.10.53.159:7001:512\n" + "10.10.53.159:26379:mymaster\n" + "10.10.53.159:26380:mymaster\n" + "10.10.53.159:26381:mymaster";
boolean result = importAppCenter.importAppAndInstance(appDesc, appInstanceInfo);
logger.info("result: {}", result);
}
use of com.sohu.cache.entity.AppDesc in project cachecloud by sohutv.
the class ImportAppCenterTest method testCheckSentinelAllNodes.
/**
* 检测sentinel节点
*/
@Test
public void testCheckSentinelAllNodes() {
// 应用信息
AppDesc appDesc = new AppDesc();
appDesc.setName("carlosfu12");
// 实例信息
String appInstanceInfo = "10.10.53.159:7000:512\n" + "10.10.53.159:7001:512\n" + "10.10.53.159:26379:mymaster\n" + "10.10.53.159:26380:mymaster\n" + "10.10.53.159:26381:mymaster";
ImportAppResult importAppResult = importAppCenter.check(appDesc, appInstanceInfo);
logger.info("importAppResult: {}", importAppResult);
}
use of com.sohu.cache.entity.AppDesc in project cachecloud by sohutv.
the class ImportAppCenterTest method testCheckExistInstanceInfo.
/**
* 已经存在实例信息
*/
@Test
public void testCheckExistInstanceInfo() {
// 应用信息
AppDesc appDesc = new AppDesc();
appDesc.setName("carlosfu6");
// 实例信息
String appInstanceInfo = "10.10.53.162:6379:1024";
ImportAppResult importAppResult = importAppCenter.check(appDesc, appInstanceInfo);
logger.info("importAppResult: {}", importAppResult);
}
Aggregations