You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Viraj Turakhia <vi...@gmail.com> on 2006/08/28 15:18:18 UTC

configuring Tomcat for protocols other than http/s

Hi all,
I am starting to work with Tomcat's code and have no clue where to start
from.
Any pointers would be very very helpful.

To start with, I would like to know whether Tomcat is configurable to work
with protocols other than http/https?
I want to configure Tomcat in such a way that it gives me RAW data that is
posted on given port.
Please let me know which server element is to be configured (and where..
server.xml?) such that forming request/response from RAW data is possible
for me.
This RAW data is not necessarily a http/https specific data. It could be
specific to any other protocol like ftp://.

Waiting for reply, thanks.

-- 
The first right of human is the right of EGO.
--
http://www.xperienceexperience.blogspot.com

Re: configuring Tomcat for protocols other than http/s

Posted by Viraj Turakhia <vi...@gmail.com>.
Hey Bill,
Thanks alot for this help of yours.

I will get back to you if I face problems in it.  :)

Viraj K. Turakhia

On 8/29/06, Bill Barker <wb...@wilshire.com> wrote:
>
> "Viraj Turakhia" <vi...@gmail.com> wrote in message
> news:f03059de0608280618h2082eac8mb7760b28b8533918@mail.gmail.com...
> > Hi all,
> > I am starting to work with Tomcat's code and have no clue where to start
> > from.
> > Any pointers would be very very helpful.
>
> Well, one method is to implement your own ProtocolHandler (
>
> http://tomcat.apache.org/tomcat-5.5-doc/catalina/docs/api/org/apache/coyote/ProtocolHandler.html
> ).
> This is responsible for setting up the Request and Response objects,
> threading, and handling sending and receiving data on the protocol.  It
> then
> hands off the Request and Response to the service method of the Adapter
> (
> http://tomcat.apache.org/tomcat-5.5-doc/catalina/docs/api/org/apache/coyote/Adapter.html
> )
> that Tomcat passed to it.  The MemoryProtocolHandler
> (
> http://tomcat.apache.org/tomcat-5.5-doc/catalina/docs/api/org/apache/coyote/memory/MemoryProtocolHandler.html
> )
> is the easiest if you want an example.  You'll probably also want to
> implement ActionHook
> (
> http://tomcat.apache.org/tomcat-5.5-doc/catalina/docs/api/org/apache/coyote/ActionHook.html
> )
> for best results.  You tell Tomcat to use yours via:
>   <Connector protocol="com.myfirm.mypackage.MyProtocolHandler" .... />
>
> >
> > To start with, I would like to know whether Tomcat is configurable to
> work
> > with protocols other than http/https?
>
> Well, it comes with AJP/1.3 support ;-).  However, the servlet container
> neutral to the protocol (that's the job of the ProtocolHandler :).
>
> > I want to configure Tomcat in such a way that it gives me RAW data that
> is
> > posted on given port.
> > Please let me know which server element is to be configured (and where..
> > server.xml?) such that forming request/response from RAW data is
> possible
> > for me.
> > This RAW data is not necessarily a http/https specific data. It could be
> > specific to any other protocol like ftp://.
> >
> > Waiting for reply, thanks.
> >
> > --
> > The first right of human is the right of EGO.
> > --
> > http://www.xperienceexperience.blogspot.com
> >
>
>
>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>


-- 
The first right of human is the right of EGO.
--
http://www.xperienceexperience.blogspot.com

Re: configuring Tomcat for protocols other than http/s

Posted by Bill Barker <wb...@wilshire.com>.
"Viraj Turakhia" <vi...@gmail.com> wrote in message 
news:f03059de0608280618h2082eac8mb7760b28b8533918@mail.gmail.com...
> Hi all,
> I am starting to work with Tomcat's code and have no clue where to start
> from.
> Any pointers would be very very helpful.

Well, one method is to implement your own ProtocolHandler ( 
http://tomcat.apache.org/tomcat-5.5-doc/catalina/docs/api/org/apache/coyote/ProtocolHandler.html). 
This is responsible for setting up the Request and Response objects, 
threading, and handling sending and receiving data on the protocol.  It then 
hands off the Request and Response to the service method of the Adapter 
(http://tomcat.apache.org/tomcat-5.5-doc/catalina/docs/api/org/apache/coyote/Adapter.html) 
that Tomcat passed to it.  The MemoryProtocolHandler 
(http://tomcat.apache.org/tomcat-5.5-doc/catalina/docs/api/org/apache/coyote/memory/MemoryProtocolHandler.html) 
is the easiest if you want an example.  You'll probably also want to 
implement ActionHook 
(http://tomcat.apache.org/tomcat-5.5-doc/catalina/docs/api/org/apache/coyote/ActionHook.html) 
for best results.  You tell Tomcat to use yours via:
  <Connector protocol="com.myfirm.mypackage.MyProtocolHandler" .... />

>
> To start with, I would like to know whether Tomcat is configurable to work
> with protocols other than http/https?

Well, it comes with AJP/1.3 support ;-).  However, the servlet container 
neutral to the protocol (that's the job of the ProtocolHandler :).

> I want to configure Tomcat in such a way that it gives me RAW data that is
> posted on given port.
> Please let me know which server element is to be configured (and where..
> server.xml?) such that forming request/response from RAW data is possible
> for me.
> This RAW data is not necessarily a http/https specific data. It could be
> specific to any other protocol like ftp://.
>
> Waiting for reply, thanks.
>
> -- 
> The first right of human is the right of EGO.
> --
> http://www.xperienceexperience.blogspot.com
> 




---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: configuring Tomcat for protocols other than http/s

Posted by Viraj Turakhia <vi...@gmail.com>.
Yeah.. you are write.
But actually I am planning to use Tomcat's servlet container's capability.

Viraj

On 8/28/06, Marc Farrow <ma...@gmail.com> wrote:
>
> Instead of goign through the over head of Tomcat, why not write your own
> custom port listener and implement whatever protocol you want?  You will
> know that the sender has to adhere to that protocol standard and you would
> adhere to same protocol as well..  Most protocols are just extensions of
> TCPIP.
>
> On 8/28/06, Viraj Turakhia <vi...@gmail.com> wrote:
> >
> > Hi all,
> > I am starting to work with Tomcat's code and have no clue where to start
> > from.
> > Any pointers would be very very helpful.
> >
> > To start with, I would like to know whether Tomcat is configurable to
> work
> > with protocols other than http/https?
> > I want to configure Tomcat in such a way that it gives me RAW data that
> is
> > posted on given port.
> > Please let me know which server element is to be configured (and where..
> > server.xml?) such that forming request/response from RAW data is
> possible
> > for me.
> > This RAW data is not necessarily a http/https specific data. It could be
> > specific to any other protocol like ftp://.
> >
> > Waiting for reply, thanks.
> >
> > --
> > The first right of human is the right of EGO.
> > --
> > http://www.xperienceexperience.blogspot.com
> >
> >
>
>
> --
> Marc Farrow
>
>


-- 
The first right of human is the right of EGO.
--
http://www.xperienceexperience.blogspot.com

Re: configuring Tomcat for protocols other than http/s

Posted by Marc Farrow <ma...@gmail.com>.
Instead of goign through the over head of Tomcat, why not write your own
custom port listener and implement whatever protocol you want?  You will
know that the sender has to adhere to that protocol standard and you would
adhere to same protocol as well..  Most protocols are just extensions of
TCPIP.

On 8/28/06, Viraj Turakhia <vi...@gmail.com> wrote:
>
> Hi all,
> I am starting to work with Tomcat's code and have no clue where to start
> from.
> Any pointers would be very very helpful.
>
> To start with, I would like to know whether Tomcat is configurable to work
> with protocols other than http/https?
> I want to configure Tomcat in such a way that it gives me RAW data that is
> posted on given port.
> Please let me know which server element is to be configured (and where..
> server.xml?) such that forming request/response from RAW data is possible
> for me.
> This RAW data is not necessarily a http/https specific data. It could be
> specific to any other protocol like ftp://.
>
> Waiting for reply, thanks.
>
> --
> The first right of human is the right of EGO.
> --
> http://www.xperienceexperience.blogspot.com
>
>


-- 
Marc Farrow