Instance Size Selections with the SkySQL DBaaS API

Overview

This reference page details how to select instance sizes with the SkySQL DBaaS API for SkySQL.

Instance size defines vCPU count and memory.

For database nodes, instance size can be selected to meet your requirements. All database nodes within a service use the same instance size.

When your SkySQL account has Power tier, an instance size for MaxScale nodes can be selected during service launch. When a MaxScale instance size is not specified, the default size is used.

When your SkySQL account has Foundation tier, the instance size for MaxScale nodes can't be selected, and the default size is always used.

Available Instance Sizes

Instance size choices are specific to the cloud provider, topology, region, and hardware architecture.

Enterprise Server Single Node

For Foundation tier:

Instance Size

Cloud Provider

CPU

Memory

sky-2x4

aws

2 vCPU

4 GB

sky-2x8

aws

2 vCPU

8 GB

sky-2x8

gcp

2 vCPU

8 GB

sky-4x16

aws

4 vCPU

16 GB

sky-4x16

gcp

4 vCPU

16 GB

sky-4x32

aws

4 vCPU

32 GB

sky-4x32

gcp

4 vCPU

32 GB

sky-8x32

aws

8 vCPU

32 GB

sky-8x32

gcp

8 vCPU

32 GB

sky-8x64

aws

8 vCPU

64 GB

sky-8x64

gcp

8 vCPU

64 GB

For Power tier:

Instance Size

Cloud Provider

CPU

Memory

sky-2x4

aws

2 vCPU

4 GB

sky-2x8

aws

2 vCPU

8 GB

sky-2x8

gcp

2 vCPU

8 GB

sky-4x16

aws

4 vCPU

16 GB

sky-4x16

gcp

4 vCPU

16 GB

sky-4x32

aws

4 vCPU

32 GB

sky-4x32

gcp

4 vCPU

32 GB

sky-8x32

aws

8 vCPU

32 GB

sky-8x32

gcp

8 vCPU

32 GB

sky-8x64

aws

8 vCPU

64 GB

sky-16x64

aws

16 vCPU

64 GB

sky-16x64

gcp

16 vCPU

64 GB

sky-16x128

aws

16 vCPU

128 GB

sky-16x128

gcp

16 vCPU

128 GB

sky-32x128

aws

32 vCPU

128 GB

sky-32x128

gcp

32 vCPU

128 GB

sky-32x256

aws

32 vCPU

256 GB

sky-32x256

gcp

32 vCPU

256 GB

sky-64x256

aws

64 vCPU

256 GB

sky-64x256

gcp

64 vCPU

256 GB

sky-64x512

aws

64 vCPU

512 GB

sky-64x512

gcp

64 vCPU

512 GB

Enterprise Server With Replica(s)

For Foundation tier:

Instance Size

Cloud Provider

CPU

Memory

sky-2x4

aws

2 vCPU

4 GB

sky-2x8

aws

2 vCPU

8 GB

sky-2x8

gcp

2 vCPU

8 GB

sky-4x16

aws

4 vCPU

16 GB

sky-4x16

gcp

4 vCPU

16 GB

sky-4x32

aws

4 vCPU

32 GB

sky-4x32

gcp

4 vCPU

32 GB

sky-8x32

aws

8 vCPU

32 GB

sky-8x32

gcp

8 vCPU

32 GB

sky-8x64

aws

8 vCPU

64 GB

sky-8x64

gcp

8 vCPU

64 GB

For Power tier:

Instance Size

Cloud Provider

CPU

Memory

sky-2x4

aws

2 vCPU

4 GB

sky-2x8

aws

2 vCPU

8 GB

sky-2x8

gcp

2 vCPU

8 GB

sky-4x16

aws

4 vCPU

16 GB

sky-4x16

gcp

4 vCPU

16 GB

sky-4x32

aws

4 vCPU

32 GB

sky-4x32

gcp

4 vCPU

32 GB

sky-8x32

aws

8 vCPU

32 GB

sky-8x32

gcp

8 vCPU

32 GB

sky-8x64

aws

8 vCPU

64 GB

sky-16x64

aws

16 vCPU

64 GB

sky-16x64

gcp

16 vCPU

64 GB

sky-16x128

aws

16 vCPU

128 GB

sky-16x128

gcp

16 vCPU

128 GB

sky-32x128

aws

32 vCPU

128 GB

sky-32x128

gcp

32 vCPU

128 GB

sky-32x256

aws

32 vCPU

256 GB

sky-32x256

gcp

32 vCPU

256 GB

sky-64x256

aws

64 vCPU

256 GB

sky-64x256

gcp

64 vCPU

256 GB

