• Post Reply Bookmark Topic Watch Topic
  • New Topic

problem with RMI - SCJD  RSS feed

 
Hewerton Silva
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Develop communication with RMI, I am doing tests, I start the server and ok:



After that the server is started, and can do consultations by the network.
But how do you "turn off" the server, cut the communication?



but it did not work, I turn off after receiving a response such as: "connection refused" or something.

Thanks.

 
Anne Crace
Ranch Hand
Posts: 223
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm not quite sure what you mean here, but my server is a GUI. I have an Exit button. I call System.exit(0); I have JFrame.EXIT_ON_CLOSE for the red X in the upper right hand corner. I'm thinking you might be over-complicating this.
 
Ulises Pulido
Ranch Hand
Posts: 81
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am having a problem like this one, what you mean is that you leave the server running as a GUI even when there is nothing inside the frame or you just pust a message saying "The server is running, close the window to shut down it", from an user perspective is this correct ? From a developer perspective this would make our life easier I believe
 
Anne Crace
Ranch Hand
Posts: 223
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That's about how it is, Ulises. Mine is pretty similar to the one in Andrew's book. It displays "Server is Running" on a successful startup and connection to the data file. Server Gui not up, client throws an exception.
 
K. Tsang
Bartender
Posts: 3639
16
Firefox Browser Java Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I like the GUI approach to doing the server. You can also display the thread connecting to the server indicating there are multiple clients connected.
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!