Yandex Cloud
  • Сервисы
  • Решения
  • Почему Yandex Cloud
  • Сообщество
  • Тарифы
  • Документация
  • Связаться с нами
Подключиться
Language / Region
Проект Яндекса
© 2023 ООО «Яндекс.Облако»
Yandex Managed Service for Greenplum®
  • Начало работы
  • Пошаговые инструкции
    • Все инструкции
    • Информация об имеющихся кластерах
    • Расчет конфигурации кластера
    • Создание кластера
    • Подключение к базе данных
    • Остановка и запуск кластера
    • Управление хостами кластера
      • Просмотр хостов кластера
      • Расширение кластера
    • Изменение настроек кластера
    • Управление ролями и пользователями
    • Управление клиентскими процессами
    • Использование внешних таблиц
    • Расширения Greenplum
      • Управление расширениями
      • pgcrypto
      • uuid-cb
    • Управление резервными копиями
    • Просмотр логов кластера
    • Удаление кластера
    • Диагностика производительности
    • Мониторинг состояния кластера и хостов
    • Управление ресурсными группами
  • Практические руководства
    • Миграция базы данных в Managed Service for Greenplum®
    • Создание внешней таблицы на базе таблицы из бакета Yandex Object Storage с помощью конфигурационного файла
    • Миграция базы данных из Greenplum® в PostgreSQL
    • Миграция базы данных из Greenplum® в ClickHouse
  • Концепции
    • Взаимосвязь ресурсов сервиса
    • Классы хостов
    • Сеть в Managed Service for Greenplum®
    • Квоты и лимиты
    • Типы дисков
    • Резервные копии
    • Ресурсные группы
    • Шардирование
    • Типы хранения данных
    • Пользователи и роли
    • Техническое обслуживание
    • Настройки Greenplum®
  • Управление доступом
  • Правила тарификации
  • Справочник API
    • Аутентификация в API
    • gRPC (англ.)
      • Overview
      • BackupService
      • ClusterService
      • ResourcePresetService
      • OperationService
    • REST (англ.)
      • Overview
      • Backup
        • Overview
        • get
        • list
      • Cluster
        • Overview
        • create
        • delete
        • expand
        • get
        • list
        • listBackups
        • listLogs
        • listMasterHosts
        • listOperations
        • listSegmentHosts
        • restore
        • start
        • stop
        • streamLogs
        • update
      • ResourcePreset
        • Overview
        • get
        • list
      • Operation
        • Overview
        • get
  • История изменений
  • Вопросы и ответы
    • Общие вопросы
    • Подключение
    • Резервное копирование
    • Изменение кластера
    • Кластер и хосты Managed Service for Greenplum®
    • Работа с внешними таблицами
    • Управление пользователями
    • Мониторинг и логи
    • Все вопросы на одной странице
  1. Справочник API
  2. REST (англ.)
  3. Cluster
  4. create

Managed Service for Greenplum® API, REST: Cluster.create

Статья создана
Yandex Cloud
  • HTTP request
  • Body parameters
  • Response

Creates a Greenplum® cluster in the specified folder.

HTTP request

POST https://mdb.api.cloud.yandex.net/managed-greenplum/v1/clusters

Body parameters

{
  "folderId": "string",
  "name": "string",
  "description": "string",
  "labels": "object",
  "environment": "string",
  "config": {
    "version": "string",
    "backupWindowStart": {
      "hours": "integer",
      "minutes": "integer",
      "seconds": "integer",
      "nanos": "integer"
    },
    "access": {
      "dataLens": true,
      "webSql": true,
      "dataTransfer": true
    },
    "zoneId": "string",
    "subnetId": "string",
    "assignPublicIp": true
  },
  "masterConfig": {
    "resources": {
      "resourcePresetId": "string",
      "diskSize": "string",
      "diskTypeId": "string"
    }
  },
  "segmentConfig": {
    "resources": {
      "resourcePresetId": "string",
      "diskSize": "string",
      "diskTypeId": "string"
    }
  },
  "masterHostCount": "string",
  "segmentInHost": "string",
  "segmentHostCount": "string",
  "userName": "string",
  "userPassword": "string",
  "networkId": "string",
  "securityGroupIds": [
    "string"
  ],
  "deletionProtection": true,
  "hostGroupIds": [
    "string"
  ],
  "maintenanceWindow": {

    // `maintenanceWindow` includes only one of the fields `anytime`, `weeklyMaintenanceWindow`
    "anytime": {},
    "weeklyMaintenanceWindow": {
      "day": "string",
      "hour": "string"
    },
    // end of the list of possible fields`maintenanceWindow`

  },
  "configSpec": {
    "pool": {
      "mode": "string",
      "size": "integer",
      "clientIdleTimeout": "integer"
    },

    // `configSpec` includes only one of the fields `greenplumConfig_6_17`, `greenplumConfig_6_19`
    "greenplumConfig_6_17": {
      "maxConnections": "integer",
      "maxSlotWalKeepSize": "integer",
      "gpWorkfileLimitPerSegment": "integer",
      "gpWorkfileLimitPerQuery": "integer",
      "gpWorkfileLimitFilesPerQuery": "integer",
      "maxPreparedTransactions": "integer",
      "gpWorkfileCompression": true
    },
    "greenplumConfig_6_19": {
      "maxConnections": "integer",
      "maxSlotWalKeepSize": "integer",
      "gpWorkfileLimitPerSegment": "integer",
      "gpWorkfileLimitPerQuery": "integer",
      "gpWorkfileLimitFilesPerQuery": "integer",
      "maxPreparedTransactions": "integer",
      "gpWorkfileCompression": true,
      "maxStatementMem": "integer",
      "logStatement": "string"
    },
    // end of the list of possible fields`configSpec`

  }
}
Field Description
folderId string

