[ 
https://issues.apache.org/struts/browse/WW-1679?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Don Brown resolved WW-1679.
---------------------------

    Resolution: Fixed
      Assignee: Don Brown

Fixed, and thanks a ton for the example application.   It really helped to run 
this one down.

> global-results not inherited when using zero config
> ---------------------------------------------------
>
>                 Key: WW-1679
>                 URL: https://issues.apache.org/struts/browse/WW-1679
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Configuration
>    Affects Versions: 2.0.4
>            Reporter: Nate Drake
>         Assigned To: Don Brown
>            Priority: Critical
>             Fix For: 2.0.5
>
>         Attachments: struts2-blank.war
>
>
> Using the latest Struts 2 trunk code, it seems that zero-configged Action 
> classes don't get access to global-results defined in parent packages.
> See attached war for an example of this issue.  In this war, 
> example.annotated.AnnotationAction is annotated like so:
> @ParentPackage("tmpPkg")
> @Namespace("")
> @Results({
>     @Result(name="l3", value="/example/Login.jsp")
> })
> The parent package, tmpPkg, is setup like this:
>     <package name="tmpPkg" extends="example">
>         <global-results>
>             <result name="l2">/example/Login.jsp</result>
>         </global-results>
>     </package>
> tmpPkg's parent package, example, has the following global-results defined:
> <global-results>
>     <result name="l1">/example/Login.jsp</result>            
>     <result name="hello">/example/HelloWorld.jsp</result> 
> </global-results>
> To demonstrate this problem, you can pass the AnnotationAction the "res" 
> request parameter.  If the value is "local" the action will return the 
> locally defined (via @Result) result.  This case works.  If the value is 
> "parent", the action will return tmpPkg's "l2" result.  If the value is 
> "parentparent", the action will return the example package's "l1" results.  
> The latter two cases don't work, and result in the following error:
> No result defined for action example.annotated.AnnotationAction and result l1

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to