sky-64x512

aws

64 vCPU

512 GB

sky-64x512

gcp

64 vCPU

512 GB

Xpand Distributed SQL

For Foundation tier:

Instance Size

Cloud Provider

CPU

Memory

sky-4x16

aws

4 vCPU

16 GB

sky-4x16

gcp

4 vCPU

16 GB

sky-4x32

aws

4 vCPU

32 GB

sky-4x32

gcp

4 vCPU

32 GB

sky-8x32

aws

8 vCPU

32 GB

sky-8x32

gcp

8 vCPU

32 GB

sky-8x64

aws

8 vCPU

64 GB

sky-8x64

gcp

8 vCPU

64 GB

For Power tier:

Instance Size

Cloud Provider

CPU

Memory

sky-4x16

aws

4 vCPU

16 GB

sky-4x16

gcp

4 vCPU

16 GB

sky-4x32

aws

4 vCPU

32 GB

sky-4x32

gcp

4 vCPU

32 GB

sky-8x32

aws

8 vCPU

32 GB

sky-8x32

gcp

8 vCPU

32 GB

sky-8x64

aws

8 vCPU

64 GB

sky-16x64

aws

16 vCPU

64 GB

sky-16x64

gcp

16 vCPU

64 GB

sky-16x128

aws

16 vCPU

128 GB

sky-16x128

gcp

16 vCPU

128 GB

sky-32x128

aws

32 vCPU

128 GB

sky-32x128

gcp

32 vCPU

128 GB

sky-32x256

aws

32 vCPU

256 GB

sky-32x256

gcp

32 vCPU

256 GB

ColumnStore Data Warehouse

For Foundation tier:

Instance Size

Cloud Provider

CPU

Memory

sky-4x16

aws

4 vCPU

16 GB

sky-4x16

gcp

4 vCPU

16 GB

sky-4x32

aws

4 vCPU

32 GB

sky-4x32

gcp

4 vCPU

32 GB

sky-8x32

aws

8 vCPU

32 GB

sky-8x32

gcp

8 vCPU

32 GB

sky-8x64

aws

8 vCPU

64 GB

sky-8x64

gcp

8 vCPU

64 GB

For Power tier:

Instance Size

Cloud Provider

CPU

Memory

sky-4x16

aws

4 vCPU

16 GB

sky-4x16

gcp

4 vCPU

16 GB

sky-4x32

aws

4 vCPU

32 GB

sky-4x32

gcp

4 vCPU

32 GB

sky-8x32

aws

8 vCPU

32 GB

sky-8x32

gcp

8 vCPU

32 GB

sky-8x64

aws

8 vCPU

64 GB

sky-16x64

aws

16 vCPU

64 GB

sky-16x64

gcp

16 vCPU

64 GB

sky-16x128

aws

16 vCPU

128 GB

sky-16x128

gcp

16 vCPU

128 GB

sky-32x128

aws

32 vCPU

128 GB

sky-32x128

gcp

32 vCPU

128 GB

sky-32x256

aws

32 vCPU

256 GB

sky-32x256

gcp

32 vCPU

256 GB

sky-64x256

aws

64 vCPU

256 GB

sky-64x256

gcp

64 vCPU

256 GB

sky-64x512

aws

64 vCPU

512 GB

sky-64x512

gcp

64 vCPU

512 GB

MaxScale

With Power tier, the following instance sizes can be selected for MaxScale nodes:

Instance Size

Cloud Provider

CPU

Memory

sky-2x4

aws

2 vCPU

4 GB

sky-2x8

gcp

2 vCPU

8 GB

sky-4x16

aws

4 vCPU

16 GB

sky-4x16

gcp

4 vCPU

16 GB

sky-8x32

aws

8 vCPU

32 GB

sky-8x32

gcp

8 vCPU

32 GB

sky-16x64

aws

16 vCPU

64 GB

sky-16x64

gcp

16 vCPU

64 GB

sky-32x128

aws

32 vCPU

128 GB

sky-32x128

gcp

32 vCPU

128 GB

sky-64x256

aws

64 vCPU

256 GB

sky-64x256

gcp

64 vCPU

256 GB

REST Client

A REST client can use the SkySQL DBaaS API to query instance size selections and choose an instance size for a new service.

Query Database Node Options with REST Client

A REST client can query the SkySQL DBaaS API for the database node instance size selections for a specific cloud provider, architecture, and topology.

To see the available database node instance sizes for a topology, use curl to call the /provisioning/v1/sizes API endpoint with type=server set:

$ curl -sS --location \
   --header "Authorization: Bearer ${SKYSQL_API_KEY}" \
   'https://api.mariadb.com/provisioning/v1/sizes?architecture=amd64&service_type=transactional&provider=gcp&topology=es-replica&type=server' \
   | jq .
[
  {
    "id": "37629543-65d2-11ed-8da6-2228d0ae81af",
    "name": "sky-2x8",
    "display_name": "Sky-2x8",
    "service_type": "transactional",
    "provider": "gcp",
    "tier": "foundation",
    "architecture": "amd64",
    "cpu": "2 vCPU",
    "ram": "8 GB",
    "type": "server",
    "default_maxscale_size_name": "sky-2x8",
    "updated_on": "2022-11-16T17:15:06Z",
    "created_on": "2022-11-16T17:15:06Z",
    "is_active": true,
    "topology": "es-replica"
  },
  {
    "id": "37629489-65d2-11ed-8da6-2228d0ae81af",
    "name": "sky-4x16",
    "display_name": "Sky-4x16",
    "service_type": "transactional",
    "provider": "gcp",
    "tier": "foundation",
    "architecture": "amd64",
    "cpu": "4 vCPU",
    "ram": "16 GB",
    "type": "server",
    "default_maxscale_size_name": "sky-2x8",
    "updated_on": "2022-11-16T17:15:06Z",
    "created_on": "2022-11-16T17:15:06Z",
    "is_active": true,
    "topology": "es-replica"
  },
  {
    "id": "376292a9-65d2-11ed-8da6-2228d0ae81af",
    "name": "sky-4x32",
    "display_name": "Sky-4x32",
    "service_type": "transactional",
    "provider": "gcp",
    "tier": "foundation",
    "architecture": "amd64",
    "cpu": "4 vCPU",
    "ram": "32 GB",
    "type": "server",
    "default_maxscale_size_name": "sky-4x32",
    "updated_on": "2022-11-16T17:15:06Z",
    "created_on": "2022-11-16T17:15:06Z",
    "is_active": true,
    "topology": "es-replica"
  },
  {
    "id": "376292d0-65d2-11ed-8da6-2228d0ae81af",
    "name": "sky-8x32",
    "display_name": "Sky-8x32",
    "service_type": "transactional",
    "provider": "gcp",
    "tier": "foundation",
    "architecture": "amd64",
    "cpu": "8 vCPU",
    "ram": "32 GB",
    "type": "server",
    "default_maxscale_size_name": "sky-4x16",
    "updated_on": "2022-11-16T17:15:06Z",
    "created_on": "2022-11-16T17:15:06Z",
    "is_active": true,
    "topology": "es-replica"
  },
  {
    "id": "3762935b-65d2-11ed-8da6-2228d0ae81af",
    "name": "sky-8x64",
    "display_name": "Sky-8x64",
    "service_type": "transactional",
    "provider": "gcp",
    "tier": "foundation",
    "architecture": "amd64",
    "cpu": "8 vCPU",
    "ram": "64 GB",
    "type": "server",
    "default_maxscale_size_name": "sky-4x32",
    "updated_on": "2022-11-16T17:15:06Z",
    "created_on": "2022-11-16T17:15:06Z",
    "is_active": true,
    "topology": "es-replica"
  }
]

The output can show different instance sizes, depending on whether your SkySQL account is Foundation tier or Power tier.

For the database node instance size that you would like to select, extract the name attribute from the output and provide that value to the /provisioning/v1/services API endpoint as the size attribute.

Select Database Node Option with REST Client

A database node instance size is selected during service launch. When using a REST client, select an instance size for database nodes by calling the /provisioning/v1/services API endpoint with the size attribute set.

For example, prepare a request body containing the desired service options in a file called request-service.json:

$ cat > request-service.json <<EOF
{
  "service_type": "transactional",
  "topology": "es-single",
  "provider": "gcp",
  "region": "us-central1",
  "architecture": "amd64",
  "size": "sky-2x8",
  "storage": 100,
  "nodes": 1,
  "version": "10.6.11-6-1",
  "name": "skysql-nr-quickstart",
  "ssl_enabled": true
}
EOF

Then use curl to call the /provisioning/v1/services API endpoint to create (launch) a new database service and save the response to the response-service.json file:

$ curl -sS --location --request POST \
   --header "Authorization: Bearer ${SKYSQL_API_KEY}" \
   --header "Accept: application/json" \
   --header "Content-type: application/json" \
   --data '@request-service.json' \
   https://api.mariadb.com/provisioning/v1/services \
   | tee response-service.json | jq .

Upon success, the command will return JSON with details about the new service.

Query MaxScale Node Options with REST Client

A REST client can query the SkySQL DBaaS API for the MaxScale node instance size selections for a specific cloud provider, architecture, and topology.