Required. ID of the folder to create the Greenplum® cluster in.

The maximum string length in characters is 50.

name string

Required. Name of the Greenplum® cluster. The name must be unique within the folder.

The maximum string length in characters is 63. Value must match the regular expression [a-zA-Z0-9_-]*.

description string

Description of the Greenplum® cluster.

The maximum string length in characters is 256.

labels object

Custom labels for the Greenplum® cluster as key:value pairs. For example, "project":"mvp" or "source":"dictionary".

No more than 64 per resource. The maximum string length in characters for each key is 63. Each key must match the regular expression [a-z][-_0-9a-z]*. The maximum string length in characters for each value is 63. Each value must match the regular expression [-_0-9a-z]*.

environment string

Required. Deployment environment of the Greenplum® cluster.

  • PRODUCTION: Stable environment with a conservative update policy: only hotfixes are applied during regular maintenance.
  • PRESTABLE: Environment with more aggressive update policy: new versions are rolled out irrespective of backward compatibility.
config object

Greenplum® cluster configuration.

config.
version
string

Version of the Greenplum® server software.

config.
backupWindowStart
object

Time to start the daily backup, in the UTC timezone.

Represents a time of day. The date and time zone are either not significant or are specified elsewhere. An API may choose to allow leap seconds. Related types are google.type.Date and google.protobuf.Timestamp.

config.
backupWindowStart.
hours
integer (int32)

Hours of day in 24 hour format. Should be from 0 to 23. An API may choose to allow the value "24:00:00" for scenarios like business closing time.

config.
backupWindowStart.
minutes
integer (int32)

Minutes of hour of day. Must be from 0 to 59.

config.
backupWindowStart.
seconds
integer (int32)

Seconds of minutes of the time. Must normally be from 0 to 59. An API may allow the value 60 if it allows leap-seconds.

config.
backupWindowStart.
nanos
integer (int32)

Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999.

config.
access
object

Access policy for external services.

config.
access.
dataLens
boolean (boolean)

Allows data export from the cluster to DataLens.

config.
access.
webSql
boolean (boolean)

Allows SQL queries to the cluster databases from the management console.

config.
access.
dataTransfer
boolean (boolean)

Allows access for DataTransfer.

config.
zoneId
string

ID of the availability zone the cluster belongs to. To get a list of available zones, use the list request.

The maximum string length in characters is 50.

config.
subnetId
string

ID of the subnet the cluster belongs to. This subnet should be a part of the cloud network the cluster belongs to (see Cluster.networkId).

The maximum string length in characters is 50.

config.
assignPublicIp
boolean (boolean)

Determines whether the cluster has a public IP address.

After the cluster has been created, this setting cannot be changed.

masterConfig object

Configuration of the Greenplum® master subcluster.

masterConfig.
resources
object

Resources allocated to Greenplum® master subcluster hosts.

masterConfig.
resources.
resourcePresetId
string

ID of the preset for computational resources allocated to a host.

Available presets are listed in the documentation.

masterConfig.
resources.
diskSize
string (int64)

Volume of the storage used by the host, in bytes.

masterConfig.
resources.
diskTypeId
string

Type of the storage used by the host: network-hdd, network-ssd or local-ssd.

segmentConfig object

Configuration of the Greenplum® segment subcluster.

segmentConfig.
resources
object

Resources allocated to Greenplum® segment subcluster hosts.

segmentConfig.
resources.
resourcePresetId
string

ID of the preset for computational resources allocated to a host.

Available presets are listed in the documentation.

