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

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

                Author: ASF GitHub Bot
            Created on: 08/Jul/24 09:18
            Start Date: 08/Jul/24 09:18
    Worklog Time Spent: 10m 
      Work Description: kusalk commented on code in PR #979:
URL: https://github.com/apache/struts/pull/979#discussion_r1668289815


##########
core/src/main/java/com/opensymphony/xwork2/ognl/SecurityMemberAccess.java:
##########
@@ -460,4 +473,41 @@ public void useDisallowProxyMemberAccess(String 
disallowProxyMemberAccess) {
     public void useDisallowDefaultPackageAccess(String 
disallowDefaultPackageAccess) {
         this.disallowDefaultPackageAccess = 
BooleanUtils.toBoolean(disallowDefaultPackageAccess);
     }
+
+    @Inject(StrutsConstants.STRUTS_DEVMODE)
+    protected void useDevMode(String devMode) {
+        this.isDevMode = BooleanUtils.toBoolean(devMode);
+    }
+
+    @Inject(value = StrutsConstants.STRUTS_DEV_MODE_EXCLUDED_CLASSES, required 
= false)
+    public void useDevModeExcludedClasses(String commaDelimitedClasses) {
+        this.devModeExcludedClasses = toNewClassesSet(devModeExcludedClasses, 
commaDelimitedClasses);
+    }
+
+    @Inject(value = 
StrutsConstants.STRUTS_DEV_MODE_EXCLUDED_PACKAGE_NAME_PATTERNS, required = 
false)
+    public void useDevModeExcludedPackageNamePatterns(String 
commaDelimitedPackagePatterns) {
+        this.devModeExcludedPackageNamePatterns = 
toNewPatternsSet(devModeExcludedPackageNamePatterns, 
commaDelimitedPackagePatterns);
+    }
+
+    @Inject(value = StrutsConstants.STRUTS_DEV_MODE_EXCLUDED_PACKAGE_NAMES, 
required = false)
+    public void useDevModeExcludedPackageNames(String 
commaDelimitedPackageNames) {
+        this.devModeExcludedPackageNames = 
toNewPackageNamesSet(devModeExcludedPackageNames, commaDelimitedPackageNames);
+    }
+
+    @Inject(value = 
StrutsConstants.STRUTS_DEV_MODE_EXCLUDED_PACKAGE_EXEMPT_CLASSES, required = 
false)
+    public void useDevModeExcludedPackageExemptClasses(String 
commaDelimitedClasses) {
+        this.devModeExcludedPackageExemptClasses = 
toClassesSet(commaDelimitedClasses);
+    }
+
+    private void useDevModeConfiguration() {
+        if (!isDevMode || isDevModeInit) {

Review Comment:
   The `isDevModeInit` check isn't thread-safe but it doesn't need to be as 
there's no negative consequence of running this method more than once when 
DevMode is enabled.





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

    Worklog Id:     (was: 924764)
    Time Spent: 20m  (was: 10m)

> Fix and clean up devMode excluded classes
> -----------------------------------------
>
>                 Key: WW-5439
>                 URL: https://issues.apache.org/jira/browse/WW-5439
>             Project: Struts 2
>          Issue Type: Improvement
>          Components: Core
>            Reporter: Kusal Kithul-Godage
>            Priority: Minor
>             Fix For: 6.5.0
>
>          Time Spent: 20m
>  Remaining Estimate: 0h
>




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

Reply via email to