12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061 |
- package com.primeton.damp.config;
- import lombok.Data;
- import lombok.extern.slf4j.Slf4j;
- import org.springframework.boot.context.properties.ConfigurationProperties;
- import org.springframework.stereotype.Component;
- import java.util.HashMap;
- import java.util.Map;
- /**
- * @author zhaopx
- * @date 2021/4/7 17:14
- */
- @Slf4j
- @Data
- @Component
- @ConfigurationProperties(ignoreUnknownFields = true, prefix = "datashard")
- public class DataShardConfig {
- /**
- * 文件系统
- */
- String type = "local";
- /**
- * Local,HDFS 等文件系统的基础路径
- */
- String basePath;
- /**
- * 上传后是否删除源文件
- */
- boolean delSrc = false;
- /**
- * 数据文件后缀
- */
- String fileSuffix = ".bcp";
- /**
- * ftp 配置
- */
- final Map<String, Object> ftp = new HashMap<>();
- /**
- * sftp 配置
- */
- final Map<String, Object> sftp = new HashMap<>();
- public void setFtp(Map<String, Object> ftp) {
- this.ftp.putAll(ftp);
- }
- public void setSftp(Map<String, Object> sftp) {
- this.sftp.putAll(sftp);
- }
- }
|