The applicationRollback Web API Method

Rollback an existing application to its previous version. This process is asynchronous, meaning the initial request will start the rollback process and the initial response will show information about the application being rolled back. You must continue checking the application status using the applicationGetStatus method until the process is

complete.

Version: 1.2

Required Permissions: Full

HTTP method: POST

Supported by Editions:Zend Server

Request Parameters:

Parameter

 Type

Required

Description

appId

String

Yes

The application ID you would like to rollback.

Expected Response Code: 202 Accepted - For more information see Response Format.

Response Type: applicationInfo

Possible Action Specific Error Codes:

HTTP Code

 Error Code

Description

404

noSuchApplication

The provided application ID does not exist.

404

noRollbackAvailable

The application cannot rollback as there is no previous version.

Example

Usage Example

Request

POST /ZendServer/Api/applicationRollback

Content-type: application/x-www-form-urlencoded

appId=5

Response

<?xml version="1.0" encoding="UTF-8"?>

<zendServerAPIResponse xmlns="http://www.zend.com/server/api/1.3">

<requestData>

<apiKeyName>angel.eyes</apiKeyName>

<method>applicationRollback</method>

</requestData>

<responseData>

<applicationInfo>

<id>1</id>

<baseUrl>http://example.com/myapp</baseUrl>

<appName>Wordpress</appName>

<userAppName>Wolfgang's Blog</userAppName>

<installedLocation>/usr/local/somewhere</installedLocation>

<status>rollingBack</status>

<servers>

<applicationServer>

<id>1</id>

<deployedVersion>1.6</deployedVersion>

<status>rollingBack</status>

</applicationServer>

<applicationServer>

<id>4</id>

<deployedVersion>1.6</deployedVersion>

<status>rollingBack</status>

</applicationServer>

<applicationServer>

<id>8</id>

<deployedVersion>1.5</deployedVersion>

<status>deployed</status>

</applicationServer>

</servers>

<deployedVersions>

<deployedVersion>1.6</deployedVersion>

<deployedVersion>1.5</deployedVersion>

</deployedVersions>

<messageList />

<creationTime>1970-01-01T02:00:00+02:00</creationTime>

<lastUsed>1970-01-01T02:00:00+02:00</lastUsed>

</applicationInfo>

</responseData>

</zendServerAPIResponse>

Important Note:

For Zend Serveron Linux, this action is also available via the command line using CLI Tools. For more information see CLI Tools.