#!/usr/bin/python
# -*- coding: UTF-8 -*-
# Copyright (c) Huawei Technologies Co., Ltd. 2022-2023. All rights reserved.

SERVICE_NAME = "DistributedStorage"


class PostCheckStatus(object):
    CHECKING = 0
    SUCCESSED = 1
    FAILERED = 2


class ErrorInfo(object):
    OK = 0
    ERROR_IS_MASTER = 2
    ERROR_IS_STANDBY = 3
    ERROR_PACKAGE_DIR_NOT_EXIST = 4
    ERROR_PACKAGE_DIR_IS_EXIST = 5
    ERROR_SAME_VERSION = 6


class UnifyPwdInfo:
    COMPONENT_NAME = 'Distributed storage'
    SUB_COMPONENT_NAME = 'Distributed Block Storage'


class Constant:
    WIN_PMI_RET_DIR = 'c:\\pmi_res_file_tmp{}'
    WIN_PMI_DETAILS_DIR = 'c:\\pmi_detail_file_tmp{}'
    UNIX_PMI_RET_DIR = '/tmp/pmi_res_file_tmp{}'
    UNIX_PMI_DETAILS_DIR = '/tmp/pmi_detail_file_tmp{}'

    # url
    PRODUCT_URL = "/api/v2/cluster/product"
    GET_ALARM_URL = "/api/v2/common/alarms"
    GET_ALARM_COUNT_URL = "/api/v2/common/alarm_count"
    DOWNLOAD_INSPECTION_URL = "/api/v2/cluster/inspection/"
