Forums Register Login

how to call one servlet from other servlet

+Pie Number of slices to send: Send
there is one servlet runnin in the application which gets some data and
send to another servlet to process it and return that data back.

so how do i do this...


thanxz in advance





[BS: removed "urgent" from the subject]
[ January 17, 2006: Message edited by: Ben Souther ]
+Pie Number of slices to send: Send
You can make use of ServletRequestDispatcher to forward request to the 2nd servlet.
http://home.earthlink.net/~alxdark/software/wcd-guide/ch01s06.html
+Pie Number of slices to send: Send
jaspal,

Please read the following page to find out why putting "urgent" in your subject heading will actually slow down responses to your question:
http://faq.javaranch.com/view?EaseUp
+Pie Number of slices to send: Send
A better design might be to refactor the other servlet so that you can instantiate it as a class, and then call the methods of that class, instead of trying to pass parameters and get results the HTTP way, when it is should be a local call.
+Pie Number of slices to send: Send
 

Please read the following page to find out why putting "urgent" in your subject heading will actually slow down responses to your question:



oh! big sorry for that.

thanx for getting me aware of the fact.
When evil is afoot and you don't have any arms you gotta be hip and do the legwork, but always kick some ... tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 846 times.
Similar Threads
Dependatable fields on
drawing graphs
j2me servlet communication
validation in servlet for jsp form
Midlet problem! Any help appreciated.
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 29, 2024 09:53:51.