Configurations#

This section describes the following API operations that are supported for configurations.

You can also find additional configuration-related information in the descriptions for the following API operations:

List configurations#

GET /{version}/{accountId}/configurations

Lists all defined configuration group s for the tenant.

This table shows the possible response codes for this operation:

Response Code

Name

Description

200

Success

Request succeeded.

400

Bad Request

The request is missing one or more elements, or the values of some elements are invalid.

401

Unauthorized

You are not authorized to complete this operation. This error can occur if the request is submitted with an invalid authentication token.

403

Forbidden

You are denied access to the requested resource.

404

Not Found

The requested item was not found.

405

badMethod

The specified method is not allowed for the given resource.

413

Over Limit

The number of items returned is above the allowed limit.

422

unprocessableEntity

The item cannot be processed.

500

instanceFault

The instance has experienced a fault.

501

notImplemented

The server does not support the functionality required to fulfill the request.

503

Service Unavailable

The service is not available.

Request#

This table shows the URI parameters for the request:

Name

Type

Description

{accountId}

String

The account ID of the owner of the specified instance.

This operation does not accept a request body.

Example List configurations: JSON request

The following example shows the List configurations request:

GET /v1.0/1234/configurations HTTP/1.1
Host: ord.databases.api.rackspacecloud.com
User-Agent: python-troveclient
Accept: application/json
X-Auth-Token: 26640a608aa9482b888a1664376b8113

Response#

Example List configurations: JSON response

The following example shows the List configurations response:

HTTP/1.1 200 OK
Content-Type: application/json
Via: 1.1 Repose (Repose/2.12)
Content-Length: 336
Date: Thu, 31 Jul 2014 19:00:54 GMT
Server: Jetty(8.0.y.z-SNAPSHOT)

{
    "configurations": [
        {
            "created": "2014-07-31T18:56:09",
            "datastore_name": "mysql",
            "datastore_version_id": "b00000b0-00b0-0b00-00b0-000b000000bb",
            "datastore_version_name": "5.6",
            "description": "example description",
            "id": "005a8bb7-a8df-40ee-b0b7-fc144641abc2",
            "name": "example-configuration-name",
            "updated": "2014-07-31T18:56:09"
        }
    ]
}

Create configuration#

POST /{version}/{accountId}/configurations

Creates a new configuration group based on the parameters supplied in the request body.

This table shows the possible response codes for this operation:

Response Code

Name

Description

200

Success

Request succeeded.

400

Bad Request

The request is missing one or more elements, or the values of some elements are invalid.

401

Unauthorized

You are not authorized to complete this operation. This error can occur if the request is submitted with an invalid authentication token.

403

Forbidden

You are denied access to the requested resource.

404

Not Found

The requested item was not found.

405

badMethod

The specified method is not allowed for the given resource.

413

Over Limit

The number of items returned is above the allowed limit.

422

unprocessableEntity

The item cannot be processed.

500

instanceFault

The instance has experienced a fault.

501

notImplemented

The server does not support the functionality required to fulfill the request.

503

Service Unavailable

The service is not available.

Request#

This table shows the URI parameters for the request:

Name

Type

Description

{accountId}

String

The account ID of the owner of the specified instance.

This table shows the body parameters for the request:

Name

Type

Description

datastore

Object (Optional)

The datastore for the configuration. If omitted, it defaults to MySQL 5.6.

datastore.type

String (Optional)

The type of the datastore for the configuration. If omitted, it defaults to MySQL.

datastore.version

String (Optional)

The version of the datastore for the configuration. If omitted, it defaults to MySQL 5.6.

description

String (Optional)

The description for the configuration.

name

String (Required)

The name for the configuration.

values

Object (Required)

The values for the configuration. The key value pairs “values” should be in JSON format with no spaces. The key and the value are strings and must be enclosed in double quotation marks. For example: “default_time_zone”: “- 6:00”. Each key value pair should be separated by a comma.

Example Create configuration: JSON request

The following example shows the Create configuration request:

