[ https://issues.apache.org/jira/browse/WW-5270?focusedWorklogId=834738&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-834738 ]
ASF GitHub Bot logged work on WW-5270: -------------------------------------- Author: ASF GitHub Bot Created on: 20/Dec/22 11:18 Start Date: 20/Dec/22 11:18 Worklog Time Spent: 10m Work Description: kusalk commented on PR #648: URL: https://github.com/apache/struts/pull/648#issuecomment-1359204527 My initial ThreadLocal based approach to reworking the request cleanup process was not functioning as intended. I've reverted to tracking filter recursion as a request attribute but have still retained the reworked logic. This means: - ActionContext is not cleared until the first StrutsPrepareFilter execution for that request has completed - this is irrespective of whether the ActionContext was generated there or not. This can occur when a Struts excluded URL forwards to a non-excluded one. Waiting until the ActionContext is cleared is required by SiteMesh. - The MultiPart component of a request is only cleaned up in the filter execution in which it was wrapped. This is retaining the original behaviour as before. I believe if we try to cleanup at any other stage, it will fail as the `instanceof` check will fail - although I haven't investigated this closely. The implementation is a little confusing at first glance (and was also why I favoured the ThreadLocal based approach) but it's the best I've got right now - open to suggestions. Issue Time Tracking ------------------- Worklog Id: (was: 834738) Time Spent: 20m (was: 10m) > Forwarding from a Struts excluded URL to an Action not working > -------------------------------------------------------------- > > Key: WW-5270 > URL: https://issues.apache.org/jira/browse/WW-5270 > Project: Struts 2 > Issue Type: Bug > Components: Core > Affects Versions: 6.2.0 > Reporter: Kusal Kithul-Godage > Priority: Minor > Fix For: 6.2.0 > > Time Spent: 20m > Remaining Estimate: 0h > > Since the fix implemented in WW-5199 - I noticed forwards still did not > function when it originated from a Struts excluded URL. This is because the > exclusion flag is being maintained when forwarded. There is also an > additional issue of the ActionContext being cleaned up too soon - prior to > the SiteMesh filter being able to access it. -- This message was sent by Atlassian Jira (v8.20.10#820010)