This is an automated email from the ASF dual-hosted git repository.

asf-gitbox-commits pushed a commit to branch asf-staging
in repository https://gitbox.apache.org/repos/asf/struts-site.git


The following commit(s) were added to refs/heads/asf-staging by this push:
     new 6a7bec251d Updates stage by Jenkins
6a7bec251d is described below

commit 6a7bec251dc74477f3ddaa781f43a1c219536a2f
Author: jenkins <[email protected]>
AuthorDate: Wed Oct 14 05:57:17 2026 +0000

    Updates stage by Jenkins
---
 content/core-developers/package-configuration.html |  3 +++
 content/plugins/convention/index.html              | 22 ++++++++++++++++++++++
 2 files changed, 25 insertions(+)

diff --git a/content/core-developers/package-configuration.html 
b/content/core-developers/package-configuration.html
index 7aab9f8de1..312e9b82ff 100644
--- a/content/core-developers/package-configuration.html
+++ b/content/core-developers/package-configuration.html
@@ -315,6 +315,9 @@ in <code class="language-plaintext 
highlighter-rouge">&lt;scoped-constant&gt;</c
 <a href="../tag-developers/selecting-template-directory">Selecting Template 
Directory</a></li>
 </ul>
 
+<p>The <a href="../plugins/convention/">Convention plugin</a> makes <code 
class="language-plaintext 
highlighter-rouge">struts.convention.result.path</code> scopable, see
+<a href="../plugins/convention/#result-path-per-package">Result path per 
package</a>.</p>
+
 <p>Plugins and your own application code can declare more, see <a 
href="#making-a-constant-scopable">Making a constant scopable</a>.</p>
 
 <p>The configuration is validated at startup, and loading fails when:</p>
diff --git a/content/plugins/convention/index.html 
b/content/plugins/convention/index.html
index 0fafcf1dfb..798b79da62 100644
--- a/content/plugins/convention/index.html
+++ b/content/plugins/convention/index.html
@@ -829,6 +829,28 @@ placed on an action class and also in the 
package-info.java file. Here is an exa
 
 <p>The result for this class will be located in <code 
class="language-plaintext highlighter-rouge">WEB-INF/jsps</code> rather than 
the default of <code class="language-plaintext 
highlighter-rouge">WEB-INF/content</code>.</p>
 
+<h4 id="result-path-per-package">Result path per package</h4>
+
+<p>Since Struts 7.5.0 a parent package can set the result path for all actions 
placed under it with a
+<a href="../../core-developers/package-configuration#scoped-constants">scoped 
constant</a>:</p>
+
+<div class="language-xml highlighter-rouge"><div class="highlight"><pre 
class="highlight"><code><span class="nt">&lt;package</span> <span 
class="na">name=</span><span class="s">"admin-base"</span> <span 
class="na">extends=</span><span class="s">"convention-default"</span><span 
class="nt">&gt;</span>
+    <span class="nt">&lt;scoped-constant</span> <span 
class="na">name=</span><span class="s">"struts.convention.result.path"</span> 
<span class="na">value=</span><span class="s">"/WEB-INF/admin/"</span><span 
class="nt">/&gt;</span>
+<span class="nt">&lt;/package&gt;</span>
+</code></pre></div></div>
+
+<p>Actions pick it up from the package they are placed under, chosen with 
<code class="language-plaintext 
highlighter-rouge">@ParentPackage("admin-base")</code> or
+<code class="language-plaintext 
highlighter-rouge">struts.convention.default.parent.package</code>. The result 
path of an action is taken from, in order:</p>
+
+<ol>
+  <li><code class="language-plaintext highlighter-rouge">@ResultPath</code> on 
the action class or its Java package</li>
+  <li>the <code class="language-plaintext 
highlighter-rouge">struts.convention.result.path</code> scoped constant of the 
action’s package, including inherited ones</li>
+  <li>the global <code class="language-plaintext 
highlighter-rouge">struts.convention.result.path</code> constant</li>
+</ol>
+
+<p>A request without an action class, served straight from a template, uses 
the scoped constant of the default
+parent package (<code class="language-plaintext 
highlighter-rouge">struts.convention.default.parent.package</code>).</p>
+
 <h3 id="parentpackage-annotation">ParentPackage annotation</h3>
 
 <p>The ParentPackage annotation allows applications to define different parent 
Struts package for specific action classes 

Reply via email to