package com.usky.cdi.service.config;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;

@Data
@ConfigurationProperties(prefix = "gb28181.video")
public class Gb28181VideoProperties {

    private boolean enabled = false;

    /** 市平台 MQTT */
    private Integer tenantId;
    private Long engineeringId;
    private String mqttUsername;
    private String mqttPassword;
    private String mqttTopic = "base/videoDevice";
    private String mqttStreamTopic = "iotInfo/videoStream";

    /** 国标流媒体平台（WVP）SIP 参数 */
    private String sipId = "34020000002000000001";
    private String sipDomain = "3402000000";
    private String sipIp = "114.80.201.142";
    private int sipPort = 15060;
    private int cascadePort = 15061;
    private int rtpPortMin = 30100;
    private int rtpPortMax = 30500;

    /** WVP HTTP API */
    private String apiBaseUrl = "http://114.80.201.142:18080";
    private String apiUsername = "admin";
    private String apiPassword = "admin";

    /** 定时同步设备目录 cron */
    private String syncCron = "0 0/30 * * * ?";

    /** 同步时是否为在线通道拉取预览地址 */
    private boolean fetchPlayUrl = false;

    /** WVP 点播推流 + MQTT 上报播放地址 */
    private boolean streamPushEnabled = false;
    private String streamPushCron = "0 */5 * * * ?";
    private boolean autoPushAllOnline = false;
    private int maxConcurrentStreams = 10;
    private String preferredProtocol = "flv";
}
