Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / January 2007

Tip: Looking for answers? Try searching our database.

RMI i WebService - why this way?

Thread view: 
Raveman - 23 Jan 2007 21:22 GMT
I just played with WebService in jdk6 and i dont understand why its like
rmi - I have to generate classes. why they were able to make ejb3 simple,
but this @WebService annotation needs all this generated classes. Maybe
because it uses rmi, why rmi is that way ? from what i know its just a
server that sends/receive serialized objects. I remember i wrote webserver
once in java and i havent used code generation. Shouldnt they just make a
higher level of abstraction? Please tell me. They make everything simpler,
but rmi will never change and everybody is ok with that.
Manish Pandit - 23 Jan 2007 23:34 GMT
> I just played with WebService in jdk6 and i dont understand why its like
> rmi - I have to generate classes. why they were able to make ejb3 simple,
[quoted text clipped - 4 lines]
> higher level of abstraction? Please tell me. They make everything simpler,
> but rmi will never change and everybody is ok with that.

I hope I understood your question right - For remote invocations, be it
a Remote Object or a Web service, you'd need client stubs. The client
stubs act as a "proxy" and actually make the remote call, giving your
code the impression that the call is local.

The difference between RMI and Webservices, in this case, would be that
RMI uses JRMP, a binary protocol to invoke remote methods, while
WebServices (as a standard practice) use SOAP over HTTP, which is a
text-based protocol. SOAP attachments can be used to give a binary
flavor, but in and of itself, SOAP/HTTP is text.

-cheers,
Manish
Raveman - 24 Jan 2007 03:39 GMT
>> I just played with WebService in jdk6 and i dont understand why its like
>> rmi - I have to generate classes. why they were able to make ejb3 simple,
[quoted text clipped - 17 lines]
> text-based protocol. SOAP attachments can be used to give a binary
> flavor, but in and of itself, SOAP/HTTP is text.
By why generate subs and not just use jdk dynamic proxy or some hand written
proxy? Is rmi really impossible without code generation?


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.