Forums Register Login

[B&S] Database location

+Pie Number of slices to send: Send
Hi all,
I need help to clearly understand this specification:

"the program must allow the user to specify the location of the database, and it must also accept an indication that a local database is to be used, in which case, the networking must be bypassed entirely".


At the moment, when starting the server, a dialog appears to allow the user to specify the database location.

But this phrase means also that I must implement in the client GUI the possibility to change the database location, with reload of the file?

This can be dangerous with multiple client running...

And if the user start the application with the server flag (so the server must run...), and then he specify that a local database is to be used, this one is in contrast with the first one!
So what must I do, considering the Sun automatic tests?

Thanks,

Marco
+Pie Number of slices to send: Send
If you look at your instructions carefully, you would notice that, that section describes the "Non-networked mode". Your code must run in:
1. "Networked mode" - server + (network) clients, OR
2. "Non-networked mode" - standalone client ONLY.

The instructions also mention that the same GUI should be used for the standalone client and the network client (-the search, table and all).

- You should configure your application using some GUI seperate from the client GUI (maybe some dialog, or so).

So altogether, this would mean that when you are working in the standalone (non-networked) mode,
1. you will not start the server, AND
2. you will have to specify a local database location.

- Check your documentation carefully though, because it may be different from what I think you have in your instructions.
+Pie Number of slices to send: Send
Hi Bod Toki,
thak you for your reply.

Yes, I have the specification you describe, and it also sais:

"The operating mode is selected using the single command line argument that is permitted"

Tha flag permitted are: "server", "alone" or no flag at all.

So think about this scenario:
-The user atarts the application with "server" flag (so he wants to start the application in networking mode)
-A dialog appears and the user decides to work with a local database (so he now wants to work in non-networking mode)

The second action should bypass the firs, so the final result is that tha application works in no-networking mode?

And I think that the user should be able to choose the db location only when starting the application and not when using tha application. Am I right?

Thanks,

Marco
+Pie Number of slices to send: Send
OK, i'd help you clarify this.

When starting in the Networked mode, you would start like this:
- launch the server - using say, "% runme.jar server".
- specify the server configurations, i.e. "Database Location" and "Service Port number".
- then, launch the client - using "% runme.jar". (no mode parameter).
- A dialog box appears (The Networked Client mode configurations,) requesting for the "Server IP address" and the "Service Port number" (ONLY).
- on specifying this, and clicking "OK", a network database access is created and passed to the "GUI Client".
- This way, networked mode is networked mode, user can't change it.

If, however, your want to run in Standalone mode, you would start like this:
- launch the standalone client - using say, "% runme.jar alone".
- A dialog box appears (The Standalone Client mode configurations,) requesting for the "The Local Database location" (ONLY).
- on specifying this, a local database access is created and passed to the "GUI Client".

The summary of this is that, if the user wants to change between modes, (Networked or Standalone), the user would have to quit one and launch the other.

Hope this helps.
+Pie Number of slices to send: Send
I would follow the advice that Bod has given above. The assignment instruction about local databases and specifying the location is very confusing and poorly worded. The indication that a local database is to be used is the "alone" flag. The location can then be supplied on startup.

I think what the instruction is trying (badly) to say is:

"the program must accept an indication that a local database is to be used and it must also allow the user to specify the location of the database. in which case, the networking must be bypassed entirely"

Regards,
Mark.
+Pie Number of slices to send: Send
Thanks for your help!

I think I'll do what you suggested.


Marco
The knights of nee want a shrubbery. And a tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 761 times.
Similar Threads
about the "server" instructions
question on requirements
Location of DataBase
should we open the db.db at Server startup?
networking modes
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 14:53:54.