All Products
Search
Document Center

Resource Orchestration Service:DATASOURCE::PAI::Dataset

更新時間:Sep 23, 2024

DATASOURCE::PAI::Dataset is used to query a dataset.

Syntax

{
  "Type": "DATASOURCE::PAI::Dataset",
  "Properties": {
    "DatasetId": String,
    "WorkspaceId": String,
    "RefreshOptions": String
  }
}

Properties

Property

Type

Required

Editable

Description

Constraint

DatasetId

String

Yes

Yes

The dataset ID.

None.

WorkspaceId

String

Yes

Yes

The ID of the workspace to which the dataset belongs.

None.

RefreshOptions

String

No

Yes

The refresh policy for data source resources when the stack is updated.

Valid values:

  • Never (default): does not refresh data source resources when the stack is updated.

  • Always: refreshes data source resources when the stack is updated.

Return values

Fn::GetAtt

  • Options: the extended fields.

  • Description: the description.

  • Accessibility: the accessibility of the workspace.

  • SourceId: the source ID.

  • CreateTime: the creation time.

  • SourceType: the source type.

  • WorkspaceId: the ID of the workspace to which the dataset belongs.

  • Uri: the URI configurations.

  • GmtModifiedTime: the update time.

  • DatasetId: the dataset ID.

  • OwnerId: the ID of the Alibaba Cloud account.

  • DatasetName: the dataset name.

  • UserId: the user ID.

  • DataSourceType: the data source type.

  • DataType: the data type.

  • Property: the property of the dataset.

Examples

  • YAML format

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      WorkspaceId:
        Type: String
        Description:
          en: |-
            The ID of the workspace where the dataset is located. For details about how to obtain the workspace ID, see [ListWorkspaces].
            If this parameter is not configured, the default workspace is used. If the default workspace does not exist, an error is reported.
        Required: true
      DatasetId:
        Type: String
        Description:
          en: The first ID of the resource.
        Required: true
    Resources:
      ExtensionDataSource:
        Type: DATASOURCE::PAI::Dataset
        Properties:
          WorkspaceId:
            Ref: WorkspaceId
          DatasetId:
            Ref: DatasetId
    Outputs:
      Options:
        Description: The extended field, which is of the JsonString type.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - Options
      Description:
        Description: Custom descriptions of datasets to distinguish between different datasets.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - Description
      Accessibility:
        Description: Workspace visibility.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - Accessibility
      SourceId:
        Description: The data source ID.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - SourceId
      CreateTime:
        Description: The creation time of the resource.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - CreateTime
      SourceType:
        Description: The data source type. The default value is USER.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - SourceType
      WorkspaceId:
        Description: The ID of the workspace where the dataset is located.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - WorkspaceId
      Uri:
        Description: The Uri configuration sample is as follows:.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - Uri
      GmtModifiedTime:
        Description: Update time.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - GmtModifiedTime
      DatasetId:
        Description: The first ID of the resource.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - DatasetId
      OwnerId:
        Description: The ID of the primary account.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - OwnerId
      DatasetName:
        Description: The name of the dataset.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - DatasetName
      UserId:
        Description: The ID of the user to which the dataset belongs.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - UserId
      DataSourceType:
        Description: The data source type.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - DataSourceType
      DataType:
        Description: The dataset type. The default value is COMMON.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - DataType
      Property:
        Description: The properties of the dataset.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - Property
    
  • JSON format

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "WorkspaceId": {
          "Type": "String",
          "Description": {
            "en": "The ID of the workspace where the dataset is located. For details about how to obtain the workspace ID, see [ListWorkspaces].\nIf this parameter is not configured, the default workspace is used. If the default workspace does not exist, an error is reported."
          },
          "Required": true
        },
        "DatasetId": {
          "Type": "String",
          "Description": {
            "en": "The first ID of the resource."
          },
          "Required": true
        }
      },
      "Resources": {
        "ExtensionDataSource": {
          "Type": "DATASOURCE::PAI::Dataset",
          "Properties": {
            "WorkspaceId": {
              "Ref": "WorkspaceId"
            },
            "DatasetId": {
              "Ref": "DatasetId"
            }
          }
        }
      },
      "Outputs": {
        "Options": {
          "Description": "The extended field, which is of the JsonString type.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "Options"
            ]
          }
        },
        "Description": {
          "Description": "Custom descriptions of datasets to distinguish between different datasets.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "Description"
            ]
          }
        },
        "Accessibility": {
          "Description": "Workspace visibility.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "Accessibility"
            ]
          }
        },
        "SourceId": {
          "Description": "The data source ID.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "SourceId"
            ]
          }
        },
        "CreateTime": {
          "Description": "The creation time of the resource.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "CreateTime"
            ]
          }
        },
        "SourceType": {
          "Description": "The data source type. The default value is USER.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "SourceType"
            ]
          }
        },
        "WorkspaceId": {
          "Description": "The ID of the workspace where the dataset is located.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "WorkspaceId"
            ]
          }
        },
        "Uri": {
          "Description": "The Uri configuration sample is as follows:.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "Uri"
            ]
          }
        },
        "GmtModifiedTime": {
          "Description": "Update time.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "GmtModifiedTime"
            ]
          }
        },
        "DatasetId": {
          "Description": "The first ID of the resource.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "DatasetId"
            ]
          }
        },
        "OwnerId": {
          "Description": "The ID of the primary account.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "OwnerId"
            ]
          }
        },
        "DatasetName": {
          "Description": "The name of the dataset.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "DatasetName"
            ]
          }
        },
        "UserId": {
          "Description": "The ID of the user to which the dataset belongs.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "UserId"
            ]
          }
        },
        "DataSourceType": {
          "Description": "The data source type.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "DataSourceType"
            ]
          }
        },
        "DataType": {
          "Description": "The dataset type. The default value is COMMON.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "DataType"
            ]
          }
        },
        "Property": {
          "Description": "The properties of the dataset.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "Property"
            ]
          }
        }
      }
    }