The pause and resume feature for sandbox instances allows you to perform pause (Pause) and resume (Resume) Actions on running sandbox instances. After pausing, the instance enters the paused state, its computing resources are released and billing is stopped, and the running state is fully retained. This article introduces the background information, usage scenarios, and operational methods for this feature.
warning
- The pause and resume capability is currently in beta. To activate it, please submit a ticket.
- The pause and resume capability only takes effect for sandbox instances created after the feature is activated.
In many scenarios, sandbox instances are not always running at full capacity after being created, but often have long idle periods waiting for user input or external events. If an instance continues to run during idle periods, it results in unnecessary resource consumption and costs. The pause and resume feature for sandbox instances enables you to proactively pause an instance during idle periods, stop billing, and retain its running state. When you need to continue using it, you can resume the instance and it will continue running from the state before pausing.
Sandbox instances switch between Running and Paused states. Resources are released (billing is stopped) when paused, and reallocated when resumed. You can perform Actions via the console, or call the PauseSandbox and ResumeSandbox APIs to pause and resume respectively. Status transitions are illustrated in the following diagram. tip
After pausing, the instance's computing resources (CPU / memory) are released. When resumed, the system reallocates resources. Instances in the paused state also support query and terminate Actions.
Resource retention during pause
- File system (including file contents): retained, saved as a file system snapshot, and is consistent before and after resuming.
- Memory data: not retained. Data in process memory, running processes, and established network connections must be reinitialized after resuming.
Pausing and resuming sandbox instances is applicable to the following scenarios.
Sandbox instances have been created. For operation details, see Sandbox Instance. Step 1: Pause a sandbox instance
- In the top navigation bar, select the target region.
- In the left navigation bar, select Cloud Sandbox > Sandbox Application, click the target application name to enter the details page, and select the Sandbox Instance tab.
- Locate the target instance, and in the Actions column, click ... > Pause.
- On the confirmation page, click Confirm to complete the operation.
Step 2: Resume a sandbox instance
- On the Sandbox Instance tab, click View Paused Instances to display the paused sandbox instances.
- In the Actions column of the target sandbox instance, click Resume.
- On the confirmation page, click Confirm, and the instance resumes running.