You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@struts.apache.org by "Michael Menzies (JIRA)" <ji...@apache.org> on 2012/05/14 17:19:53 UTC

[jira] [Created] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Michael Menzies created WW-3815:
-----------------------------------

             Summary: Dispatching after action phase renders with different stack/TextProvider
                 Key: WW-3815
                 URL: https://issues.apache.org/jira/browse/WW-3815
             Project: Struts 2
          Issue Type: Bug
          Components: Plugin - Portlet
    Affects Versions: 2.3.3
            Reporter: Michael Menzies
            Priority: Minor


This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.

The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.

This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.

Unless there is a reason for the change, this is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);

I had created a stackoverflow question that explains the issue in detail.

http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13277750#comment-13277750 ] 

Michael Menzies commented on WW-3815:
-------------------------------------

I tried the new StrutsTestCase, same thing. The phase is still null. This does not occur when using the release portlet plugin.
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Lukasz Lenart (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13280069#comment-13280069 ] 

Lukasz Lenart commented on WW-3815:
-----------------------------------

ech... a bit confused ... what should be changed in the latest version to work with your tests ? I think getMajorVersion() should be exposed to be set from tests ? right ?
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13277757#comment-13277757 ] 

Michael Menzies commented on WW-3815:
-------------------------------------

I just set the phase to event in the context. Fix a few tests, but I'm still getting a lot of errors. One of the interesting things I noticed is that I had a npe in PortletResultHelperJSR286. This is because our app is using the portlet 1.0 api because our portal environment doesn't support the new spec.
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Menzies updated WW-3815:
--------------------------------

    Description: 
This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.

The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.

This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.

Unless there is a reason for the change, this is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);

I had created a stackoverflow question that explains the issue in detail.

http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac

Original bug:
https://issues.apache.org/jira/browse/WW-2720


  was:
This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.

The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.

This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.

Unless there is a reason for the change, this is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);

I had created a stackoverflow question that explains the issue in detail.

http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac


    
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Priority: Minor
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, this is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13281058#comment-13281058 ] 

Michael Menzies commented on WW-3815:
-------------------------------------

I could definitely register a new ticket. Exposing the getMajorVersion() seems like a good idea. MockPortletContext is actually apart of the spring framework. Sooo... I'd create a ticket in the Spring jira then?
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13277136#comment-13277136 ] 

Michael Menzies commented on WW-3815:
-------------------------------------

It works when I deploy it... but the new snapshot breaks all of my action unit tests. I get a NPE on line 49:

