Bug #5824

Call CN.setAccessPolicy() when editing access

Added by ben leinfelder over 9 years ago. Updated over 9 years ago.

morpho - general
Target version:
Start date:
Due date:
% Done:


Estimated time:


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.

Related issues

Blocked by Morpho - Bug #5831: Address "inherited" access policy on data entitiesResolved01/29/2013


#1 Updated by ben leinfelder over 9 years ago

I'll take this -- should be just like doing the setReplicationPolicy bug.

#2 Updated by ben leinfelder over 9 years ago

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.

#3 Updated by ben leinfelder over 9 years ago

This needs to be done for data entities as well. I don't currently see any changes to edit SystemMetadata for these data objects.

#4 Updated by ben leinfelder over 9 years ago

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.

#5 Updated by ben leinfelder over 9 years ago

Now setting access control rules for data using the data entity's SystemMetadata.AccessPolicy.

#6 Updated by ben leinfelder over 9 years ago

This is done. See related bug about "inherited" access rules from metadata on data

#7 Updated by Redmine Admin over 9 years ago

Original Bugzilla ID was 5824

Also available in: Atom PDF