POST /v1.0/1234/configurations HTTP/1.1
User-Agent: python-troveclient
Host: ord.databases.api.rackspacecloud.com
X-Auth-Token: 87c6033c-9ff6-405f-943e-2deb73f278b7
Accept: application/json
Content-Type: application/json

{
    "configuration": {
        "datastore": {
            "type": "a00000a0-00a0-0a00-00a0-000a000000aa",
            "version": "b00000b0-00b0-0b00-00b0-000b000000bb"
        },
        "description": "example description",
        "name": "example-configuration-name",
        "values": {
            "collation_server": "latin1_swedish_ci",
            "connect_timeout": 120
        }
    }
}

Note

Each value provided for name and description must be a string composed of 1 to 255 alphanumeric characters. Both uppercase and lowercase alpha characters may be used.

Response#

Example Create configuration: JSON response

The following example shows the Create configuration response:

HTTP/1.1 200 OK
Content-Type: application/json
Via: 1.1 Repose (Repose/2.12)
Content-Length: 431
Date: Thu, 31 Jul 2014 15:07:26 GMT
Server: Jetty(8.0.y.z-SNAPSHOT)

{
    "configuration": {
        "created": "2014-07-31T15:02:52",
        "datastore_name": "mysql",
        "datastore_version_id": "b00000b0-00b0-0b00-00b0-000b000000bb",
        "datastore_version_name": "5.6",
        "description": "example description",
        "id": "005a8bb7-a8df-40ee-b0b7-fc144641abc2",
        "instance_count": 0,
        "name": "example-configuration-name",
        "updated": "2014-07-31T15:02:52",
        "values": {
            "collation_server": "latin1_swedish_ci",
            "connect_timeout": 120
        }
    }
}

List configuration details#

GET /{version}/{accountId}/configurations/{configId}

Lists details for the specified configuration group.

This table shows the possible response codes for this operation:

Response Code

Name

Description

200

Success

Request succeeded.

400

Bad Request

The request is missing one or more elements, or the values of some elements are invalid.

401

Unauthorized

You are not authorized to complete this operation. This error can occur if the request is submitted with an invalid authentication token.

403

Forbidden

You are denied access to the requested resource.

404

Not Found

The requested item was not found.

405

badMethod

The specified method is not allowed for the given resource.

413

Over Limit

The number of items returned is above the allowed limit.

422

unprocessableEntity

The item cannot be processed.

500

instanceFault

The instance has experienced a fault.

501

notImplemented

The server does not support the functionality required to fulfill the request.

503

Service Unavailable

The service is not available.

Request#

This table shows the URI parameters for the request:

Name

Type

Description

{accountId}

String

The account ID of the owner of the specified instance.

{configId}

String

The configuration ID for the specified configuration group.

This operation does not accept a request body.

Example List configuration details: JSON request

The following example shows the List configuration details request:

GET /v1.0/1234/configurations/005a8bb7-a8df-40ee-b0b7-fc144641abc2 HTTP/1.1
Host: ord.databases.api.rackspacecloud.com
User-Agent: python-troveclient
Accept: application/json
X-Auth-Token: 26640a608aa9482b888a1664376b8113

Response#

Example List configuration details: JSON response

The following example shows the List configuration details response:

HTTP/1.1 200 OK
Content-Type: application/json
Via: 1.1 Repose (Repose/2.12)
Content-Length: 431
Date: Thu, 31 Jul 2014 15:25:07 GMT
Server: Jetty(8.0.y.z-SNAPSHOT)

{
    "configuration": {
        "created": "2014-07-31T15:19:50",
        "datastore_name": "mysql",
        "datastore_version_id": "b00000b0-00b0-0b00-00b0-000b000000bb",
        "datastore_version_name": "5.6",
        "description": "example description",
        "id": "005a8bb7-a8df-40ee-b0b7-fc144641abc2",
        "instance_count": 0,
        "name": "example-configuration-name",
        "updated": "2014-07-31T15:19:50",
        "values": {
            "collation_server": "latin1_swedish_ci",
            "connect_timeout": 120
        }
    }
}

Update some configuration parameters#

