finspace / Client / update_kx_dataview

update_kx_dataview#

finspace.Client.update_kx_dataview(**kwargs)#

Updates the specified dataview. The dataviews get automatically updated when any new changesets are ingested. Each update of the dataview creates a new version, including changeset details and cache configurations

See also: AWS API Documentation

Request Syntax

response = client.update_kx_dataview(
    environmentId='string',
    databaseName='string',
    dataviewName='string',
    description='string',
    changesetId='string',
    segmentConfigurations=[
        {
            'dbPaths': [
                'string',
            ],
            'volumeName': 'string',
            'onDemand': True|False
        },
    ],
    clientToken='string'
)
Parameters:
  • environmentId (string) –

    [REQUIRED]

    A unique identifier for the kdb environment, where you want to update the dataview.

  • databaseName (string) –

    [REQUIRED]

    The name of the database.

  • dataviewName (string) –

    [REQUIRED]

    The name of the dataview that you want to update.

  • description (string) – The description for a dataview.

  • changesetId (string) – A unique identifier for the changeset.

  • segmentConfigurations (list) –

    The configuration that contains the database path of the data that you want to place on each selected volume. Each segment must have a unique database path for each volume. If you do not explicitly specify any database path for a volume, they are accessible from the cluster through the default S3/object store segment.

    • (dict) –

      The configuration that contains the database path of the data that you want to place on each selected volume. Each segment must have a unique database path for each volume. If you do not explicitly specify any database path for a volume, they are accessible from the cluster through the default S3/object store segment.

      • dbPaths (list) – [REQUIRED]

        The database path of the data that you want to place on each selected volume for the segment. Each segment must have a unique database path for each volume.

        • (string) –

      • volumeName (string) – [REQUIRED]

        The name of the volume where you want to add data.

      • onDemand (boolean) –

        Enables on-demand caching on the selected database path when a particular file or a column of the database is accessed. When on demand caching is True, dataviews perform minimal loading of files on the filesystem as needed. When it is set to False, everything is cached. The default value is False.

  • clientToken (string) –

    [REQUIRED]

    A token that ensures idempotency. This token expires in 10 minutes.

    This field is autopopulated if not provided.

Return type:

dict

Returns:

Response Syntax

{
    'environmentId': 'string',
    'databaseName': 'string',
    'dataviewName': 'string',
    'azMode': 'SINGLE'|'MULTI',
    'availabilityZoneId': 'string',
    'changesetId': 'string',
    'segmentConfigurations': [
        {
            'dbPaths': [
                'string',
            ],
            'volumeName': 'string',
            'onDemand': True|False
        },
    ],
    'activeVersions': [
        {
            'changesetId': 'string',
            'segmentConfigurations': [
                {
                    'dbPaths': [
                        'string',
                    ],
                    'volumeName': 'string',
                    'onDemand': True|False
                },
            ],
            'attachedClusters': [
                'string',
            ],
            'createdTimestamp': datetime(2015, 1, 1),
            'versionId': 'string'
        },
    ],
    'status': 'CREATING'|'ACTIVE'|'UPDATING'|'FAILED'|'DELETING',
    'autoUpdate': True|False,
    'readWrite': True|False,
    'description': 'string',
    'createdTimestamp': datetime(2015, 1, 1),
    'lastModifiedTimestamp': datetime(2015, 1, 1)
}

Response Structure

  • (dict) –

    • environmentId (string) –

      A unique identifier for the kdb environment, where you want to update the dataview.

    • databaseName (string) –

      The name of the database.

    • dataviewName (string) –

      The name of the database under which the dataview was created.

    • azMode (string) –

      The number of availability zones you want to assign per volume. Currently, FinSpace only supports SINGLE for volumes. This places dataview in a single AZ.

    • availabilityZoneId (string) –

      The identifier of the availability zones.

    • changesetId (string) –

      A unique identifier for the changeset.

    • segmentConfigurations (list) –

      The configuration that contains the database path of the data that you want to place on each selected volume. Each segment must have a unique database path for each volume. If you do not explicitly specify any database path for a volume, they are accessible from the cluster through the default S3/object store segment.

      • (dict) –

        The configuration that contains the database path of the data that you want to place on each selected volume. Each segment must have a unique database path for each volume. If you do not explicitly specify any database path for a volume, they are accessible from the cluster through the default S3/object store segment.

        • dbPaths (list) –

          The database path of the data that you want to place on each selected volume for the segment. Each segment must have a unique database path for each volume.

          • (string) –

        • volumeName (string) –

          The name of the volume where you want to add data.

        • onDemand (boolean) –

          Enables on-demand caching on the selected database path when a particular file or a column of the database is accessed. When on demand caching is True, dataviews perform minimal loading of files on the filesystem as needed. When it is set to False, everything is cached. The default value is False.

    • activeVersions (list) –

      The current active changeset versions of the database on the given dataview.

      • (dict) –

        The active version of the dataview that is currently in use by this cluster.

        • changesetId (string) –

          A unique identifier for the changeset.

        • segmentConfigurations (list) –

          The configuration that contains the database path of the data that you want to place on each selected volume. Each segment must have a unique database path for each volume. If you do not explicitly specify any database path for a volume, they are accessible from the cluster through the default S3/object store segment.

          • (dict) –

            The configuration that contains the database path of the data that you want to place on each selected volume. Each segment must have a unique database path for each volume. If you do not explicitly specify any database path for a volume, they are accessible from the cluster through the default S3/object store segment.

            • dbPaths (list) –

              The database path of the data that you want to place on each selected volume for the segment. Each segment must have a unique database path for each volume.

              • (string) –

            • volumeName (string) –

              The name of the volume where you want to add data.

            • onDemand (boolean) –

              Enables on-demand caching on the selected database path when a particular file or a column of the database is accessed. When on demand caching is True, dataviews perform minimal loading of files on the filesystem as needed. When it is set to False, everything is cached. The default value is False.

        • attachedClusters (list) –

          The list of clusters that are currently using this dataview.

          • (string) –

        • createdTimestamp (datetime) –

          The timestamp at which the dataview version was active. The value is determined as epoch time in milliseconds. For example, the value for Monday, November 1, 2021 12:00:00 PM UTC is specified as 1635768000000.

        • versionId (string) –

          A unique identifier of the active version.

    • status (string) –

      The status of dataview creation.

      • CREATING – The dataview creation is in progress.

      • UPDATING – The dataview is in the process of being updated.

      • ACTIVE – The dataview is active.

    • autoUpdate (boolean) –

      The option to specify whether you want to apply all the future additions and corrections automatically to the dataview when new changesets are ingested. The default value is false.

    • readWrite (boolean) –

      Returns True if the dataview is created as writeable and False otherwise.

    • description (string) –

      A description of the dataview.

    • createdTimestamp (datetime) –

      The timestamp at which the dataview was created in FinSpace. The value is determined as epoch time in milliseconds. For example, the value for Monday, November 1, 2021 12:00:00 PM UTC is specified as 1635768000000.

    • lastModifiedTimestamp (datetime) –

      The last time that the dataview was updated in FinSpace. The value is determined as epoch time in milliseconds. For example, the value for Monday, November 1, 2021 12:00:00 PM UTC is specified as 1635768000000.

Exceptions

  • finspace.Client.exceptions.InternalServerException

  • finspace.Client.exceptions.ValidationException

  • finspace.Client.exceptions.ThrottlingException

  • finspace.Client.exceptions.AccessDeniedException

  • finspace.Client.exceptions.ResourceNotFoundException

  • finspace.Client.exceptions.ConflictException

  • finspace.Client.exceptions.ResourceAlreadyExistsException