-
Notifications
You must be signed in to change notification settings - Fork 225
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Server UI changes #2199
Server UI changes #2199
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you. Will try soon.
bc5e7bc
to
abe3c1f
Compare
Jamulus client - connects your sound system to the internet! Let's jam! Jamulus server - somewhere Jamulus clients connect to for jams. A Jamulus server has an "address". Server list - a list of Jamulus servers retrieved from a Jamulus directory (a Jamulus directory "publishes" a server list, if you like to use the word "publish" for anything at all) Jamulus directory - a service with which a Jamulus server can choose to register and from which a Jamulus client can request a server list (list of Jamulus servers). A Jamulus directory has an "address". Address - Jamulus client users will most likely use the server list in the Connect dialog, so only need to know the Jamulus directory and Name for the Jamulus server they want to use. However, the Conenct dialog also allows entering an Address. An Address can also be given for a Custom directory, both in client and server. The Address is a host name or IP address with an optional port number, for instance "jams.example.com:22555" or "192.168.1.54". Public directory - all of the built in Jamulus directories, some custom directories Custom directory - a Jamulus directory not built into the Jamulus server or client Private directory - a custom directory that restricts access for server registration and server list retrieval Private server - a server (optionally registered with a directory) that restricts access for client connection NOTE: "Privacy" (i.e. running as a private directory or private server) is not directly supported by Jamulus - firewall set up is required. (When thinking about this, remember |
For the "Directory" drop down:
For the status value:
|
We're also planning client Connect window changes:
(Client Settings/Advanced Custom directories "What's This?" looks good to me -- seems I've not changed my mind again since I wrote it... or I have but I've got back to where I was at that point...) |
abe3c1f
to
596385a
Compare
Hm. Can we try not running all of the builds in parallel? It might be causing the fails. If it doesn't fix it, we can switch back to parallel... ... third time lucky... |
596385a
to
fafc85d
Compare
Probably out of scope, but having the recorder directory in the Options tab while having the (by default disabled) "enable recorder" checkbox in the configuration tab seems very confusing. We don't hint the user at setting a recording directory, so by default it looks like the recording feature is not available (and this can't be fixed). |
The whole Server UI is a bit clumsy. Pretty much everything for a server is "set once and forget". You could almost have the list of clients filling one tab and a second tab "Settings" for everything, grouped more logically (with some more visual hinting to group related items). |
fafc85d
to
f539230
Compare
98311c0
to
c57d3a0
Compare
Given no one's come up with an alternative that makes sense to registering when you register with a directory, can we go ahead with this? I was hoping to get this as well as
into the coming release but it looks like that's been missed. |
3.8.2 is supposed to be a bug fix release, but I don't suppose we need to stick to that. |
Given that this PR touches many files and deliberately changes layout and behavior, I'd tend towards targeting 3.9.0. Such changes might come unexpected for users, e.g. see the unexpected (?) sandboxing side effects of the Mac signing stuff. |
0c55a50
to
b4e4937
Compare
b4e4937
to
a50f9e2
Compare
a50f9e2
to
0eb4436
Compare
Can this be merged right after the upcoming release? If yes, please do so. |
I'll rebase (and squash shortly). |
0eb4436
to
be7b7c1
Compare
Great! |
Hm. I changed the commit comment. Let me try that again. |
be7b7c1
to
6b61c23
Compare
I merged some PRs, maybe that's why - although I doubt that. |
No, I probably got lost somewhere locally - I had to redo what I was doing at one point. |
It'll be easier to document this once it's stable on master. So does anyone want to approve it? :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Although only roughly tested a few weeks ago, I think we should merge this (and tag a nightly in a week or so)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Had a look through and made some initial comments. Would really like to compile and try it out, but as I said, can't do that will Wednesday.
It looks like the "Register" checkbox has been replaced by a "None" option in the directory list. That means if the user wants to unregister their server, it can't remember where it was registered to, and the user needs to choose the directory afresh when re-registering. With an on/off checkbox, the preferred directory could be left set.
@@ -684,12 +684,6 @@ void CServer::OnAboutToQuit() | |||
|
|||
Stop(); | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Was it deliberate to remove the if ( GetServerRegistered() ) { Unregister(); }
here? I can't see it has moved to anywhere else.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
9222c20 was the original change doing this and ServerListManager.SetDirectoryType()
seems to handle Unregister()
if necessary: https://github.com/jamulussoftware/jamulus/blob/master/src/serverlist.cpp#L269-L275
So this looks fine to me.
if ( strDirectoryServer.isEmpty() ) | ||
{ | ||
// per definition, we must be a headless server and ignoring inifile, so we have all the information | ||
// by definition, when running with the GUI we always default to registering somewhere but |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment suggests that you can't have an unregistered ("private") server when running with the GUI. That's not true, surely (maybe it used to be?). Could the comment be clarified?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, it says what it defaults to, not what's available.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have just tried this code for the first time (in fact it was the code for #2427 I tried, which incorporates these changes), and compared with 3.8.2, using default empty ini files to ensure all defaults were used:
/usr/local/bin/Jamulus -s -i /tmp/x.ini
./Jamulus -s -p 22125 -i /tmp/y.ini
The 3.8.2 defaulted to "Not registered", with the "make my server public" checkbox unticked, which is good.
The newer version defaulted to registering with Any Genre 1, which I think is not good. The directory drop-down should default to "None", if not set in the command line or ini file, so that a new server does not register with a directory until the user asks it to.
6b61c23
to
a99dd6b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code looks good to me, but I haven't done any real-world tests so far. I'll comment again when I get time to do those. At least one additional person should do them before merging, I guess. :)
Meta: This PR is rather large and was not easy to review for me. I did most of the initial reading via git log -wp 75e4ad0c100bce605c14d9fe0f0729143fc70bc2..a50f9e2f62b3bae8acaf4bfde1b0918b53db7aad
(earlier state before rebasings) as it was much simpler for me to follow the individual commits.
What I think we should do for future refactoring PRs is:
- Make refactorings only do refactorings. It's way harder to judge whether code reorganizations are correct if they are mixed with new functionality.
- Use and keep individual commits with a polished subject and description so that they can be merged without squashing.
Thanks for doing this though, it looks much cleaner and logical to me now.
@@ -684,12 +684,6 @@ void CServer::OnAboutToQuit() | |||
|
|||
Stop(); | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
9222c20 was the original change doing this and ServerListManager.SetDirectoryType()
seems to handle Unregister()
if necessary: https://github.com/jamulussoftware/jamulus/blob/master/src/serverlist.cpp#L269-L275
So this looks fine to me.
// clang-format off | ||
// TODO compatibility to old version < 3.8.2 | ||
directoryAddress = GetIniSetting ( IniXMLDocument, "server", "centralservaddr", directoryAddress ); | ||
// clang-format on |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a huge fan of this break-identation-to-get-attention scheme personally (I know that the original code uses this in several places).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in several places
"Consistently" might be a better way of putting it ;).
a99dd6b
to
1088c0a
Compare
Short description of changes
My initial goal was to add to the server UI a way of setting (and changing in flight) the server list persistence file for a Jamulus directory.
However, during that change, it became apparent that the design of the interface between GUI and service layers was not geared to such in flight changes - the server is more expectant that it will be run with a configuration and left running "as is".
CHANGELOG: UI: Amend server registration, add server persistence
Context: Fixes an issue?
Jamulus Directory improvements: UI to set / amend / remove the server list persistence file;
Jamulus Server improvements: the server can be switched between:
without restart, through the UI. That configuration will be saved and restored in the server inifile. If set to unregistered, the server will start up unregistered, rather than registered in the default directory. You can set the custom directory without registering, so you can set that whilst unregistered then switch to registering with the custom directory, and never register as a public server.
Does this change need documentation? What needs to be documented and how?
The UI has changed both in layout and behaviour. All server documentation probably needs review as a result.
Status of this Pull Request
I've been running it for months in headless mode. I've used it on Windows and Linux with the GUI and find it works much better than 3.8.1.
What is missing until this pull request can be merged?
More testing. UX feedback.
Checklist