Re: Determine Servlet Name

Kazuhito SUGURI <[email protected]>
Newsgroups gmane.comp.jakarta.cactus.user
Message-ID <[email protected]>
Hi Perry,

In article <481100825.1155052507694.JavaMail.root@fepweb09>,
Tue, 8 Aug 2006 10:55:07 -0500,
<[email protected]> wrote: 
dutchman_mn> Is there a cactus mailing list archive and failing that,
dutchman_mn> how does Cactus determine the servlet to test.
dutchman_mn> If I have a method called testFooAction and the servlet mapping is
dutchman_mn> /fooAction, how does Cactus determin to have the ServletRedirector
dutchman_mn> determine fooAction?  I tried looked at the source code but
dutchman_mn> could not determine it.

ServletRedirector does not refer servlet-mapping for its execution.
Information that is needed for execution of a test,
such as test class and method names, is transmitted from the client-side
of the Cactus framework as a set of HTTP parameter.


In article <795604853.1155221901522.JavaMail.root@fepweb01>,
Thu, 10 Aug 2006 9:58:21 -0500,
<[email protected]> wrote: 
dutchman_mn> My question revolves around the DefaultHttpClient class.
dutchman_mn> Looking at the source, I see within the callRunTest method
dutchman_mn> the following method:
dutchman_mn> 
dutchman_mn> // Specify the service to call on the redirector side
dutchman_mn> theRequest.addParameter(HttpServiceDefinition.SERVICE_NAME_PARAM,
dutchman_mn>       ServiceEnumeration.CALL_TEST_SERVICE.toString(),
dutchman_mn>        WebRequest.GET_METHOD);

This is a part of the parameter set.

This parameter directs the service that ServletRedirector should provide
to the client-side, such as CALL_TEST, GET_RESULTS.
As the test execution sequence is determined, the client-side of
the framework can determine specific service suitable for the state.
Please take a look at http://jakarta.apache.org/cactus/how_it_works.html


dutchman_mn> My question is, how does cactus determine the service name of
dutchman_mn> the servlet under test?

If you mean "servlet-name and its mapping definition in web.xml"
by "the service name of the servlet", the answer is:
	Cactus doesn't determine that. (or Cactus doesn't care of that.)

If you mean something different, please let us know.

Best Regards,
----
Kazuhito SUGURI
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.