Browse Source

Pull request #1667: REPORT-31261 WangEditor富文本控件

Merge in DESIGN/design from ~LUCIAN.CHEN/design:bugfix/10.0 to bugfix/10.0

* commit 'fa45ecfd1dbea4817a3f260c85b44b666e00a4f4':
  REPORT-31261 WangEditor富文本控件
bugfix/10.0
Lucian.Chen 4 years ago
parent
commit
7082f6753a
  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