Google Cloud Dataplex V1 Client - Class Schema (0.1.6)

Reference documentation and code samples for the Google Cloud Dataplex V1 Client class Schema.

Schema information describing the structure and layout of the data.

Generated from protobuf message google.cloud.dataplex.v1.Schema

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ user_managed bool

Required. Whether the schema is user-managed or managed by the service. - Set user_manage to false if you would like Dataplex to help you manage the schema. You will get the full service provided by Dataplex discovery, including new data discovery, schema inference and schema evolution. You can still provide input the schema of the entities, for example renaming a schema field, changing CSV or Json options if you think the discovered values are not as accurate. Dataplex will consider your input as the initial schema (as if they were produced by the previous discovery run), and will evolve schema or flag actions based on that. - Set user_manage to true if you would like to fully manage the entity schema by yourself. This is useful when you would like to manually specify the schema for a table. In this case, the schema defined by the user is guaranteed to be kept unchanged and would not be overwritten. But this also means Dataplex will not provide schema evolution management for you. Dataplex will still be able to manage partition registration (i.e., keeping the list of partitions up to date) when Dataplex discovery is turned on and user_managed is set to true.

↳ fields array<Google\Cloud\Dataplex\V1\Schema\SchemaField>

Optional. The sequence of fields describing data in table entities.

↳ partition_fields array<Google\Cloud\Dataplex\V1\Schema\PartitionField>

Optional. The sequence of fields describing the partition structure in entities. If this field is empty, there are no partitions within the data.

↳ partition_style int

Optional. The structure of paths containing partition data within the entity.

getUserManaged

Required. Whether the schema is user-managed or managed by the service.

  • Set user_manage to false if you would like Dataplex to help you manage the schema. You will get the full service provided by Dataplex discovery, including new data discovery, schema inference and schema evolution. You can still provide input the schema of the entities, for example renaming a schema field, changing CSV or Json options if you think the discovered values are not as accurate. Dataplex will consider your input as the initial schema (as if they were produced by the previous discovery run), and will evolve schema or flag actions based on that.
  • Set user_manage to true if you would like to fully manage the entity schema by yourself. This is useful when you would like to manually specify the schema for a table. In this case, the schema defined by the user is guaranteed to be kept unchanged and would not be overwritten. But this also means Dataplex will not provide schema evolution management for you. Dataplex will still be able to manage partition registration (i.e., keeping the list of partitions up to date) when Dataplex discovery is turned on and user_managed is set to true.

Generated from protobuf field bool user_managed = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
bool

setUserManaged

Required. Whether the schema is user-managed or managed by the service.

  • Set user_manage to false if you would like Dataplex to help you manage the schema. You will get the full service provided by Dataplex discovery, including new data discovery, schema inference and schema evolution. You can still provide input the schema of the entities, for example renaming a schema field, changing CSV or Json options if you think the discovered values are not as accurate. Dataplex will consider your input as the initial schema (as if they were produced by the previous discovery run), and will evolve schema or flag actions based on that.
  • Set user_manage to true if you would like to fully manage the entity schema by yourself. This is useful when you would like to manually specify the schema for a table. In this case, the schema defined by the user is guaranteed to be kept unchanged and would not be overwritten. But this also means Dataplex will not provide schema evolution management for you. Dataplex will still be able to manage partition registration (i.e., keeping the list of partitions up to date) when Dataplex discovery is turned on and user_managed is set to true.

Generated from protobuf field bool user_managed = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
var bool
Returns
TypeDescription
$this

getFields

Optional. The sequence of fields describing data in table entities.

Generated from protobuf field repeated .google.cloud.dataplex.v1.Schema.SchemaField fields = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setFields

Optional. The sequence of fields describing data in table entities.

Generated from protobuf field repeated .google.cloud.dataplex.v1.Schema.SchemaField fields = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
var array<Google\Cloud\Dataplex\V1\Schema\SchemaField>
Returns
TypeDescription
$this

getPartitionFields

Optional. The sequence of fields describing the partition structure in entities.

If this field is empty, there are no partitions within the data.

Generated from protobuf field repeated .google.cloud.dataplex.v1.Schema.PartitionField partition_fields = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setPartitionFields

Optional. The sequence of fields describing the partition structure in entities.

If this field is empty, there are no partitions within the data.

Generated from protobuf field repeated .google.cloud.dataplex.v1.Schema.PartitionField partition_fields = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
var array<Google\Cloud\Dataplex\V1\Schema\PartitionField>
Returns
TypeDescription
$this

getPartitionStyle

Optional. The structure of paths containing partition data within the entity.

Generated from protobuf field .google.cloud.dataplex.v1.Schema.PartitionStyle partition_style = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

setPartitionStyle

Optional. The structure of paths containing partition data within the entity.

Generated from protobuf field .google.cloud.dataplex.v1.Schema.PartitionStyle partition_style = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
var int
Returns
TypeDescription
$this