the redirection specs in your sitemap:
When you call the source
http://localhost:8080/Cocoontest/servlet/cocontest.Servlet2
cocoon probably does this by making a http:client call to that resource. This is definitely done in a separate session. What exactly do you
want to achieve? Couldn't this be done cheeper by passing parameters in the redirect of your Servlet1 to Servlet2 ?
regards, hussayn
CLAIS, Rene wrote:
I have seen this subject (Cocoon with Servlets) in a huge number of archive
Anyway no one can explain me how my problem can be solved (I do not find the right one !!)
The problem is : how can I retrieve java object in a cocoon session ?
My example:
I have a cocoon XLM / XSL showing a HTML page (That works !)
This HTML contains a form which call my Servlet1 (That works !)
<form action="Servlet1" method="post>
Your name: <input type="text" name="thename"/>
</form>
This Servlet1 make a senRedirect to ../Cocoon/servlet2 (Good that works)
the site map contains:
<map:pipeline> <map:match pattern="servlet2">
<map:generate src="http://localhost:8080/Cocoontest/servlet/cocontest.Servlet2"/>
<map:transform src="appl/servlet2.xsl"/>
<map:serialize/>
</map:match>
</map:pipeline>
The cocoontest.Servlet2 write a xml layout in the generator
this one is transformed by the "appl/servlet2.xsl"
and serialized in a HTML page.
All this stuff works well.
In my Servlet1 I put some attributes in the session:
HttpSession session = request.getSession();
session.setAttribute=("test","cocoon is great !!");
In my Servlet2 I get this attribute:
String value = (String) session.getAttribute("test");
This instruction return a null in the String value.
Does that means that the session of the first called servlet and the session of the second calling servlet are not the same ?
If no: ====> what is wrong ?
if yes: how can I put objects in session that can be retrieved by servlets writing in the Cocoon generator ?
Thanks a lot for advice and help
René Clais
-- Dr. Hussayn Dabbous SAXESS Software Design GmbH Neuenhöfer Allee 125 50935 Köln Telefon: +49-221-56011-0 Fax: +49-221-56011-20 E-Mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- Please check that your question has not already been answered in the FAQ before posting. <http://xml.apache.org/cocoon/faq/index.html> To unsubscribe, e-mail: <[EMAIL PROTECTED]> For additional commands, e-mail: <[EMAIL PROTECTED]>