Re: Seperate deployment in tomcat 6.0.29

Posted by Ilja Werner (psinova) on
URL: https://discuss.orbeon.com/Seperate-deployment-in-tomcat-6-0-29-tp3214139p3214974.html



-----Ursprüngliche Nachricht-----
Von: Ilja Werner (psinova) [mailto:[hidden email]]
Gesendet: Donnerstag, 13. Januar 2011 00:11
An: '[hidden email]'
Betreff: AW: [ops-users] Re: Seperate deployment in tomcat 6.0.29

Thanks a lot: I am replaying this on Windows.

At first. I do not understand point 2 completely, but let me describe my
phenomenon first.


Effects are
http://localhost:8080/mini_orbeon_test/xforms/view.xhtml shows the running
xform --> OK http://localhost:8080/mini_orbeon_test/xforms/ shows a white
screen http://localhost:8080/mini_orbeon_test/ shows an 404 error. -->
???????

What do I have to do the http://localhost:8080/mini_orbeon_test/ shows the
running xform. Do I need an epilogue? Or a redirecting index.html.

Honestly I do not understand the bootstrapping sequence in this scenario --
minimum I got a running xform but in an unexpected path.

Thanks for further hints. Ilja Werner

______________________________________________________-vvvvvvvvvvvvvvvvvvvvv
vvvvvvvvvvvvvvv-_______________________

Project structure is like the following with a xforms subdir.
____________________________________________________________________________
_____________________
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test>dir /S /B
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test\META-INF
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test\WEB-INF
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test\xforms
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test\META-INF\context.xml
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test\META-INF\MANIFEST.MF
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test\WEB-INF\classes
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test\WEB-INF\lib
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test\WEB-INF\web.xml
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test\WEB-INF\lib\orbeon-xfo
rms-filter.jar
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test\xforms\page-flow.xml
C:\Java\apache-tomcat-6.0.29\webapps\mini_orbeon_test\xforms\view.xhtml
____________________________________________________________________________
_____________________

I have the following web.xml
____________________________________________________________________________
_____________________
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
        xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
        id="WebApp_ID" version="2.5">
        <display-name>mini_orbeon_test</display-name>
        <welcome-file-list>
            <welcome-file>index.xhtml</welcome-file>
                <welcome-file>index.html</welcome-file>
                <welcome-file>index.htm</welcome-file>
                <welcome-file>index.jsp</welcome-file>
                <welcome-file>default.html</welcome-file>
                <welcome-file>default.htm</welcome-file>
                <welcome-file>default.jsp</welcome-file>
        </welcome-file-list>

        <!-- Declare and configure the Orbeon Forms XForms filter -->
        <filter>
                <filter-name>orbeon-xforms-filter</filter-name>

<filter-class>org.orbeon.oxf.servlet.OrbeonXFormsFilter</filter-class>
                <init-param>
                        <param-name>oxf.xforms.renderer.context</param-name>
                        <param-value>/orbeon</param-value>
                </init-param>
        </filter>
        <!-- Any web resource under /xforms-jsp is processed by the XForms