segmentConfig.
resources.
diskSize
string (int64)

Volume of the storage used by the host, in bytes.

segmentConfig.
resources.
diskTypeId
string

Type of the storage used by the host: network-hdd, network-ssd or local-ssd.

masterHostCount string (int64)

Number of hosts in the master subcluster.

segmentInHost string (int64)

Number of segments per host.

segmentHostCount string (int64)

Number of hosts in the segment subcluster.

userName string

Required. Owner user name.

userPassword string

Required. Owner user password.

The string length in characters must be 8-128.

networkId string

Required. ID of the network to create the cluster in.

The maximum string length in characters is 50.

securityGroupIds[] string

User security groups.

deletionProtection boolean (boolean)

Determines whether the cluster is protected from being deleted.

hostGroupIds[] string

Host groups to place VMs of the cluster in.

maintenanceWindow object

A Greenplum® cluster maintenance window. Should be defined by either one of the two options.

maintenanceWindow.
anytime
object
An any-time maintenance window.
maintenanceWindow includes only one of the fields anytime, weeklyMaintenanceWindow
maintenanceWindow.
weeklyMaintenanceWindow
object
A weekly maintenance window.
maintenanceWindow includes only one of the fields anytime, weeklyMaintenanceWindow
maintenanceWindow.
weeklyMaintenanceWindow.
day
string

Day of the week.

  • MON: Monday
  • TUE: Tuesday
  • WED: Wednesday
  • THU: Thursday
  • FRI: Friday
  • SAT: Saturday
  • SUN: Sunday
maintenanceWindow.
weeklyMaintenanceWindow.
hour
string (int64)

Hour of the day in the UTC timezone.

Acceptable values are 1 to 24, inclusive.

configSpec object

Configuration of Greenplum® and Odyssey®.

configSpec.
pool
object
Odyssey® pool settings.
configSpec.
pool.
mode
string

Route server pool mode.

  • SESSION: Assign server connection to a client until it disconnects. Default value.
  • TRANSACTION: Assign server connection to a client for a transaction processing.
configSpec.
pool.
size
integer (int64)

The number of servers in the server pool. Clients are placed in a wait queue when all servers are busy.

Set to zero to disable the limit.

configSpec.
pool.
clientIdleTimeout
integer (int64)

Server pool idle timeout, in seconds.

A server connection closes after being idle for the specified time.

Set to zero to disable the limit.

configSpec.
greenplumConfig_6_17
object
configSpec includes only one of the fields greenplumConfig_6_17, greenplumConfig_6_19
configSpec.
greenplumConfig_6_17.
maxConnections
integer (int64)

Maximum number of inbound connections on master segment.

configSpec.
greenplumConfig_6_17.
maxSlotWalKeepSize
integer (int64)

The maximum size of WAL files that replication slots are allowed to retain in the pg_wal directory at checkpoint time.

More info in PostgreSQL® documentation.

configSpec.
greenplumConfig_6_17.
gpWorkfileLimitPerSegment
integer (int64)

The maximum total disk size that all running queries are allowed to use for creating temporary spill files at each segment.

The default value is 0 (no limit).

More info in Greenplum® documentation.

configSpec.
greenplumConfig_6_17.
gpWorkfileLimitPerQuery
integer (int64)

The maximum disk size that an individual query is allowed to use for creating temporary spill files at each segment.

The default value is 0 (no limit).

More info in Greenplum® documentation.

configSpec.
greenplumConfig_6_17.
gpWorkfileLimitFilesPerQuery
integer (int64)

The maximum number of temporary spill files allowed per query at each segment.

Spill files, also known as workfiles, are created when a query requires more memory than there is allocated.

The current query is terminated if the limit is exceeded.

Set to zero to disable the limit.

Master session reloads if the parameter changes.

Default value is 10000.

More info in Greenplum® documentation.

configSpec.
greenplumConfig_6_17.
maxPreparedTransactions
integer (int64)

The maximum number of transactions that can be in the prepared state simultaneously.

More info in PostgreSQL® documentation.

configSpec.
greenplumConfig_6_17.
gpWorkfileCompression
boolean (boolean)

Whether the spill files are compressed or not.

More info in Greenplum® documentation.

configSpec.
greenplumConfig_6_19
object
configSpec includes only one of the fields greenplumConfig_6_17, greenplumConfig_6_19
configSpec.
greenplumConfig_6_19.
maxConnections
integer (int64)

Maximum number of inbound connections on master segment.

configSpec.
greenplumConfig_6_19.
maxSlotWalKeepSize
integer (int64)

The maximum size of WAL files that replication slots are allowed to retain in the pg_wal directory at checkpoint time.