48		PortletPhase phase = (PortletPhase) invocation.getInvocationContext().get(PortletConstants.PHASE);
49		if (phase.isRender()) {

The phase isn't in the context. Any ideas guys? The intercept method has been changed in the snapshot from the release version.

Where does the phase get put into the context?
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Lukasz Lenart (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13276491#comment-13276491 ] 

Lukasz Lenart commented on WW-3815:
-----------------------------------

I've checked the repository, the latest snapshot 2.3.5 was uploaded at 4.34 PM (GMT+2), please try again.
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13277832#comment-13277832 ] 

Michael Menzies commented on WW-3815:
-------------------------------------

I got all my tests passing. I reverted back to the release struts junit plugin, and just mocked dependencies as needed.
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Lukasz Lenart (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13280070#comment-13280070 ] 

Lukasz Lenart commented on WW-3815:
-----------------------------------

Or better, register a new ticket for that
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Lukasz Lenart (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13277678#comment-13277678 ] 

Lukasz Lenart commented on WW-3815:
-----------------------------------

Does your action unit test extend StrutsTestCase? I've added a code to initialize PortletContext if portlet dependency are available.
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Lukasz Lenart (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13281165#comment-13281165 ] 

Lukasz Lenart commented on WW-3815:
-----------------------------------

You can but I think you can do the same for StrutsTestCase and it'll be faster ;-)
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Assigned] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Johannes Geppert (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Johannes Geppert reassigned WW-3815:
------------------------------------

    Assignee: Johannes Geppert
    
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13277764#comment-13277764 ] 

Michael Menzies commented on WW-3815:
-------------------------------------

Oh! Because you set the PortletContext in the StrutsTestCase, it assumes jsr268.

In PortletActionContext:

    public static boolean isJSR268Supported() {
        PortletContext ctx = getPortletContext();
        if (ctx == null) {
            return false; // fallback to old behaviour, check WW-3763
        }
        return ctx.getMajorVersion() > 1;
    }
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Menzies updated WW-3815:
--------------------------------

    Description: 
This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.

The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.

This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.

Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);

I had created a stackoverflow question that explains the issue in detail.

http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac

Original bug:
https://issues.apache.org/jira/browse/WW-2720


  was:
This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.

The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.

This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.

Unless there is a reason for the change, this is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);

I had created a stackoverflow question that explains the issue in detail.

http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac

Original bug:
https://issues.apache.org/jira/browse/WW-2720


    
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Priority: Minor
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Comment Edited] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13277764#comment-13277764 ] 

Michael Menzies edited comment on WW-3815 at 5/17/12 12:51 PM:
---------------------------------------------------------------

Oh! Because you set the PortletContext in the StrutsTestCase, it assumes jsr268.

In PortletActionContext:

    public static boolean isJSR268Supported() {
        PortletContext ctx = getPortletContext();
        if (ctx == null) {
            return false; // fallback to old behaviour, check WW-3763
        }
        return ctx.getMajorVersion() > 1;
    }

EDIT: Ah, I see that's your code. I read it in haste it seems. The reason it assumes jsr268 is in MockPortletContext:

	public int getMajorVersion() {
		return 2;
	}
                
      was (Author: glopal):
    Oh! Because you set the PortletContext in the StrutsTestCase, it assumes jsr268.

In PortletActionContext:

    public static boolean isJSR268Supported() {
        PortletContext ctx = getPortletContext();
        if (ctx == null) {
            return false; // fallback to old behaviour, check WW-3763
        }
        return ctx.getMajorVersion() > 1;
    }
                  
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Comment Edited] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13277757#comment-13277757 ] 

Michael Menzies edited comment on WW-3815 at 5/17/12 12:35 PM:
---------------------------------------------------------------

I just set the phase to event in the context. Fixed a few tests, but I'm still getting a lot of errors. One of the interesting things I noticed is that I had a npe in PortletResultHelperJSR286. This is because our app is using the portlet 1.0 api because our portal environment doesn't support the new spec.
                
      was (Author: glopal):
    I just set the phase to event in the context. Fix a few tests, but I'm still getting a lot of errors. One of the interesting things I noticed is that I had a npe in PortletResultHelperJSR286. This is because our app is using the portlet 1.0 api because our portal environment doesn't support the new spec.
                  
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13276818#comment-13276818 ] 

Michael Menzies commented on WW-3815:
-------------------------------------

Ah, found it. Ya, the new snapshot does the trick. Thanks.
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WW-3815) Dispatching after action phase renders with different stack/TextProvider

Posted by "Michael Menzies (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WW-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13276094#comment-13276094 ] 

Michael Menzies commented on WW-3815:
-------------------------------------

I set my project to pull the LATEST snapshot of the plugin but I'm not seeing the change. I took a quick look at the trunk, and I see your change... but the snapshot I'm getting doesn't have it.
                
> Dispatching after action phase renders with different stack/TextProvider
> ------------------------------------------------------------------------
>
>                 Key: WW-3815
>                 URL: https://issues.apache.org/jira/browse/WW-3815
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Portlet
>    Affects Versions: 2.3.3
>            Reporter: Michael Menzies
>            Assignee: Johannes Geppert
>            Priority: Minor
>             Fix For: 2.3.5
>
>
> This is actually a rather old bug that was fixed in 2.1.3, but for some unknown reason the bug was reintroduced in 2.3.3.
> The PortletStateInterceptor merges the old stack with the current stack during the render stage. It should add the old root to the beginning of the current root. In 2.3.3 it now adds it to the end.
> This puts the DefaultTextProvider above the Action class, which breaks a bunch of struts tags if your action implements TextProvider.
> Unless there is a reason for the change, the simple fix is changing root.addAll(oldRoot); to root.addAll(0, oldRoot);
> I had created a stackoverflow question that explains the issue in detail.
> http://stackoverflow.com/questions/10557124/possible-struts-portlet-2-3-3-bug-action-class-not-at-the-top-of-the-value-stac
> Original bug:
> https://issues.apache.org/jira/browse/WW-2720

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira