aspose file tools*
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes Using Socket Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "Using Socket" Watch "Using Socket" New topic
Author

Using Socket

James Lee
Greenhorn

Joined: Nov 24, 2002
Posts: 11
I have read my topic discussing usage of RMI. Actaully, is there's anyone using socket instead? Why RMI is so popularly be used?
In my design, running of ther server side only need to use command-line instruction. Is any GUI required for the server side?
Peter den Haan
author
Ranch Hand

Joined: Apr 20, 2000
Posts: 3252
Originally posted by James Lee:
I have read my topic discussing usage of RMI. Actaully, is there's anyone using socket instead? Why RMI is so popularly be used?
Very few opt for sockets. My assessment at the time was that, if you would choose to use sockets, you would find yourself essentially doing all the things that RMI does for you. And a good programmer is a lazy programmer
In my design, running of ther server side only need to use command-line instruction. Is any GUI required for the server side?
You don't need a server-side GUI. In fact I think it's a positively bad idea -- in the real world, server applications often run on Unix servers that do not necessarily have a graphical (X11) display.
In fact I personally have had lots of of grief with a (non-Java) server application that insisted on having an X11 server to talk to. For some reason a dummy X11 server would not build on the machine, so we used an X11 terminal. Whenever anyone switched it off, deliberately or by bumping into it, the whole back-end would go down with it. The whole miserable episode was concluded only when we shoved a graphics card in the server. Grrrrr.
But that is entirely by the by Peter's tip for the day is: if your server does not absolutely need a GUI, make sure that it supports GUI-less operation.
- Peter
James Lee
Greenhorn

Joined: Nov 24, 2002
Posts: 11
THX for your opinion
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Using Socket