Problem/Motivation

Many use cases for workspaces treat them as one time things, therefore after deployment the workspace is not needed anymore. However it should not be deleted as an audit log and history may want to be retained.

Proposed resolution

Give an option on the deployment form to archive the workspace.
After a successful deployment unpublish the workspace.
If the deployment was not successful do not archive / unpublish the workspace.

Remaining tasks

User interface changes

API changes

Data model changes

Comments

timmillwood created an issue. See original summary.

timmillwood’s picture

Status: Active » Needs review
StatusFileSize
new1.24 KB

Checking workspaces are published.

Status: Needs review » Needs work

The last submitted patch, 2: 2939425-2.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

jeqq’s picture

Archived workspaces have also to be removed from the list of target workspaces on workspace form.

timmillwood’s picture

Status: Needs work » Needs review
StatusFileSize
new3.48 KB
new5.68 KB

Deleting workspace pointer entities when the workspace is archived.

Status: Needs review » Needs work

The last submitted patch, 5: 2939425-5.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

jeqq’s picture

+++ b/src/EntityOperations.php
@@ -54,13 +54,45 @@ class EntityOperations {
+    $storage = \Drupal::entityTypeManager()->getStorage('workspace_pointer');

Is there a reason we don't use the injected service here?

jeqq’s picture

+++ b/src/EntityOperations.php
@@ -54,13 +54,45 @@ class EntityOperations {
+      $pointer->setWorkspace($this);

::setWorkspace() should get as argument the workspace.

timmillwood’s picture

Status: Needs work » Needs review
StatusFileSize
new866 bytes
new5.68 KB

Oops, I'd put loadOrCreateWorkspacePointer() in the Workspace entity class at first, before remembering that's in Multiversion not Workspace. 😃

Status: Needs review » Needs work

The last submitted patch, 9: 2939425-9.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

jeqq’s picture

StatusFileSize
new6.45 KB
new692 bytes

Set the correct type for the text displayed on Changes page when the upstream is not set.

jeqq’s picture

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, 11: 2939425-11.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

jeqq’s picture

Status: Needs work » Needs review
StatusFileSize
new7.01 KB
new924 bytes

Return 404 when the source workspace is null or it has been archived.

Status: Needs review » Needs work

The last submitted patch, 14: 2939425-14.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

timmillwood’s picture

Status: Needs work » Needs review
StatusFileSize
new2.84 KB
new9.86 KB

Adding extra test.

Status: Needs review » Needs work

The last submitted patch, 16: 2939425-16.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

jeqq’s picture

Status: Needs work » Reviewed & tested by the community

looks good!

  • timmillwood committed 9c2f6d7 on 8.x-1.x
    Issue #2939425 by timmillwood, jeqq: Allow deployed workspaces to be...
timmillwood’s picture

Status: Reviewed & tested by the community » Fixed

Pushed.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.