How do I shut down the server and lock whole databse wih -1?
posted 15 years ago
I don't believe there is a requirement to have an implementation for the use of locking the entire database. My understanding is that it should only be available int the Data class. As for shut down on the server, I have heard others used ctrl-c, and I plan to do the same. One alternative is to have the server doing its main duties in a background thread while listening for user input on the command prompt. Having a user type quit could call for whatever shutdown processing is needed before exiting. Travis Zimmerman [ March 15, 2002: Message edited by: Travis Zimmerman ]
Harry, first Javaranch has a naming convention to have your user name be your first and last name. Secondly, there is a requirement to include the lock(-1) to lock the entire database. I would suggest creating a simple GUI to start your server, with a button or menuitem that shutsdown the server. In the action of that have the lock(-1) in the code along with close(). Mark