[ 
https://issues.apache.org/jira/browse/WW-5141?focusedWorklogId=893214&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-893214
 ]

ASF GitHub Bot logged work on WW-5141:
--------------------------------------

                Author: ASF GitHub Bot
            Created on: 30/Nov/23 15:59
            Start Date: 30/Nov/23 15:59
    Worklog Time Spent: 10m 
      Work Description: lukaszlenart commented on code in PR #778:
URL: https://github.com/apache/struts/pull/778#discussion_r1410882608


##########
core/src/main/java/org/apache/struts2/dispatcher/multipart/JakartaMultiPartRequest.java:
##########
@@ -186,13 +191,14 @@ protected ServletFileUpload 
createServletFileUpload(DiskFileItemFactory fac) {
     }
 
     protected DiskFileItemFactory createDiskFileItemFactory(String saveDir) {
-        DiskFileItemFactory fac = new DiskFileItemFactory();
+        DiskFileItemFactory.Builder fac = DiskFileItemFactory.builder();
         // Make sure that the data is written to file, even if the file is 
empty.
-        fac.setSizeThreshold(-1);
+        //setting 0 or -1 no longer seems to work for fileupload buffer size, 
so using 1 instead.
+        fac.setBufferSize(1);
         if (saveDir != null) {
-            fac.setRepository(new File(saveDir));
+            fac.setPath(saveDir);

Review Comment:
   is it resolved?





Issue Time Tracking
-------------------

    Worklog Id:     (was: 893214)
    Time Spent: 5.5h  (was: 5h 20m)

> Support for JEE 9+ 
> -------------------
>
>                 Key: WW-5141
>                 URL: https://issues.apache.org/jira/browse/WW-5141
>             Project: Struts 2
>          Issue Type: New Feature
>          Components: Core
>            Reporter: Daniel Le Berre
>            Priority: Major
>             Fix For: 7.0.0
>
>         Attachments: pom.xml
>
>          Time Spent: 5.5h
>  Remaining Estimate: 0h
>
> JEE 9 breaks the JEE API by replacing javax domain by jakarta.
> Tomcat 10 implements some specifications of JEE 9.
> Struts 2.5 has some dependencies with the javax servlet API.
> Struts would require some changes to run on Tomcat 10+.
> Is there any plan to support JEE 9+ in the future?
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to