com.chen.tools.config.CommonConfig Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of commons Show documentation
Show all versions of commons Show documentation
基于springboot框架,将redis、swagger、rabbitmq框架的基本配置整合在一起。
封装了开发常用的工具类,比如StringUtil DateUtil 等等
抽取出项目的返回格式,请求过滤器,异常拦截
The newest version!
package com.chen.tools.config;
import org.springframework.boot.web.servlet.MultipartConfigFactory;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import javax.servlet.MultipartConfigElement;
@Configuration
public class CommonConfig {
@Bean
public MultipartConfigElement multipartConfigElement() {
MultipartConfigFactory factory = new MultipartConfigFactory();
factory.setMaxFileSize(1024L * 1024L*10);
return factory.createMultipartConfig();
}
}