Change record status: 
Project: 
Introduced in branch: 
8.8.x
Introduced in version: 
8.8.0
Description: 

Starting with Drupal 8.8.0, there is no concept of a "Live" (default) workspace anymore. Switching to the live version of the site is now accomplished by switching out of the current workspace.

API additions:

WorkspaceManagerInterface has three new methods:

  • hasActiveWorkspace() - should be used to check whether a workspace context is active
  • switchToLive() - should be used to switch out of the currently active workspace
  • executeOutsideWorkspace() - should be used for executing code outside of a workspace context

WorkspaceNegotiatorInterface has one new method:

  • unsetActiveWorkspace() - used to remove the persisted workspace from a negotiator when the user switches to the Live version of the site

Deprecations:

\Drupal\workspaces\WorkspaceInterface::isDefaultWorkspace() is deprecated and now always returns FALSE because there is no "default" workspace anymore.

Code that was previously using the WorkspaceInterface::isDefaultWorkspace() method to check if some action needs to be performed based on whether the currently active workspace is the Live (default) one should use the new WorkspaceManager::hasActiveWorkspace() method instead.

Impacts: 
Site builders, administrators, editors
Module developers
Site templates, recipes and distribution developers