More info in PostgreSQL® documentation.

configSpec.
greenplumConfig_6_19.
gpWorkfileLimitPerSegment
integer (int64)

The maximum total disk size that all running queries are allowed to use for creating temporary spill files at each segment.

The default value is 0 (no limit).

More info in Greenplum® documentation.

configSpec.
greenplumConfig_6_19.
gpWorkfileLimitPerQuery
integer (int64)

The maximum disk size that an individual query is allowed to use for creating temporary spill files at each segment.

The default value is 0 (no limit).

More info in Greenplum® documentation.

configSpec.
greenplumConfig_6_19.
gpWorkfileLimitFilesPerQuery
integer (int64)

The maximum number of temporary spill files allowed per query at each segment.

Spill files, also known as workfiles, are created when a query requires more memory than there is allocated.

The current query is terminated if the limit is exceeded.

Set to zero to disable the limit.

Master session reloads if the parameter changes.

Default value is 10000.

More info in Greenplum® documentation.

configSpec.
greenplumConfig_6_19.
maxPreparedTransactions
integer (int64)

The maximum number of transactions that can be in the prepared state simultaneously.

More info in PostgreSQL® documentation.

configSpec.
greenplumConfig_6_19.
gpWorkfileCompression
boolean (boolean)

Whether the spill files are compressed or not.

More info in Greenplum® documentation.

configSpec.
greenplumConfig_6_19.
maxStatementMem
integer (int64)

The maximum memory limit for a query, in bytes.

Helps to avoid out-of-memory errors on a segment host during query processing as a result of setting statement_mem too high.

Taking into account the configuration of a single segment host, calculate maxStatementMem as follows: seghost_physical_memory / average_number_concurrent_queries.

When changing both maxStatementMem and statement_mem, maxStatementMem must be changed first, or listed first in the postgresql.conf file.

Default value is 2097152000 (2000 MB).

More info in Greenplum® documentation.

configSpec.
greenplumConfig_6_19.
logStatement
string

Logged SQL statements.

PREPARE and EXPLAIN ANALYZE statements are also logged if their contained command belongs to an appropriate type.

More info in Greenplum® documentation.

  • NONE: None statements are logged.
  • DDL: Logs all data definition commands like CREATE, ALTER, and DROP. Default value.
  • MOD: Logs all DDL statements, plus INSERT, UPDATE, DELETE, TRUNCATE, and COPY FROM.
  • ALL: Logs all statements.

Response

HTTP Code: 200 - OK

{
  "id": "string",
  "description": "string",
  "createdAt": "string",
  "createdBy": "string",
  "modifiedAt": "string",
  "done": true,
  "metadata": "object",

  //  includes only one of the fields `error`, `response`
  "error": {
    "code": "integer",
    "message": "string",
    "details": [
      "object"
    ]
  },
  "response": "object",
  // end of the list of possible fields

}

An Operation resource. For more information, see Operation.

Field Description
id string

ID of the operation.

description string

Description of the operation. 0-256 characters long.

createdAt string (date-time)

Creation timestamp.

String in RFC3339 text format. The range of possible values is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z, i.e. from 0 to 9 digits for fractions of a second.

To work with values in this field, use the APIs described in the Protocol Buffers reference. In some languages, built-in datetime utilities do not support nanosecond precision (9 digits).

createdBy string

ID of the user or service account who initiated the operation.

modifiedAt string (date-time)

The time when the Operation resource was last modified.

String in RFC3339 text format. The range of possible values is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z, i.e. from 0 to 9 digits for fractions of a second.

To work with values in this field, use the APIs described in the Protocol Buffers reference. In some languages, built-in datetime utilities do not support nanosecond precision (9 digits).

done boolean (boolean)

If the value is false, it means the operation is still in progress. If true, the operation is completed, and either error or response is available.

metadata object

Service-specific metadata associated with the operation. It typically contains the ID of the target resource that the operation is performed on. Any method that returns a long-running operation should document the metadata type, if any.

error object
The error result of the operation in case of failure or cancellation.
includes only one of the fields error, response
error.
code
integer (int32)

Error code. An enum value of google.rpc.Code.

error.
message
string

An error message.

error.
details[]
object

A list of messages that carry the error details.

response object
includes only one of the fields error, response

The normal response of the operation in case of success. If the original method returns no data on success, such as Delete, the response is google.protobuf.Empty. If the original method is the standard Create/Update, the response should be the target resource of the operation. Any method that returns a long-running operation should document the response type, if any.

Была ли статья полезна?

Language / Region
Проект Яндекса
© 2023 ООО «Яндекс.Облако»
В этой статье:
  • HTTP request
  • Body parameters
  • Response