Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Design issue with Server

 
Reshma Das
Ranch Hand
Posts: 125
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do I need a server when running in local mode ?
When client selects Remote option and server is down we have to show a message to client or start the server remotely ? any suggestions.
Any advantage of using server for both local/remote mode ?
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No server needed in Local mode.
If the server is down, I'd show a message. You can't have the client start up a remote server. Imagine if I run MS Word, and becuase I can't type I can restart Microsofts Web Server. Not really good security. But then again I am talking about Microsoft, Mr. Security himself
Local mode should not have a server. That is why they have you do local and remote, to see if you can make a Client/Server and a stand-alone program.
Besides the client won't have the server files on that machine. Meaning in the client.jar file.
Hope that I wrote that understandable, I sometimes babble when I write and it makes no sense.
Mark
 
Reshma Das
Ranch Hand
Posts: 125
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I got it. I have a problem with interfaces.
interface A {
}
interface B extends A {
public methods of Data
}
interface C extends A,Remote {
public methods of Data throws RemoteException
}
class Data implements B {
...
}
class server implements C {
}
class client {
A a;
clein() {
if (local)
a = new Data();
else
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I only have Interface A extends Remote, all the methods threw Exception, then I had
class BLocal implements A methods threw Exception or DatabaseException
class CRemote extends UnicastRemoteObject implements A, Unreferenced in this class all methods threw RemoteException and some also threw databaseExceptions
Hope that helps some more
Mark
[ January 30, 2002: Message edited by: Mark Spritzler ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic