Skip to content

put_data_catalog_export_configuration

put_data_catalog_export_configuration(
    export_setting: ExportSetting,
    *,
    config_overrides: Optional[GlueClientConfig] = None,
    encryption_configuration: Optional[ExportEncryptionConfiguration] = None,
    client_token: Optional[HashString] = None,
) -> PutDataCatalogExportConfigurationOutput

Creates or updates the export configuration for the Glue Data Catalog. Use this operation to enable or disable the export of catalog metadata to S3 Tables.

Parameters:

  • export_setting (ExportSetting) –

    The export setting for the data catalog. Specify ENABLED to start exporting catalog metadata to S3 Tables, or DISABLED to stop exporting. This field is required.

  • encryption_configuration (Optional[ExportEncryptionConfiguration], default: None ) –

    The encryption configuration for the exported data. If not specified, the default encryption settings are used.

  • client_token (Optional[HashString], default: None ) –

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.

Raises:

Source code in docs_src/capo_glue/_services/glue.py
def put_data_catalog_export_configuration(
    self,
    export_setting: "capo_glue.types.export_setting.ExportSetting",
    *,
    config_overrides: Optional[GlueClientConfig] = None,
    encryption_configuration: Optional[
        "capo_glue.types.export_encryption_configuration.ExportEncryptionConfiguration"
    ] = None,
    client_token: Optional["capo_glue.types.hash_string.HashString"] = None,
) -> "capo_glue.types.put_data_catalog_export_configuration_output.PutDataCatalogExportConfigurationOutput":
    """<p>Creates or updates the export configuration for the Glue Data Catalog. Use this operation to enable or disable the export of catalog metadata to S3 Tables.</p>

    Args:
        export_setting: <p>The export setting for the data catalog. Specify <code>ENABLED</code> to start exporting catalog metadata to S3 Tables, or <code>DISABLED</code> to stop exporting. This field is required.</p>
        encryption_configuration: <p>The encryption configuration for the exported data. If not specified, the default encryption settings are used.</p>
        client_token: <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.</p>

    Raises:
        capo_glue.errors.access_denied_exception.AccessDeniedException: <p>Access to a resource was denied.</p>
        capo_glue.errors.conflict_exception.ConflictException: <p>The <code>CreatePartitions</code> API was called on a table that has indexes enabled. </p>
        capo_glue.errors.internal_service_exception.InternalServiceException: <p>An internal service error occurred.</p>
        capo_glue.errors.invalid_input_exception.InvalidInputException: <p>The input provided was not valid.</p>
        capo_glue.errors.throttling_exception.ThrottlingException: <p>The throttling threshhold was exceeded.</p>
        capo_glue.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_glue.types.put_data_catalog_export_configuration_input.PutDataCatalogExportConfigurationInput]",
    ) -> OperationResponse[
        "capo_glue.types.put_data_catalog_export_configuration_output.PutDataCatalogExportConfigurationOutput"
    ]:
        import capo_glue._operations.aws_glue.put_data_catalog_export_configuration

        output, http_response = (
            capo_glue._operations.aws_glue.put_data_catalog_export_configuration.put_data_catalog_export_configuration(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("PutDataCatalogExportConfiguration")
    )
    input_: capo_glue.types.put_data_catalog_export_configuration_input.PutDataCatalogExportConfigurationInput = {
        "export_setting": export_setting
    }
    if encryption_configuration is not None:
        input_["encryption_configuration"] = encryption_configuration
    if client_token is None:
        client_token = str(uuid.uuid4())
    input_["client_token"] = client_token

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output