PATCH /{version}/{accountId}/configurations/{configId}

Updates some of the configuration parameter s associated with the specified configuration group.

This table shows the possible response codes for this operation:

Response Code

Name

Description

200

Success

Request succeeded.

400

Bad Request

The request is missing one or more elements, or the values of some elements are invalid.

401

Unauthorized

You are not authorized to complete this operation. This error can occur if the request is submitted with an invalid authentication token.

403

Forbidden

You are denied access to the requested resource.

404

Not Found

The requested item was not found.

405

badMethod

The specified method is not allowed for the given resource.

413

Over Limit

The number of items returned is above the allowed limit.

422

unprocessableEntity

The item cannot be processed.

500

instanceFault

The instance has experienced a fault.

501

notImplemented

The server does not support the functionality required to fulfill the request.

503

Service Unavailable

The service is not available.

Request#

This table shows the URI parameters for the request:

Name

Type

Description

{accountId}

String

The account ID of the owner of the specified instance.

{configId}

String

The configuration ID for the specified configuration group.

Example Update some configuration parameters: JSON request

The following example shows the Update some configuration parameters request:

PATCH /v1.0/1234/configurations/f5aaf933-86b2-440e-a9dc-36c24665b3b4 HTTP/1.1
User-Agent: python-troveclient
Host: ord.databases.api.rackspacecloud.com
X-Auth-Token: 87c6033c-9ff6-405f-943e-2deb73f278b7
Accept: application/json
Content-Type: application/json

{
    "configuration": {
        "values": {
            "connect_timeout": 300
        }
    }
}

Response#

Example Update some configuration parameters: JSON response

The following example shows the Update some configuration parameters response:

HTTP/1.1 200 OK
Content-Type: application/json
Via: 1.1 Repose (Repose/2.6.7)
Content-Length: 0
Date: Thu, 13 Feb 2014 21:47:15 GMT
Server: Jetty(8.0.y.z-SNAPSHOT)

Replace all configuration parameters#

PUT /{version}/{accountId}/configurations/{configId}

Replaces all of the configuration parameter s associated with the specified configuration group.

This table shows the possible response codes for this operation:

Response Code

Name

Description

200

Success

Request succeeded.

400

Bad Request

The request is missing one or more elements, or the values of some elements are invalid.

401

Unauthorized

You are not authorized to complete this operation. This error can occur if the request is submitted with an invalid authentication token.

403

Forbidden

You are denied access to the requested resource.

404

Not Found

The requested item was not found.

405

badMethod

The specified method is not allowed for the given resource.

413

Over Limit

The number of items returned is above the allowed limit.

422

unprocessableEntity

The item cannot be processed.

500

instanceFault

The instance has experienced a fault.

501

notImplemented

The server does not support the functionality required to fulfill the request.

503

Service Unavailable

The service is not available.

Request#

This table shows the URI parameters for the request:

Name

Type

Description

{accountId}

String

The account ID of the owner of the specified instance.

{configId}

String

The configuration ID for the specified configuration group.

Example Replace all configuration parameters: JSON request

The following example shows the Replace all configuration parameters request:

PUT /v1.0/1234/configurations/f5aaf933-86b2-440e-a9dc-36c24665b3b4 HTTP/1.1
User-Agent: python-troveclient
Host: ord.databases.api.rackspacecloud.com
X-Auth-Token: 87c6033c-9ff6-405f-943e-2deb73f278b7
Accept: application/json
Content-Type: application/json

{
    "configuration": {
        "description": "example updated description",
        "name": "example-updated-name",
        "values": {
            "collation_server": "utf8_unicode_ci",
            "connect_timeout": 150
        }
    }
}

Note

Each value provided for name and description must be a string composed of 1 to 255 alphanumeric characters. Both uppercase and lowercase alpha characters may be used.

Response#

Example Replace all configuration parameters: JSON response

The following example shows the Replace all configuration parameters response:

HTTP/1.1 202 Accepted
Content-Type: application/json
Via: 1.1 Repose (Repose/2.6.7)
Content-Length: 0
Date: Thu, 13 Feb 2014 21:47:15 GMT
Server: Jetty(8.0.y.z-SNAPSHOT)

