package cn.common;
import javax.annotation.PostConstruct;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Component;
/**
* 初始化spring bean
*
* 日期:2015年8月29日
*/
@Component
@Lazy(false)
public class InitConfigSpringBean {
@PostConstruct
public void initDemo() {
System.err.println("---set max content size");
System.setProperty("org.eclipse.jetty.server.Request.maxFormContentSize", "3000000000");
}
}
springmvc bean初始化
最新推荐文章于 2023-11-01 23:11:21 发布
本文介绍了一个使用Spring框架的Java类,该类通过@PostConstruct注解实现Spring Bean的初始化过程。具体操作包括设置系统属性来调整Jetty服务器的请求最大内容尺寸。
1333

被折叠的 条评论
为什么被折叠?