To see the default MaxScale instance size for a topology, cloud, and architecture, use curl to call the /provisioning/v1/sizes API endpoint:

$ curl -sS --location \
   --header "Authorization: Bearer ${SKYSQL_API_KEY}" \
   'https://api.mariadb.com/provisioning/v1/sizes?provider=gcp&architecture=amd64&topology=es-replica' \
   | jq .
[
   {
     "id": "c0666ab8-4a3b-11ed-8853-b278760e6ab5",
     "name": "sky-2x8",
     "display_name": "Sky-2x8",
     "service_type": "transactional",
     "provider": "gcp",
     "tier": "foundation",
     "architecture": "amd64",
     "cpu": "2 vCPU",
     "ram": "8 GB",
     "type": "server",
     "default_maxscale_size_name": "sky-2x8",
     "updated_on": "2022-10-12T14:40:00Z",
     "created_on": "2022-10-12T14:40:00Z",
     "is_active": true,
     "topology": "es-replica"
   }
]

The default_maxscale_size_name attribute shows the default MaxScale instance size.

To see the available MaxScale node instance sizes for a topology, use curl to call the /provisioning/v1/sizes API endpoint with type=proxy set:

$ curl -sS --location \
   --header "Authorization: Bearer ${SKYSQL_API_KEY}" \
   'https://api.mariadb.com/provisioning/v1/sizes?architecture=amd64&service_type=transactional&provider=gcp&topology=es-replica&type=proxy' \
   | jq .

The output can show different instance sizes, depending on whether your SkySQL account is Foundation tier or Power tier.

For the MaxScale node instance size that you would like to select, extract the name attribute from the output and provide that value to the /provisioning/v1/services API endpoint as the maxscale_size attribute.

Select MaxScale Node Option with REST Client

A MaxScale node instance size is selected during service launch. When using a REST client and your SkySQL account has Power tier, select an instance size for MaxScale nodes by calling the /provisioning/v1/services API endpoint with the maxscale_size attribute set.

For example, prepare a request body containing the desired service options in a file called request-service.json:

$ cat > request-service.json <<EOF
{
  "service_type": "transactional",
  "topology": "es-replica",
  "provider": "gcp",
  "region": "us-central1",
  "architecture": "amd64",
  "size": "sky-2x8",
  "storage": 100,
  "nodes": 3,
  "maxscale_size": "sky-2x8",
  "maxscale_nodes": 2,
  "version": "10.6.11-6-1",
  "name": "skysql-nr-quickstart",
  "ssl_enabled": true
}
EOF

Then use curl to call the /provisioning/v1/services API endpoint to create (launch) a new database service and save the response to the response-service.json file:

$ curl -sS --location --request POST \
   --header "Authorization: Bearer ${SKYSQL_API_KEY}" \
   --header "Accept: application/json" \
   --header "Content-type: application/json" \
   --data '@request-service.json' \
   https://api.mariadb.com/provisioning/v1/services \
   | tee response-service.json | jq .

Upon success, the command will return JSON with details about the new service.

Terraform

Terraform can use the SkySQL Terraform provider to choose a database node or MaxScale node instance size for a new service.

Select Database Node Option with Terraform

When using Terraform, select an instance size for database nodes using the size attribute for the skysql_service resource:

# Create a service
resource "skysql_service" "default" {
  service_type        = "transactional"
  topology            = "es-single"
  cloud_provider      = "gcp"
  region              = "us-central1"
  architecture        = "amd64"
  size                = "sky-2x8"
  storage             = 100
  nodes               = 1
  version             = "10.6.11-6-1"
  name                = "skysql-nr-quickstart"
  ssl_enabled         = true
  deletion_protection = true
  wait_for_creation   = true
  wait_for_deletion   = true
  wait_for_update     = true
  is_active           = true
}

Select MaxScale Node Option with Terraform

When using Terraform and your SkySQL account has Power tier, select an instance size for MaxScale nodes using the maxscale_size attribute for the skysql_service resource:

# Create a service
resource "skysql_service" "default" {
  service_type        = "transactional"
  topology            = "es-replica"
  cloud_provider      = "gcp"
  region              = "us-central1"
  architecture        = "amd64"
  size                = "sky-2x8"
  storage             = 100
  nodes               = 3
  version             = "10.6.11-6-1"
  maxscale_size       = "sky-2x8"
  maxscale_nodes      = 2
  name                = "skysql-nr-quickstart"
  ssl_enabled         = true
  deletion_protection = true
  wait_for_creation   = true
  wait_for_deletion   = true
  wait_for_update     = true
  is_active           = true
}