This operation does not return a response body.

Delete configuration group#

DELETE /{version}/{accountId}/configurations/{configId}

Deletes the specified configuration group. No message body is expected in the request.

This table shows the possible response codes for this operation:

Response Code

Name

Description

200

Success

Request succeeded.

400

Bad Request

The request is missing one or more elements, or the values of some elements are invalid.

401

Unauthorized

You are not authorized to complete this operation. This error can occur if the request is submitted with an invalid authentication token.

403

Forbidden

You are denied access to the requested resource.

404

Not Found

The requested item was not found.

405

badMethod

The specified method is not allowed for the given resource.

413

Over Limit

The number of items returned is above the allowed limit.

422

unprocessableEntity

The item cannot be processed.

500

instanceFault

The instance has experienced a fault.

501

notImplemented

The server does not support the functionality required to fulfill the request.

503

Service Unavailable

The service is not available.

Request#

This table shows the URI parameters for the request:

Name

Type

Description

{accountId}

String

The account ID of the owner of the specified instance.

{configId}

String

The configuration ID for the specified configuration group.

This operation does not accept a request body.

Example Delete configuration group: JSON request

The following example shows the Delete configuration group request:

DELETE /v1.0/1234/configurations/f5aaf933-86b2-440e-a9dc-36c24665b3b4 HTTP/1.1
User-Agent: python-troveclient
Host: ord.databases.api.rackspacecloud.com
X-Auth-Token: 87c6033c-9ff6-405f-943e-2deb73f278b7
Accept: application/json
Content-Type: application/json

Response#

Example Delete configuration group: JSON response

The following example shows the Delete configuration group response:

HTTP/1.1 202 Accepted
Content-Type: application/json
Via: 1.1 Repose (Repose/2.6.7)
Content-Length: 0
Date: Thu, 13 Feb 2014 21:47:19 GMT
Server: Jetty(8.0.y.z-SNAPSHOT)

List instances for configuration#

GET /{version}/{accountId}/configurations/{configId}/instances

Lists instances that are associated with the specified configuration group.

This table shows the possible response codes for this operation:

Response Code

Name

Description

200

Success

Request succeeded.

400

Bad Request

The request is missing one or more elements, or the values of some elements are invalid.

401

Unauthorized

You are not authorized to complete this operation. This error can occur if the request is submitted with an invalid authentication token.

403

Forbidden

You are denied access to the requested resource.

404

Not Found

The requested item was not found.

405

badMethod

The specified method is not allowed for the given resource.

413

Over Limit

The number of items returned is above the allowed limit.

422

unprocessableEntity

The item cannot be processed.

500

instanceFault

The instance has experienced a fault.

501

notImplemented

The server does not support the functionality required to fulfill the request.

503

Service Unavailable

The service is not available.

Request#

This table shows the URI parameters for the request:

Name

Type

Description

{accountId}

String

The account ID of the owner of the specified instance.

{configId}

String

The configuration ID for the specified configuration group.

This operation does not accept a request body.

Example List instances for configuration: JSON request

The following example shows the List instances for configuration request:

GET /v1.0/1234/configurations/f5aaf933-86b2-440e-a9dc-36c24665b3b4/instances HTTP/1.1
User-Agent: python-troveclient
Host: ord.databases.api.rackspacecloud.com
X-Auth-Token: 87c6033c-9ff6-405f-943e-2deb73f278b7
Accept: application/json
Content-Type: application/json

Response#

Example List instances for configuration: JSON response

The following example shows the List instances for configuration response:

HTTP/1.1 200 OK
Content-Type: application/json
Via: 1.1 Repose (Repose/2.6.7)
Content-Length: 93
Date: Thu, 13 Feb 2014 21:47:15 GMT
Server: Jetty(8.0.y.z-SNAPSHOT)

{
    "instances": [
        {
            "id": "d4603f69-ec7e-4e9b-803f-600b9205576f",
            "name": "json_rack_instance"
        }
    ]
}