com.xinjump.easyexcel.example.DemoApplication Maven / Gradle / Ivy
package com.xinjump.easyexcel.example;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.web.servlet.MultipartConfigFactory;
import org.springframework.context.annotation.Bean;
import javax.servlet.MultipartConfigElement;
@SpringBootApplication
public class DemoApplication {
public static void main(String[] args) {
try {
SpringApplication.run(DemoApplication.class, args);
} catch (Throwable e) {
e.printStackTrace();
}
}
@Bean
public MultipartConfigElement multipartConfigElement() {
MultipartConfigFactory factory = new MultipartConfigFactory();
factory.setMaxRequestSize("200Mb");
factory.setMaxFileSize("200Mb");
return factory.createMultipartConfig();
}
}