creating custom protocol handler

Hi all java's guru I hope that you guys can help me. I,ve been trying to develop custom protocol handler that handles this kind of url:

jdbc://driver_type/database_url/statement

I have override the URLConnection class but i get confused where to set the input stream and output stream.

Your guys help will be really appreciated.

Thanks in advance

[378 byte] By [satoto01a] at [2007-11-27 6:09:33]
# 1
> I,ve been trying to develop custom protocol handler> that handles this kind of url:> jdbc://driver_type/database_url/statementfirst, why?do you intend to write a client or server? by handler i assume server but what is the client?
developer_jbsa at 2007-7-12 17:13:34 > top of Java-index,Core,Core APIs...
# 2

> Hi all java's guru I hope that you guys can help me.

> I,ve been trying to develop custom protocol handler

> that handles this kind of url:

> jdbc://driver_type/database_url/statement

Is that supposed to be a JDBC url? Because it is invalid, or at least unlike any I have ever seen.

cotton.ma at 2007-7-12 17:13:34 > top of Java-index,Core,Core APIs...
# 3

Well I've been busy implementing Thinkfree application server(online office applet). I have succeeded implementing webdav protocol(it's not that difficult since webdav works also via http) Now I'm trying to develop custom file object that getting his inputstream and outputstream from and into the database. Because database connection in java only possible via jdbc so I have to write my own URLStreamHandler and URLConnection class. Does anybody has experience in developing a custom protocol handler? any advice will be appreciated

satoto01a at 2007-7-12 17:13:34 > top of Java-index,Core,Core APIs...
# 4

> Well I've been busy implementing Thinkfree

> application server(online office applet). I have

> succeeded implementing webdav protocol(it's not that

> difficult since webdav works also via http) Now I'm

> trying to develop custom file object that getting his

> inputstream and outputstream from and into the

> database. Because database connection in java only

> possible via jdbc so I have to write my own

> URLStreamHandler and URLConnection class. Does

> anybody has experience in developing a custom

> protocol handler? any advice will be appreciated

Are you aware that the actual protocol used for communication to a database is totally proprietary? As in it depends on the database?

Could you describe how you think this will work exactly? Because you can't just write a one-size fits all solution here. It just does not exist. And I am not too sure what you mean by the input and output streams from and into the database mean.

cotton.ma at 2007-7-12 17:13:34 > top of Java-index,Core,Core APIs...
# 5
From now on I've been creating jdbc URLConnection class(mysql as default sub protocol ) with this url jdbc://mysql/localhost/database_name/file_name/ and I allready get the content from the database as inputstream.I'm close....
satoto01a at 2007-7-12 17:13:34 > top of Java-index,Core,Core APIs...