-
Notifications
You must be signed in to change notification settings - Fork 10
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
Delete or clean client data #25
Comments
For a quick overview I added all available NSM-programs on my system into a single session and saved (all empty). The NSM API mentions two variants: use name.ID directly as file or dir or append a file extension.
There are many programs that use the file extension (All carla versions, JACKpatch, Non-Sequencer, QMidiArp, ZynAddSubFX, possibly more). While the file extension cannot be known by nsmd nor the GUI it is a clear pattern still. If deleting client data is done in two steps I think this would be safe to work. An OSC message to request a list of clients files (in the subdir variant) and a second message to instruct nsmd to delete client files (not a list of files to delete, nsmd will fetch them on its own again). Those two messages would be technically independent. A GUI like Argodejo should first ask for confirmation, presenting the list of files, then instruct to delete. But there are enough scenarios where a user knows exactly what is going on in the session-dir and just wants to send a script command to delete a client (for example in headless scenarios) I can create a proof of concept version of that behaviour in Argodejo, to test if this is reliable and convenient. However, due to networked sessions in the end only the daemon itself (or rather the interconnected daemons) have access to their files. |
When loading an existent session, why not copying it in a temp file or directory ? In case of abort, the temp file is restored, so there is no risk of loosing data. You could safely delete client data when removing a client. |
Thanks for the good input. Working with temporary copies of files is an interesting concept in itself with many opportunities. Some thoughts to explore the idea: This is on such a fundamental level that any changes in this direction would need very careful planning and thorough testing. It may sound less convenient than an automatic solution but a dedicated step to clean up a session (with user confirmation) might turn out to be a more robust approach, especially given that it is required not that often. And it is still better than cleaning up files by hand without the assistance of the session-knowledge. Maybe there are aspects of this idea, and its further development, that can be integrated safely without changing the expected behaviour from a users point of view. Expected behaviour is either explicitely stated in the docs or implicit computer-desktop conventions. |
When a client is removed from a session it leaves data behind.
This is both needed and undesired.
This is not a paradox. Cleaning up old clients need not be integrated into the existing remove functionality but could be an extra step with e.g. the option for the GUI to present a list of files and ask for confirmation. Or even cherry pick which old clients to delete.
However, that remains wishful thinking until there is a solution to figure out which files belong to which client.
Background information: Each client receives a name.ID combo to be used as name for the save-file. In an ideal world this will either be a single file or a directory with arbitrary content. Both variants make sure to find only the this clients data. However, it must be confirmed that these are indeed the only possible scenarios (according to the NSM API specs) and there is no chance of over-deleting.
The text was updated successfully, but these errors were encountered: