find and fix a bug when changeHostState
@@ -90,7 +90,7 @@ public class HostApiInterceptor implements ApiMessageInterceptor {
.select(HostVO_.status)
.eq(HostVO_.uuid,msg.getHostUuid())
.findValue();
- if (hostStatus == HostStatus.Connecting){
+ if (hostStatus == HostStatus.Connecting && msg.getStateEvent().equals(HostStateEvent.maintain.toString())){
throw new ApiMessageInterceptionException(operr("can not maintain host[uuid:%s]which is connecting", msg.getHostUuid()));
}
}
