Hi Jeff,
everything works fine nw. Thanks very much. Nearly all of my configuration
was perfectly all right in the beginning. The problem was - and still is in
some areas - that there is very few documentation for orion config-files and
their relationships. The solution:
default-web-site:
<web-app application="gamsytest" name="junitee-web"
root="/gamsytest" />
My EAR archive contains a WAR called junitee-web.war. I didn't realize, that
the name attribute in the web-app tag references the WAR filename.
After reading your mail I realized what was wrong. Thanks, again.
Hartmut
-----Ursprüngliche Nachricht-----
Von: Jeff Schnitzer [mailto:[EMAIL PROTECTED]]
Gesendet: Mittwoch, 17. Januar 2001 22:09
An: Orion-Interest
Betreff: RE: Servlet Mapping and Access
Have you successfully installed the sample junitee test in the JUnitEE
tutorial?
You shouldn't need to modify the global application.xml. Here's how my
system is set up, given that my ear contains two wars, "similarity-web"
and "similarity-test-web" (which contains my TestServlet and JUnit
tests):
server.xml:
<application name="similarity" path="../applications/similarity.ear" />
default-web-site:
<web-app application="similarity" name="similarity-web"
root="/similarity" />
<web-app application="similarity" name="similarity-test-web"
root="/test" />
similarity-web's web.xml:
<servlet>
<servlet-name> JUnitTestServlet </servlet-name>
<description> JUnit test harness </description>
<servlet-class> TestServlet </servlet-class>
</servlet>
<servlet-mapping>
<servlet-name> JUnitTestServlet </servlet-name>
<url-pattern> /TestServlet </url-pattern>
</servlet-mapping>
After this, I can access my test servlet as either
http://localhost/test/TestServlet or
http://localhost/test/servlet/TestServlet. The first because it's
configured in the web.xml, the second because all servlets in the
WEB-INF/classes directory of the war are exported as under the fairly
standard path "<root>/servlet" (it can be configured in the
global-web-application.xml).
I'm a little confused by what you posted, but assuming that your normal
web application is in gamesytest-web.war and your tests are in
junitee-web.war, both packaged in "junitee-orion.ear", you should
configure junitee-web in the default-web-site and remove the reference
to it from the global application.xml.
Then you should be able to use either URL:
http://localhost/junitee/TestServlet
http://localhost/junitee/servlet/TestServlet
Jeff
>-----Original Message-----
>From: hartmut wilms [mailto:[EMAIL PROTECTED]]
>Sent: Wednesday, January 17, 2001 5:16 AM
>To: Orion-Interest
>Subject: AW: Servlet Mapping and Access
>
>
>Hi Santosh,
>
>http://localhost/junitee/servlet/TestServlet didn't work, too.
>Do you know
>about an orion servlet example?
>
>Bye
>
>Hartmut
>
>-----Ursprüngliche Nachricht-----
>Von: Santosh Kumar [mailto:[EMAIL PROTECTED]]
>Gesendet: Mittwoch, 17. Januar 2001 10:12
>An: Orion-Interest
>Betreff: Re: Servlet Mapping and Access
>
>
>try http://localhost/junitee/servlet/TestServlet
>
>----- Original Message -----
>From: hartmut wilms <[EMAIL PROTECTED]>
>To: Orion-Interest <[EMAIL PROTECTED]>
>Sent: Wednesday, January 17, 2001 2:17 PM
>Subject: Servlet Mapping and Access
>
>
>> Hi there,
>>
>> I'm really lost. I can't figure out how to access a mapped
>servlet from a
>> Web-Browser. I tried several URLs, like:
>>
>> - http://localhost/gamsytest/TestServlet
>> - http://localhost/gamsytest/junitee/TestServlet
>> - http://localhost/junitee/TestServlet
>> - ...
>>
>> Accessing JSPs in the example applications works fine. My
>problem is that
>I
>> don't understand the relationships between all the orion xml
>> configuration/descriptor files. I know that they are documented, but
>> sometimes some pieces are missing or I don't get enough
>information. After
>> all I'm a Newbie to Orion.
>>
>> My configuration:
>>
>> server.xml
>> ...
>> <application name="gamsytest"
>>
>> path="../applications/junitee-orion.ear" />
>> ...
>>
>> default-web-site.xml
>> ...
>> <web-app application="gamsytest" name="gamsytest-web"
>> root="/gamsytest" />
>> ...
>>
>> ??? What values are expected for name and root?
>>
>> web.xml
>> ...
>> <servlet>
>> <servlet-name>TestServlet</servlet-name>
>> <description>Servlet that calls the TestRunner
>bean</description>
>>
>>
><servlet-class>com.itellium.aeservices.junit.htmlui.TestServlet
></servlet-cla
>> ss>
>> </servlet>
>> <servlet-mapping>
>> <servlet-name>TestServlet</servlet-name>
>> <url-pattern>/TestServlet</url-pattern>
>> </servlet-mapping>
>> ...
>>
>> application.xml
>> ...
>> <module>
>> <web>
>> <web-uri>junitee-web.war</web-uri>
>> <context-root>/junitee</context-root>
>> </web>
>> </module>
>> ...
>>
>> What are the relationships between all these name/mapping
>attributes. I
>used
>> the web.xml and application.xml with jBOSS and WebLogic
>without having any
>> problems:
>>
>> http://.../junitee/TestServlet WORKED!
>>
>> Can anybody help me and explain the orion way?
>>
>> Regards
>>
>> Hartmut Wilms
>>
>>
>>
>
>
>