package com.ningdatech.pmapi.staging.utils;

import java.util.Map;
import javax.annotation.PostConstruct;

import lombok.AllArgsConstructor;
import org.springframework.stereotype.Component;
import com.google.common.collect.Maps;
import lombok.RequiredArgsConstructor;

/**
 * 工作通知流转 事件函数MAP
 * @return
 * @author CMM
 * @since 2023/02/28 17:03
 */
@Component
@AllArgsConstructor
public class WorkNoticeFlowMapUtil {
    /**
     * key 重试的次数 , value 是增加是描述
     */
    public Map<Integer, Integer> intervalTimeMap = Maps.newHashMap();

    /**
     *  扫描的间隔越来越长 秒数
     */
    public WorkNoticeFlowMapUtil(){
        intervalTimeMap.put(0,60);
        intervalTimeMap.put(1,60 * 2);
        intervalTimeMap.put(2,60 * 6);
        intervalTimeMap.put(3,60 * 15);
        intervalTimeMap.put(4,60 * 30);
        intervalTimeMap.put(5,60 * 60);
        intervalTimeMap.put(6,60 * 60 * 2);
        intervalTimeMap.put(7,60 * 60 * 5);
        intervalTimeMap.put(8,60 * 60 * 12);
        intervalTimeMap.put(9,60 * 60 * 24);
        intervalTimeMap.put(10,60 * 60 * 72);
        intervalTimeMap.put(11,60 * 60 * 216);
    }
}
