Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Clarification of operating mode

 
Steve Granton
Ranch Hand
Posts: 200
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I'm new to the forum so apologies if this question has already been asked/answered.
The specification requires that the program should be able to be run in non-networked mode as well as networked mode - so that the database and GUI run in the same VM.
Should other clients running in other VM's be able to connect to the database while its running in the same VM as a client GUI?
My thoughts are that if run in 'non-networked' mode only one client can connect - the client in the same VM. Is this correct?
Cheers,
Steve
 
HenkGijsbert
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Steve,
I thought about the same question and decided that, since it is not explicitly required, not to register an rmi server when I am running in 'single VM-mode.
regards,
Henk
 
Steve Granton
Ranch Hand
Posts: 200
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks,
I think I'll go along with that.
Cheers,
Steve
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When in local mode the data only resides on the clients machine and there is no RMI, therefore other clients wouldn't be able to connect to that version of the db.db file. You will include the Data classes and db.db file in both the local version and the network version. Think of the program as two versions. one stand-alone(local) the other as a network(remote). In stand-alone(local) there is no server.
As far as asking questions, I am pretty sure most questions have been asked before, so don't worry about posting anything that has been asked before. I asked all the same questions too.
One thing that is really cool about this forum, is that you can do a search on the forum and find all the responses to similar questions and therefore get a good cross-section of answers.
Mark
 
James Hook
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just been reading the above thread, and just wanted to confirm..
If the user chooses to operate in local mode then the user could, potentially, be viewing data from the same db.db file as clients operating in network mode. It is not necessary to ensure concurrency in this situation??
 
Jim Yingst
Wanderer
Sheriff
Posts: 18671
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check your instructions carefully. For my assignment, it says that in non-networked mode the network server code must not be used at all. So there's no way that my DB instance can be accessed by any networked clients at the same time. And elsewhere I'm told I can assume no other programs will be accessing the DB file at the same time. So there's no way another client can access the same DB file. Your assignment may be different, however.
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"For my assignment, it says that in non-networked mode the network server code must not be used at all. "
Yes in the new assignments they are making sure they have this statement, since it was a place for confusion to many. I know half of my posts are "In Local Mode there is no server" I even post that in other forums.
Mark
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic