This topic gives you reference information about the Google Spanner service (csb-google-spanner). It details the plans, configuration parameters, and binding credentials.
Caution The Google Spanner service offering is currently in beta and is intended for evaluation and test purposes only. Do not use this product in a production environment.
The table below lists the plans for Google Spanner:
Plan | Description |
---|---|
small | Single Node Spanner with 10 GB storage |
medium | 2 Nodes Spanner with 20 GB storage |
large | 3 Nodes and Multi Region Spanner with 100 GB storage |
When configuring Cloud Service Broker for GCP you can add additional plans. For how to configure plans, see Configure Services with Cloud Service Broker for GCP.
The following table lists parameters which can only be configured for additional plans:
Parameter Name | Values | Default |
---|---|---|
name * |
The plan name | n/a |
id * |
A unique GUID | n/a |
description * |
Description of the new plan | n/a |
num_nodes * |
Minimum number of cores for service instance, 1–64 | 1 |
storage_gb * |
Size of storage volume for service instance, 10–4096 | 10 |
display_name |
Name to use when displaying plan in marketplace | n/a |
free |
When false, Service Instances of this Service Plan have a cost | true |
bindable |
Specifies whether Service Instances of the Service Plan can bind to applications | true |
plan_updateable |
Whether the Plan supports upgrade/downgrade/sidegrade to another version | true |
* Required
You can also add any of the configuration parameters listed in the parameters section to your plan.
Note If you set a parameter at plan level, developers cannot change the value when creating or updating service instances.
You can provision a service by running:
cf create-service csb-google-spanner PLAN-NAME SERVICE-INSTANCE-NAME -c '{"PARAMETER-NAME": "PARAMETER-VALUE"}'
You can update the configuration parameters for a service instance by running:
cf update-service SERVICE-INSTANCE-NAME -c '{"PARAMETER-NAME": "PARAMETER-VALUE"}'
The following table lists the parameters that you can configure, by using the -c
flag, when provisioning a csb-google-spanner service:
Parameter Name | Type | Description | Default | Operation |
---|---|---|---|---|
instance_name |
string | The name of the spanner instance to create. | csb-spanner-INSTANCE-ID |
provision and update |
db_name |
string | The name of the database to create. | csb-spanner |
provision and update |
config |
string | The name of the instance's configuration that defines the geographic placement and replication of your databases in this instance. Similar to, but not quite the same as a region. | us-central1 |
provision and update |
ddl |
array | An optional list of DDL statements to run inside the newly created database. | [] |
provision and update |
region |
string | The region of the spanner instance. | us-central1 |
provision and update |
credentials |
string | The GCP credentials. | The value the operator entered for Credentials in Ops Manager. | provision and update |
project |
string | The GCP project to use. | The value the operator entered for Project in Ops Manager. | provision and update |
You can bind a service by running:
cf bind-service APP-NAME SERVICE-INSTANCE --binding-name BINDING-NAME -c '{"PARAMETER-NAME": "PARAMETER-VALUE"}'
The following table lists the parameters that you can configure, by using the -c
flag, when binding to a csb-google-spanner service:
Parameter Name | Type | Description | Default |
---|---|---|---|
role |
string | The role for the account. For more information, see the Google Cloud documentation. Your operator can override the default enumeration. | roles/editor |
credentials |
string | The GCP credentials. | The value the operator entered for Credentials in Ops Manager. |
The format for binding credentials for Google Spanner is as follows:
{
"db_name" : "DATABASE-NAME",
"instance" : "INSTANCE-NAME",
"Credentials" : "SERVICE-ACCOUNT-CREDENTIALS",
"Email" : "SERVICE-ACCOUNT-EMAIL",
"Name" : "SERVICE-ACCOUNT-NAME",
"PrivateKeyData" : "SERVICE-ACCOUNT-PRIVATE-KEY",
"ProjectId" : "GCP-PROJECT-ID",
"UniqueId" : "SERVICE-ACCOUNT-UNIQUE-ID",
"policy_etag": "IAM-POLICY-ETAG",
"binding_etag": "IAM-BINDING-ETAG",
"member_etag": "IAM-MEMBER-ETAG"
}