Google BigQuery Connection V1 Client - Class CloudSpannerProperties (1.5.0)

Reference documentation and code samples for the Google BigQuery Connection V1 Client class CloudSpannerProperties.

Connection properties specific to Cloud Spanner.

Generated from protobuf message google.cloud.bigquery.connection.v1.CloudSpannerProperties

Namespace

Google \ Cloud \ BigQuery \ Connection \ V1

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ database string

Cloud Spanner database in the form `project/instance/database'

↳ use_parallelism bool

If parallelism should be used when reading from Cloud Spanner

↳ max_parallelism int

Allows setting max parallelism per query when executing on Spanner independent compute resources. If unspecified, default values of parallelism are chosen that are dependent on the Cloud Spanner instance configuration. REQUIRES: use_parallelism must be set. REQUIRES: Either use_data_boost or use_serverless_analytics must be set.

↳ use_serverless_analytics bool

If the serverless analytics service should be used to read data from Cloud Spanner. Note: use_parallelism must be set when using serverless analytics.

↳ use_data_boost bool

If set, the request will be executed via Spanner independent compute resources. REQUIRES: use_parallelism must be set. NOTE: use_serverless_analytics will be deprecated. Prefer use_data_boost over use_serverless_analytics.

↳ database_role string

Optional. Cloud Spanner database role for fine-grained access control. The Cloud Spanner admin should have provisioned the database role with appropriate permissions, such as SELECT and INSERT. Other users should only use roles provided by their Cloud Spanner admins. For more details, see About fine-grained access control. REQUIRES: The database role name must start with a letter, and can only contain letters, numbers, and underscores.

getDatabase

Cloud Spanner database in the form `project/instance/database'

Returns
TypeDescription
string

setDatabase

Cloud Spanner database in the form `project/instance/database'

Parameter
NameDescription
var string
Returns
TypeDescription
$this

getUseParallelism

If parallelism should be used when reading from Cloud Spanner

Returns
TypeDescription
bool

setUseParallelism

If parallelism should be used when reading from Cloud Spanner

Parameter
NameDescription
var bool
Returns
TypeDescription
$this

getMaxParallelism

Allows setting max parallelism per query when executing on Spanner independent compute resources. If unspecified, default values of parallelism are chosen that are dependent on the Cloud Spanner instance configuration.

REQUIRES: use_parallelism must be set. REQUIRES: Either use_data_boost or use_serverless_analytics must be set.

Returns
TypeDescription
int

setMaxParallelism

Allows setting max parallelism per query when executing on Spanner independent compute resources. If unspecified, default values of parallelism are chosen that are dependent on the Cloud Spanner instance configuration.

REQUIRES: use_parallelism must be set. REQUIRES: Either use_data_boost or use_serverless_analytics must be set.

Parameter
NameDescription
var int
Returns
TypeDescription
$this

getUseServerlessAnalytics

If the serverless analytics service should be used to read data from Cloud Spanner.

Note: use_parallelism must be set when using serverless analytics.

Returns
TypeDescription
bool

setUseServerlessAnalytics

If the serverless analytics service should be used to read data from Cloud Spanner.

Note: use_parallelism must be set when using serverless analytics.

Parameter
NameDescription
var bool
Returns
TypeDescription
$this

getUseDataBoost

If set, the request will be executed via Spanner independent compute resources.

REQUIRES: use_parallelism must be set. NOTE: use_serverless_analytics will be deprecated. Prefer use_data_boost over use_serverless_analytics.

Returns
TypeDescription
bool

setUseDataBoost

If set, the request will be executed via Spanner independent compute resources.

REQUIRES: use_parallelism must be set. NOTE: use_serverless_analytics will be deprecated. Prefer use_data_boost over use_serverless_analytics.

Parameter
NameDescription
var bool
Returns
TypeDescription
$this

getDatabaseRole

Optional. Cloud Spanner database role for fine-grained access control.

The Cloud Spanner admin should have provisioned the database role with appropriate permissions, such as SELECT and INSERT. Other users should only use roles provided by their Cloud Spanner admins. For more details, see About fine-grained access control. REQUIRES: The database role name must start with a letter, and can only contain letters, numbers, and underscores.

Returns
TypeDescription
string

setDatabaseRole

Optional. Cloud Spanner database role for fine-grained access control.

The Cloud Spanner admin should have provisioned the database role with appropriate permissions, such as SELECT and INSERT. Other users should only use roles provided by their Cloud Spanner admins. For more details, see About fine-grained access control. REQUIRES: The database role name must start with a letter, and can only contain letters, numbers, and underscores.

Parameter
NameDescription
var string
Returns
TypeDescription
$this