(struts) branch 7.0.x/WW-5411-delete-deprecated-3 updated (d0b53465b -> 1c2961ea1)
This is an automated email from the ASF dual-hosted git repository. kusal pushed a change to branch 7.0.x/WW-5411-delete-deprecated-3 in repository https://gitbox.apache.org/repos/asf/struts.git from d0b53465b WW-5411 Delete deprecated code part 6 add bf56c59d8 WW-5411 Delete old comment add 8c6d7efcc WW-5386 Delete deprecated FileUploadInterceptor add 1c2961ea1 WW-5411 Delete unsupported static field templating No new revisions were added by this update. Summary of changes: .../webapp/WEB-INF/tags/non-ui/ifTag/testIf.jsp| 14 - .../struts2/interceptor/FileUploadInterceptor.java | 273 - core/src/main/resources/struts-default.xml | 1 - .../interceptor/FileUploadInterceptorTest.java | 659 - plugins/bean-validation/pom.xml| 6 - 5 files changed, 953 deletions(-) delete mode 100644 core/src/main/java/org/apache/struts2/interceptor/FileUploadInterceptor.java delete mode 100644 core/src/test/java/org/apache/struts2/interceptor/FileUploadInterceptorTest.java
(struts) branch 7.0.x/WW-5411-delete-deprecated-3 updated (1c2961ea1 -> e070cf7f7)
This is an automated email from the ASF dual-hosted git repository. kusal pushed a change to branch 7.0.x/WW-5411-delete-deprecated-3 in repository https://gitbox.apache.org/repos/asf/struts.git discard 1c2961ea1 WW-5411 Delete unsupported static field templating discard 8c6d7efcc WW-5386 Delete deprecated FileUploadInterceptor add ede5edb10 WW-5411 Delete unsupported static field templating add e070cf7f7 WW-5386 Delete deprecated FileUploadInterceptor This update added new revisions after undoing existing revisions. That is to say, some revisions that were in the old version of the branch are not in the new version. This situation occurs when a user --force pushes a change and generates a repository containing something like this: * -- * -- B -- O -- O -- O (1c2961ea1) \ N -- N -- N refs/heads/7.0.x/WW-5411-delete-deprecated-3 (e070cf7f7) You should already have received notification emails for all of the O revisions, and so the following emails describe only the N revisions from the common base, B. Any revisions marked "omit" are not gone; other references still refer to them. Any revisions marked "discard" are gone forever. No new revisions were added by this update. Summary of changes: core/src/main/resources/struts-default.xml | 8 plugins/bean-validation/src/main/resources/struts-plugin.xml | 2 +- plugins/rest/src/main/resources/struts-plugin.xml| 2 +- 3 files changed, 2 insertions(+), 10 deletions(-)
(struts) branch 7.0.x/WW-5411-delete-deprecated-3 updated (e070cf7f7 -> 1ecfbae46)
This is an automated email from the ASF dual-hosted git repository. kusal pushed a change to branch 7.0.x/WW-5411-delete-deprecated-3 in repository https://gitbox.apache.org/repos/asf/struts.git discard e070cf7f7 WW-5386 Delete deprecated FileUploadInterceptor discard ede5edb10 WW-5411 Delete unsupported static field templating add 9d624069a WW-5411 Delete unsupported static field templating add 1ecfbae46 WW-5386 Delete deprecated FileUploadInterceptor This update added new revisions after undoing existing revisions. That is to say, some revisions that were in the old version of the branch are not in the new version. This situation occurs when a user --force pushes a change and generates a repository containing something like this: * -- * -- B -- O -- O -- O (e070cf7f7) \ N -- N -- N refs/heads/7.0.x/WW-5411-delete-deprecated-3 (1ecfbae46) You should already have received notification emails for all of the O revisions, and so the following emails describe only the N revisions from the common base, B. Any revisions marked "omit" are not gone; other references still refer to them. Any revisions marked "discard" are gone forever. No new revisions were added by this update. Summary of changes: .../src/main/java/org/apache/struts2/showcase/hangman/Hangman.java | 7 ++- apps/showcase/src/main/resources/struts.xml| 1 - 2 files changed, 6 insertions(+), 2 deletions(-)
(struts) branch release/struts-7-0-x updated (5cd03aa02 -> 6265455d1)
This is an automated email from the ASF dual-hosted git repository. kusal pushed a change to branch release/struts-7-0-x in repository https://gitbox.apache.org/repos/asf/struts.git from 5cd03aa02 Merge pull request #1003 from apache/7.0.x/WW-5411-delete-deprecated-2 add d0b53465b WW-5411 Delete deprecated code part 6 add bf56c59d8 WW-5411 Delete old comment add 9d624069a WW-5411 Delete unsupported static field templating add 1ecfbae46 WW-5386 Delete deprecated FileUploadInterceptor add 6265455d1 Merge pull request #1004 from apache/7.0.x/WW-5411-delete-deprecated-3 No new revisions were added by this update. Summary of changes: .../apache/struts2/showcase/hangman/Hangman.java | 7 +- apps/showcase/src/main/resources/struts.xml| 1 - .../webapp/WEB-INF/tags/non-ui/ifTag/testIf.jsp| 14 - .../com/opensymphony/xwork2/ognl/OgnlUtil.java | 16 - .../struts2/interceptor/FileUploadInterceptor.java | 273 - core/src/main/resources/struts-default.xml | 9 - .../com/opensymphony/xwork2/ognl/OgnlUtilTest.java | 18 +- .../interceptor/FileUploadInterceptorTest.java | 659 - plugins/bean-validation/pom.xml| 6 - .../src/main/resources/struts-plugin.xml | 2 +- plugins/rest/src/main/resources/struts-plugin.xml | 2 +- 11 files changed, 17 insertions(+), 990 deletions(-) delete mode 100644 core/src/main/java/org/apache/struts2/interceptor/FileUploadInterceptor.java delete mode 100644 core/src/test/java/org/apache/struts2/interceptor/FileUploadInterceptorTest.java
(struts) branch 7.0.x/WW-5411-delete-deprecated-3 deleted (was 1ecfbae46)
This is an automated email from the ASF dual-hosted git repository. kusal pushed a change to branch 7.0.x/WW-5411-delete-deprecated-3 in repository https://gitbox.apache.org/repos/asf/struts.git was 1ecfbae46 WW-5386 Delete deprecated FileUploadInterceptor The revisions that were on this branch are still contained in other references; therefore, this change does not discard any commits from the repository.
(struts) 01/01: WW-5449 Make Velocity Tools dependency optional for Velocity plugin
This is an automated email from the ASF dual-hosted git repository. kusal pushed a commit to branch 7.0.x/WW-5449-remove-vel-tools in repository https://gitbox.apache.org/repos/asf/struts.git commit db7dd726129b27a381e4089aba83d7911b3ef996 Author: Kusal Kithul-Godage AuthorDate: Fri Jul 26 19:17:00 2024 +1000 WW-5449 Make Velocity Tools dependency optional for Velocity plugin --- plugins/sitemesh/pom.xml | 10 + plugins/velocity/pom.xml | 3 +- .../struts2/views/velocity/VelocityManager.java| 360 - .../struts2/views/velocity/VelocityTools.java | 41 +++ .../views/velocity/VelocityManagerTest.java| 6 +- 5 files changed, 193 insertions(+), 227 deletions(-) diff --git a/plugins/sitemesh/pom.xml b/plugins/sitemesh/pom.xml index c2e1546a3..4ab5e0702 100644 --- a/plugins/sitemesh/pom.xml +++ b/plugins/sitemesh/pom.xml @@ -44,6 +44,16 @@ struts2-velocity-plugin true + +org.apache.struts +struts2-velocity-tools-view-jakarta +true + + +org.apache.struts +struts2-velocity-tools-jsp-jakarta +true + diff --git a/plugins/velocity/pom.xml b/plugins/velocity/pom.xml index b467fa18a..02c7546e8 100644 --- a/plugins/velocity/pom.xml +++ b/plugins/velocity/pom.xml @@ -42,11 +42,12 @@ org.apache.struts struts2-velocity-tools-view-jakarta +true - org.apache.struts struts2-velocity-tools-jsp-jakarta +true diff --git a/plugins/velocity/src/main/java/org/apache/struts2/views/velocity/VelocityManager.java b/plugins/velocity/src/main/java/org/apache/struts2/views/velocity/VelocityManager.java index cc4a20057..2b06e84bc 100644 --- a/plugins/velocity/src/main/java/org/apache/struts2/views/velocity/VelocityManager.java +++ b/plugins/velocity/src/main/java/org/apache/struts2/views/velocity/VelocityManager.java @@ -22,10 +22,12 @@ import com.opensymphony.xwork2.ObjectFactory; import com.opensymphony.xwork2.inject.Container; import com.opensymphony.xwork2.inject.Inject; import com.opensymphony.xwork2.util.ValueStack; +import jakarta.servlet.ServletContext; +import jakarta.servlet.http.HttpServletRequest; +import jakarta.servlet.http.HttpServletResponse; import org.apache.commons.lang3.StringUtils; import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; -import org.apache.struts2.ServletActionContext; import org.apache.struts2.StrutsConstants; import org.apache.struts2.StrutsException; import org.apache.struts2.views.TagLibraryDirectiveProvider; @@ -34,13 +36,7 @@ import org.apache.velocity.VelocityContext; import org.apache.velocity.app.Velocity; import org.apache.velocity.app.VelocityEngine; import org.apache.velocity.context.Context; -import org.apache.velocity.tools.ToolContext; -import org.apache.velocity.tools.ToolManager; -import org.apache.velocity.tools.ToolboxFactory; -import jakarta.servlet.ServletContext; -import jakarta.servlet.http.HttpServletRequest; -import jakarta.servlet.http.HttpServletResponse; import java.io.File; import java.io.FileInputStream; import java.io.IOException; @@ -48,16 +44,17 @@ import java.io.InputStream; import java.util.ArrayList; import java.util.Arrays; import java.util.Collection; -import java.util.Collections; import java.util.List; import java.util.Map; import java.util.Properties; -import static java.lang.String.format; import static java.util.Collections.emptyList; +import static java.util.Objects.requireNonNullElse; import static java.util.stream.Collectors.joining; import static java.util.stream.Collectors.toList; +import static org.apache.commons.lang3.StringUtils.isBlank; import static org.apache.struts2.views.util.ContextUtil.STRUTS; +import static org.apache.velocity.runtime.DeprecatedRuntimeConstants.OLD_CUSTOM_DIRECTIVES; /** * Manages the environment for Velocity result types @@ -72,11 +69,7 @@ public class VelocityManager implements VelocityManagerInterface { private VelocityEngine velocityEngine; -/** - * A reference to the toolbox manager. - */ -protected ToolManager toolboxManager = null; -private String toolBoxLocation; +private VelocityTools velocityTools; /** * Names of contexts that will be chained on every request @@ -96,9 +89,8 @@ public class VelocityManager implements VelocityManagerInterface { @Inject public void setContainer(Container container) { -List list = container.getInstanceNames(TagLibraryDirectiveProvider.class).stream() -.map(prefix -> container.getInstance(TagLibraryDirectiveProvider.class, prefix)).collect(toList()); -this.tagLibraries = Collections.unmodifiableList(list); +this.tagLibraries = container.getInst
(struts) branch 7.0.x/WW-5449-remove-vel-tools created (now db7dd7261)
This is an automated email from the ASF dual-hosted git repository. kusal pushed a change to branch 7.0.x/WW-5449-remove-vel-tools in repository https://gitbox.apache.org/repos/asf/struts.git at db7dd7261 WW-5449 Make Velocity Tools dependency optional for Velocity plugin This branch includes the following new commits: new db7dd7261 WW-5449 Make Velocity Tools dependency optional for Velocity plugin The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference.
(struts) branch 7.0.x/WW-5449-remove-vel-tools updated (db7dd7261 -> 015544abd)
This is an automated email from the ASF dual-hosted git repository. kusal pushed a change to branch 7.0.x/WW-5449-remove-vel-tools in repository https://gitbox.apache.org/repos/asf/struts.git discard db7dd7261 WW-5449 Make Velocity Tools dependency optional for Velocity plugin add 015544abd WW-5449 Make Velocity Tools dependency optional for Velocity plugin This update added new revisions after undoing existing revisions. That is to say, some revisions that were in the old version of the branch are not in the new version. This situation occurs when a user --force pushes a change and generates a repository containing something like this: * -- * -- B -- O -- O -- O (db7dd7261) \ N -- N -- N refs/heads/7.0.x/WW-5449-remove-vel-tools (015544abd) You should already have received notification emails for all of the O revisions, and so the following emails describe only the N revisions from the common base, B. Any revisions marked "omit" are not gone; other references still refer to them. Any revisions marked "discard" are gone forever. No new revisions were added by this update. Summary of changes: .../apache/struts2/views/velocity/VelocityTools.java | 18 ++ 1 file changed, 18 insertions(+)
(struts) branch 7.0.x/WW-5449-remove-vel-tools updated (015544abd -> ac860d3bb)
This is an automated email from the ASF dual-hosted git repository. kusal pushed a change to branch 7.0.x/WW-5449-remove-vel-tools in repository https://gitbox.apache.org/repos/asf/struts.git from 015544abd WW-5449 Make Velocity Tools dependency optional for Velocity plugin add 902dca06c WW-5449 Minor clean up add ac860d3bb WW-5449 Include Velocity Tools dependencies explicitly in Showcase app No new revisions were added by this update. Summary of changes: apps/showcase/pom.xml | 8 +++ .../struts2/views/velocity/VelocityManager.java| 25 +++--- 2 files changed, 20 insertions(+), 13 deletions(-)
(struts) branch 7.0.x/WW-5449-remove-vel-tools updated (ac860d3bb -> a0d34210f)
This is an automated email from the ASF dual-hosted git repository. kusal pushed a change to branch 7.0.x/WW-5449-remove-vel-tools in repository https://gitbox.apache.org/repos/asf/struts.git from ac860d3bb WW-5449 Include Velocity Tools dependencies explicitly in Showcase app add a0d34210f WW-5449 Increase coverage No new revisions were added by this update. Summary of changes: .../struts2/views/velocity/VelocityManager.java| 5 ++- .../views/velocity/VelocityManagerTest.java| 48 ++ .../src/test/resources/velocity.properties | 1 + 3 files changed, 45 insertions(+), 9 deletions(-) create mode 100644 plugins/velocity/src/test/resources/velocity.properties
(struts) branch 7.0.x/WW-5449-remove-vel-tools updated (a0d34210f -> b4b4f0079)
This is an automated email from the ASF dual-hosted git repository. kusal pushed a change to branch 7.0.x/WW-5449-remove-vel-tools in repository https://gitbox.apache.org/repos/asf/struts.git discard a0d34210f WW-5449 Increase coverage add b4b4f0079 WW-5449 Increase coverage This update added new revisions after undoing existing revisions. That is to say, some revisions that were in the old version of the branch are not in the new version. This situation occurs when a user --force pushes a change and generates a repository containing something like this: * -- * -- B -- O -- O -- O (a0d34210f) \ N -- N -- N refs/heads/7.0.x/WW-5449-remove-vel-tools (b4b4f0079) You should already have received notification emails for all of the O revisions, and so the following emails describe only the N revisions from the common base, B. Any revisions marked "omit" are not gone; other references still refer to them. Any revisions marked "discard" are gone forever. No new revisions were added by this update. Summary of changes: .../velocity/src/test/resources/velocity.properties | 19 +++ 1 file changed, 19 insertions(+)
(struts) branch 7.0.x/WW-5449-remove-vel-tools updated (b4b4f0079 -> ca358c57d)
This is an automated email from the ASF dual-hosted git repository. kusal pushed a change to branch 7.0.x/WW-5449-remove-vel-tools in repository https://gitbox.apache.org/repos/asf/struts.git omit b4b4f0079 WW-5449 Increase coverage add ca358c57d WW-5449 Increase coverage This update added new revisions after undoing existing revisions. That is to say, some revisions that were in the old version of the branch are not in the new version. This situation occurs when a user --force pushes a change and generates a repository containing something like this: * -- * -- B -- O -- O -- O (b4b4f0079) \ N -- N -- N refs/heads/7.0.x/WW-5449-remove-vel-tools (ca358c57d) You should already have received notification emails for all of the O revisions, and so the following emails describe only the N revisions from the common base, B. Any revisions marked "omit" are not gone; other references still refer to them. Any revisions marked "discard" are gone forever. No new revisions were added by this update. Summary of changes: .../struts2/views/velocity/VelocityManagerTest.java| 18 ++ .../webinf-velocity.properties}| 2 +- .../{velocity.properties => test-velocity.properties} | 0 3 files changed, 15 insertions(+), 5 deletions(-) copy plugins/velocity/src/test/resources/{velocity.properties => WEB-INF/webinf-velocity.properties} (98%) rename plugins/velocity/src/test/resources/{velocity.properties => test-velocity.properties} (100%)