下线应用的时候 判断先下线topic

This commit is contained in:
shirenchuang
2021-04-19 10:17:29 +08:00
parent 5f1a839620
commit 1fdecf8def
2 changed files with 4 additions and 1 deletions

View File

@@ -25,6 +25,9 @@ public enum ResultStatus {
CHANGE_ZOOKEEPER_FORBIDDEN(1405, "change zookeeper forbidden"),
APP_OFFLINE_FORBIDDEN(1406, "先下线topic才能下线应用"),
TOPIC_OPERATION_PARAM_NULL_POINTER(1450, "参数错误"),
TOPIC_OPERATION_PARTITION_NUM_ILLEGAL(1451, "分区数错误"),
TOPIC_OPERATION_BROKER_NUM_NOT_ENOUGH(1452, "Broker数不足错误"),

View File

@@ -95,7 +95,7 @@ public class DeleteAppOrder extends AbstractAppOrder {
// 判断app是否对topic有权限
List<AuthorityDO> authorityList = authorityService.getAuthority(orderAppExtension.getAppId());
if (!ValidateUtils.isEmptyList(authorityList)) {
return ResultStatus.OPERATION_FORBIDDEN;
return ResultStatus.APP_OFFLINE_FORBIDDEN;
}
if (appService.deleteApp(appDO, userName) > 0) {
return ResultStatus.SUCCESS;