Browse Source

Pull request #1668: 无jira任务, bugfix -> release

Merge in DESIGN/design from bugfix/10.0 to release/10.0

* commit '7082f6753a4f872bd361e08a94945d6968f740bf':
  REPORT-31261 WangEditor富文本控件
feature/big-screen
neil 5 years ago
parent
commit
d821ea096b
  1. 13
      designer-base/src/main/java/com/fr/start/server/FineEmbedServerActivator.java

13
designer-base/src/main/java/com/fr/start/server/FineEmbedServerActivator.java

@ -62,6 +62,7 @@ public class FineEmbedServerActivator extends Activator {
tomcat.setPort(DesignerEnvManager.getEnvManager().getEmbedServerPort());
// 设置解码uri使用的字符编码
tomcat.getConnector().setURIEncoding(EncodeConstants.ENCODING_UTF_8);
setMaxPostSize();
String docBase = new File(WorkContext.getCurrent().getPath()).getParent();
//内置的上下文使用工程目录比如webroot
@ -79,6 +80,18 @@ public class FineEmbedServerActivator extends Activator {
context.addServletContainerInitializer(initializer, classes);
}
// tomcat的maxPostSize会影响到post参数获取,默认2M
private void setMaxPostSize() {
if (System.getProperty("tomcat-maxPostSize") != null) {
try {
tomcat.getConnector().setMaxPostSize(Integer.parseInt(System.getProperty("tomcat-maxPostSize")));
} catch (Exception e) {
FineLoggerFactory.getLogger().error("maxPostSize error: " + e.getMessage(), e);
}
}
}
private void stopServerActivator() {

Loading…
Cancel
Save