Skip to main content

ClickHouse

ClickHouse is a fast open-source column-oriented database management system optimized for real-time analytics.

Resources

Service

Create, manage and delete ClickHouse services.
import { OrganizationRef, Service } from "alchemy/clickhouse";

const organization = await OrganizationRef("Alchemy's Organization");
const service = await Service("clickhouse", {
  organization,
  provider: "aws",
  region: "us-east-1"
});

Props

organization
string | Organization
required
The ID, name, or OrganizationRef of ClickHouse cloud organization to create the service in
provider
string
required
The underlying cloud provider to create the service on (e.g., “aws”, “gcp”, “azure”)
region
string
required
The region to create the service in
name
string
default:"${app}-${stage}-${id}"
The name of the ClickHouse service to create
keyId
string | Secret
The key ID for the ClickHouse API
secret
string | Secret
The secret for the ClickHouse API
ipAccessList
array
The IP access list to create the service with
minReplicaMemoryGb
number
default:"8"
The minimum replica memory to create the service with
maxReplicaMemoryGb
number
default:"356"
The maximum replica memory to create the service with
numReplicas
number
default:"3"
The number of replicas to create the service with
idleScaling
boolean
default:"true"
Whether to enable idle scaling
idleTimeoutMinutes
number
default:"15"
The timeout minutes for idle scaling
isReadonly
boolean
default:"false"
Whether to make the service readonly
releaseChannel
string
default:"default"
The release channel to create the service with
stateTarget
'start' | 'stop'
default:"start"
The desired state of the service
enableMysqlEndpoint
boolean
default:"true"
Whether to enable the MySQL endpoint
enableHttpsEndpoint
boolean
default:"true"
Whether to enable the HTTPS endpoint. Cannot be disabled
enableNativesecureEndpoint
boolean
default:"true"
Whether to enable the nativesecure endpoint. Cannot be disabled
waitForHttpEndpointReady
boolean
default:"true"
Wait for HTTP service to be ready before marking the resource as created

Returns

organizationId
string
The ID of ClickHouse cloud organization the service is in
name
string
The name of the ClickHouse service
clickhouseId
string
The ClickHouse ID of the service
password
Secret
The password for the ClickHouse service
provider
string
The provider of the ClickHouse service
region
string
The region of the ClickHouse service
ipAccessList
array
The IP access list of the ClickHouse service
minReplicaMemoryGb
number
The minimum replica memory of the ClickHouse service
maxReplicaMemoryGb
number
The maximum replica memory of the ClickHouse service
numReplicas
number
The number of replicas of the ClickHouse service
idleScaling
boolean
Whether idle scaling is enabled for the ClickHouse service
idleTimeoutMinutes
number
The timeout minutes for idle scaling of the ClickHouse service
mysqlEndpoint
object
The MySQL endpoint details of the ClickHouse service
httpsEndpoint
object
The HTTPS endpoint details of the ClickHouse service
nativesecureEndpoint
object
The nativesecure endpoint details of the ClickHouse service
state
string
The state of the ClickHouse service

Build docs developers (and LLMs) love