engine -->
        <filter-mapping>
                <filter-name>orbeon-xforms-filter</filter-name>
                <url-pattern>/xforms/*</url-pattern>
                <dispatcher>REQUEST</dispatcher>
                <dispatcher>FORWARD</dispatcher>
        </filter-mapping>
        <!-- This is necessary so that XForms engine resources can be served
appropriately -->
        <filter-mapping>
                <filter-name>orbeon-xforms-filter</filter-name>
                <url-pattern>/orbeon/*</url-pattern>
                <dispatcher>REQUEST</dispatcher>
                <dispatcher>FORWARD</dispatcher>
        </filter-mapping>
</web-app>
____________________________________________________________________________
___________________

I deployed Orbeon as /orbeon not as Orbeon-CE.
I too like the auto-copy of META-INF context.xml to
catalina/localhost/<warname>.xml  as it works find in 6.0.29 My
META.INF/context.xml is very simple
____________________________________________________________________________
___________________
<Context crossContext="true">

</Context>

____________________________________________________________________________
___________________

The catalina/localhost/orbeon.xml is exactly the same.
____________________________________________________________________________
___________________
<Context crossContext="true">

</Context>

____________________________________________________________________________
___________________

-----Ursprüngliche Nachricht-----
Von: Tambet Matiisen [mailto:[hidden email]]
Gesendet: Mittwoch, 12. Januar 2011 17:26
An: [hidden email]
Betreff: [ops-users] Re: Seperate deployment in tomcat 6.0.29

Hi!

I spotted following problems with your configuration:
1. You only need view.html, page-flow.xml is redundant. Also the name of the
file can be anything, it is not restricted to view.xhtml.
2. This file should be in mini_orbeon_test directory, so the full path is
$TOMCAT_HOME/webapps/mini_orbeon_test/mini_orbeon_test/. You could rename
the path in first filter-mapping into something more sensible, for example
/xforms/*, then the directory where you put XForms files is
$TOMCAT_HOME/webapps/mini_orbeon_test/xforms/ and this should be accessible
from http://localhost:8080/mini_orbeon_test/xforms/file.xhtml.
3. I haven't used META-INF/context.xml myself, although it appears to be a
legal configration. You could also try to move that file into
catalina/localhost and rename it to the same as context name.
4. I experienced problems with Orbeon context being anything other than
/orbeon. Most of the code works, but paths of some images in Javascript
required context named /orbeon.

Hope this helps.

   Tambet

On 12.01.2011 17:05, hospbene wrote:

> We created a simple dynamic webproject containing the page-flow.xml
> and a view.xhtml (the xforms-hello example).
>
> The web.xml looks as follows:
>
> <?xml version="1.0" encoding="UTF-8"?> <web-app
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns="http://java.sun.com/xml/ns/javaee"
> xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
> http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" id="WebApp_ID"
> version="3.0">
>    <display-name>mini_orbeon_test</display-name>
>    <welcome-file-list>
>      <welcome-file>index.html</welcome-file>
>      <welcome-file>index.htm</welcome-file>
>      <welcome-file>index.jsp</welcome-file>
>      <welcome-file>default.html</welcome-file>
>      <welcome-file>default.htm</welcome-file>
>      <welcome-file>default.jsp</welcome-file>
>    </welcome-file-list>
>
> <!-- Declare and configure the Orbeon Forms XForms filter -->
> <filter>
> <filter-name>orbeon-xforms-filter</filter-name>
>
<filter-class>org.orbeon.oxf.servlet.OrbeonXFormsFilter</filter-class>

> <init-param>
> <param-name>oxf.xforms.renderer.context</param-name>
> <param-value>/orbeon-CE</param-value>
> </init-param>
> </filter>
> <!-- Any web resource under /xforms-jsp is processed by the XForms
> engine
> -->
> <filter-mapping>
> <filter-name>orbeon-xforms-filter</filter-name>
> <url-pattern>/mini_orbeon_test/*</url-pattern>
> <dispatcher>REQUEST</dispatcher>
> <dispatcher>FORWARD</dispatcher>
> </filter-mapping>
> <!-- This is necessary so that XForms engine resources can be served

> appropriately -->
> <filter-mapping>
> <filter-name>orbeon-xforms-filter</filter-name>
> <url-pattern>/orbeon-CE/*</url-pattern>
> <dispatcher>REQUEST</dispatcher>
> <dispatcher>FORWARD</dispatcher>
> </filter-mapping>
> </web-app>
>
>
> Then we created a context.xml in the META-INF directory:
>
>   <Context path="/mini_orbeon_test"
>      docBase="mini_orbeon_test.war"
>      crossContext="true"></Context>
>
>
> Then we created a orbeon-CE.xml in catalina/localhost:
>
>   <Context path="/orbeon-CE"
>      docBase="orbeon-CE.war"
>      crossContext="true"></Context>
>
> We copied the "orbeon-xforms-filter.jar" into the WEB-INF/lib of the
> "mini_orbeon_test"-Project.
> The project looks like:
>
>
> META-INF WEB-INF page-flow.xml view.xhtml
>
> ./META-INF:
> MANIFEST.MF context.xml
>
> ./WEB-INF:
> classes lib web.xml
>
> ./WEB-INF/classes:
>
> ./WEB-INF/lib:
> orbeon-xforms-filter.jar
>
>
> The deployment of both war-Files was successfull.
> What did we do wrong. the webapp is neither reachable under
>
> localhost:8080/mini_orbeon_test
> nor under
>
> localhost:8080/orbeon-CE/mini_orbeon_test
>
>
> Any hints are welcome. THX
>




--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws