[ http://issues.apache.org/jira/browse/BEEHIVE-295?page=history ]

Jeremiah Johnson updated BEEHIVE-295:
-------------------------------------

    Attachment: BEEHIVE-295.tar

Here is a sample Web application that reproduces the output that I showed with 
the previous catalina.out.  I am going to attach a new catalina.out that is 
consistent with this application.  I created the new application because I 
wanted to ensure that my use of popups wasn't part of the cause of the 
exceptions I was seeing.

$ tar xf BEEHIVE-295.tar
$ cd BEEHIVE-295
$ ant -f 
/home/jjohnson/projects/beehive/build/dist/apache-beehive-incubating-svn-snapshot/ant/webappRuntimeCore.xml
 -Dwebapp.dir=/home/jjohnson/projects/BEEHIVE-295 deploy.beehive.webapp.runtime
$ ant -f 
/home/jjohnson/projects/beehive/build/dist/apache-beehive-incubating-svn-snapshot/ant/buildWebapp.xml
 -Dwebapp.dir=/home/jjohnson/projects/BEEHIVE-295 build
$ jar cf BEEHIVE-295.war *
$ mv BEEHIVE-295.war $CATALINA_HOME/webapps

When the Web application is deployed, go to the appropriate URL (i.e. 
http://localhost:8080/BEEHIVE-295/) and click the cancel button.  You should 
see the output with a couple RuntimeExceptions.

- jeremiah

> change button tag to prevent RuntimeException
> ---------------------------------------------
>
>          Key: BEEHIVE-295
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-295
>      Project: Beehive
>         Type: Wish
>   Components: NetUI
>  Environment: Beehive SVN / Tomcat 5.0.25
>     Reporter: Jeremiah Johnson
>     Assignee: Eddie O'Neil
>     Priority: Minor
>  Attachments: BEEHIVE-295.tar, catalina.out, log4j.xml
>
> If I use a button tag in a form to cancel and the action of that button 
> points to an action that doesn't declare a form bean, I get a 
> RuntimeException for every field in the form.  The exceptions seem harmless, 
> but I would rather not have the exception or have a single, specific 
> exception.
> I will attach the stack trace that I got using the following code:
> --- in the JSP
>          <netui:button type="submit" value="submit"/>
>          <netui:button action="cancel" type="submit" value="cancel"/>
>       </netui:form></p>
> ---
> --- in the controller
>       @Jpf.SimpleAction( name="cancel", returnAction="newProductCancel" )
>    }
> ---
> The obvious work-around (and probably correct use of the cancel action in 
> this case) work fine, so this isn't recorded as a bug against Beehive.
> --- the 'correct' controller code
> @Jpf.Action(
>    forwards={
>       @Jpf.Forward(name="success", returnAction="newProductCancel")
>    },
>    useFormBean="newProductForm"
> )
> protected Forward cancel( NewProductForm newProductForm ) {
>    return new Forward( "success" );
> }
> ---
> - jeremiah

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira

Reply via email to