|
![]() |
Originally posted by Albin Joseph:
Hi
You can use any type of protocol like FTP, SMTP with GenericServlet. But Sun is providing implementation only for HTTP protocol. So if you want to use FTP with servlet , then extend GenericServlet and provide the necessery implementations
Originally posted by Ben Souther:
You would need to learn all the ins and outs of that protocol and build a servlet container to handle it.
Originally posted by Jesper de Jong:
Ramesh, did you understand what Ulf and Ben explained?
It's not just a matter of extending GenericServlet. Normally, you have a servlet container that listens for HTTP (and HTTPS) requests. If an HTTP request is received, it calls your servlet.
If you want your servlet to be called when a client tries to contact the server via a different protocol (FTP, SMTP, whatever), you need to have server software that listens on the port for the protocol you want to use, and that software has to be able to call your servlet.
There's no ready-made server software available that can do this, so you would have to write it yourself. So it's not just a question of making your own SmtpServlet that subclasses GenericServlet.
Originally posted by Ramesh Chandra:
Hi Jesper,
Thanks for ur reply
Ur Explanation is very clear.
It would be more helpful if u can explain me say for an FTP protocol to be implemented by a servlet what all needs to be done i mean what are the additional classes or interfaces that are to be implemented or extended and other related stuff that needs to be done......![]()
Originally posted by Ramesh Chandra:
Thanks for ur reply
Ur Explanation is very clear.
It would be more helpful if u can explain me say for an FTP protocol to be implemented by a servlet what all needs to be done i mean what are the additional classes or interfaces that are to be implemented or extended and other related stuff that needs to be done......![]()
Yup, yup, yup. Tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
|