Bug #5824
closed
Call CN.setAccessPolicy() when editing access
Added by ben leinfelder almost 12 years ago.
Updated almost 12 years ago.
Category:
morpho - general
Description
Currently Morpho edits the SystemMetadata.AccessPolicy for an EML and/or data file and uploads a new version of those during a save. Instead we should be calling the CN to set the accessPolicy for a package that has been saved to the network.
Here are some ideas:
-For local-only packages, just save the SM accessPolicy change to disk when user hits "ok" after editing the access rules.
-For network/both packages, attempt to save to the Network, if that fails, alert user to try again later. Do not save the change locally either. User will have to wait until the CN synchs with the MN to get the SM.accessPolicy updated.
I'll take this -- should be just like doing the setReplicationPolicy bug.
Matt suggested that we not save the access rules in EML anymore since they can drift out of synch with what is in the SM.
This needs to be done for data entities as well. I don't currently see any changes to edit SystemMetadata for these data objects.
For EML object:
-set the SM.AccessPolicy as reflected in the AccessPage
-save SM locally if the package is a local package; call the CN.setAccessPolicy() method if it is saved to network.
-report any errors that may have occurred (no yet synched to CN is common).
-if there are EML-defined access rules (<access/> block) then delete them and mark the EML package as unsaved.
Note that last part about mutating the EML file -- this forces you to save the package again, but it will only happen the first time you do this for a legacy EML file that has a top-level <access/> block. Comments welcome if this is not desired behavior.
Now setting access control rules for data using the data entity's SystemMetadata.AccessPolicy.
This is done. See related bug about "inherited" access rules from metadata on data
Original Bugzilla ID was 5824
Also available in: Atom
PDF