Commit cdf83981 authored by BaiJiangJie's avatar BaiJiangJie

[Update] 修复创建es命令存储校验有效性异常

parent 1bfef829
......@@ -144,7 +144,11 @@ class CommandStorageCreateAPI(APIView):
def is_valid(storage_data):
if storage_data.get('TYPE') == 'server':
return True
try:
storage = jms_storage.get_log_storage(storage_data)
except Exception:
return False
return storage.ping()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment