You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@beehive.apache.org by "Jeremiah Johnson (JIRA)" <be...@incubator.apache.org> on 2005/02/02 00:48:17 UTC

[jira] Updated: (BEEHIVE-228) Controller with JSPs behaving differently than Controller in WEB-INF/src.

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

Jeremiah Johnson updated BEEHIVE-228:
-------------------------------------

    Attachment: BEEHIVE-228.tar

Here are the steps that I would recommend for the attached file:
$ tar xf BEEHIVE-228.tar
$ cd BEEHIVE-228
$ ant -f /home/jjohnson/projects/beehive/build/dist/apache-beehive-incubating-svn-snapshot/ant/webappRuntimeCore.xml -Dwebapp.dir=/home/jjohnson/projects/BEEHIVE-228 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-228 build
$ jar cf BEEHIVE-228.war *
$ mv BEEHIVE-228.war $CATALINA_HOME/webapps 

The point your browser at http://localhost:8080/BEEHIVE-228/ and click on the links.

- jeremiah


> Controller with JSPs behaving differently than Controller in WEB-INF/src.
> -------------------------------------------------------------------------
>
>          Key: BEEHIVE-228
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-228
>      Project: Beehive
>         Type: Bug
>   Components: NetUI
>  Environment: I wrote the sample on Fedora Linux deploying to Tomcat 5.0.25.
>     Reporter: Jeremiah Johnson
>  Attachments: BEEHIVE-228.tar
>
> If I put Controller.jpf in the same directory as my JSP and specify Controller.jpf before index.jsp in the welcome-file-list of web.xml, then the begin action on Controller.jpf is used; on the other hand, if I put Controller.jpf or Controller.java in WEB-INF/src, then Controller.jpf if skipped over in the welcome-file-list.  I expected Controller.jpf to still be used.
> I will attach a sample application to demonstrate my concern.  Here is the structure of the file:
> index.jsp - just links to good and bad directories
> good/Controller.jpf - begin is simple action forwarding to nonindex.jsp
> good/index.jsp - this should not be seen as welcome because of welcome-file-list
> good/nonindex.jsp - should be what the user sees with URL of <contextRoot>/good/
> bad/index.jsp - this is the second option in the welcome-file-list
> bad/nonindex.jsp - this is what I expected to see based on my controller
> WEB-INF/web.xml - contains the welcome-file-list shown below
> WEB-INF/src/bad/Controller.jpf - same controller source as good/Controller.jpf
> The relevant contents of web.xml:
>     <welcome-file-list>
>         <welcome-file>Controller.jpf</welcome-file>
>         <welcome-file>index.jsp</welcome-file>
>     </welcome-file-list>
> - 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