create_crawler
¶
create_crawler(
name: NameString,
role: Role,
targets: CrawlerTargets,
*,
config_overrides: Optional[GlueClientConfig] = None,
database_name: Optional[DatabaseName] = None,
description: Optional[DescriptionString] = None,
schedule: Optional[CronExpression] = None,
classifiers: Optional[ClassifierNameList] = None,
table_prefix: Optional[TablePrefix] = None,
schema_change_policy: Optional[SchemaChangePolicy] = None,
recrawl_policy: Optional[RecrawlPolicy] = None,
lineage_configuration: Optional[LineageConfiguration] = None,
lake_formation_configuration: Optional[LakeFormationConfiguration] = None,
configuration: Optional[CrawlerConfiguration] = None,
crawler_security_configuration: Optional[CrawlerSecurityConfiguration] = None,
tags: Optional[TagsMap] = None,
catalog_id: Optional[CatalogIdString] = None,
) -> CreateCrawlerResponse
Creates a new crawler with specified targets, role, configuration, and optional schedule. At least one crawl target must be specified, in the s3Targets field, the jdbcTargets field, or the DynamoDBTargets field.
Parameters:
-
name(NameString) –Name of the new crawler.
-
role(Role) –The IAM role or Amazon Resource Name (ARN) of an IAM role used by the new crawler to access customer resources.
-
database_name(Optional[DatabaseName], default:None) –The Glue database where results are written, such as:
arn:aws:daylight:us-east-1::database/sometable/*. -
description(Optional[DescriptionString], default:None) –A description of the new crawler.
-
targets(CrawlerTargets) –A list of collection of targets to crawl.
-
schedule(Optional[CronExpression], default:None) –A
cronexpression used to specify the schedule (see Time-Based Schedules for Jobs and Crawlers. For example, to run something every day at 12:15 UTC, you would specify:cron(15 12 * * ? *). -
classifiers(Optional[ClassifierNameList], default:None) –A list of custom classifiers that the user has registered. By default, all built-in classifiers are included in a crawl, but these custom classifiers always override the default classifiers for a given classification.
-
table_prefix(Optional[TablePrefix], default:None) –The table prefix used for catalog tables that are created.
-
schema_change_policy(Optional[SchemaChangePolicy], default:None) –The policy for the crawler's update and deletion behavior.
-
recrawl_policy(Optional[RecrawlPolicy], default:None) –A policy that specifies whether to crawl the entire dataset again, or to crawl only folders that were added since the last crawler run.
-
lineage_configuration(Optional[LineageConfiguration], default:None) –Specifies data lineage configuration settings for the crawler.
-
lake_formation_configuration(Optional[LakeFormationConfiguration], default:None) –Specifies Lake Formation configuration settings for the crawler.
-
configuration(Optional[CrawlerConfiguration], default:None) –Crawler configuration information. This versioned JSON string allows users to specify aspects of a crawler's behavior. For more information, see Setting crawler configuration options.
-
crawler_security_configuration(Optional[CrawlerSecurityConfiguration], default:None) –The name of the
SecurityConfigurationstructure to be used by this crawler. -
tags(Optional[TagsMap], default:None) –The tags to use with this crawler request. You may use tags to limit access to the crawler. For more information about tags in Glue, see Amazon Web Services Tags in Glue in the developer guide.
-
catalog_id(Optional[CatalogIdString], default:None) –The ID of the Data Catalog in which to store the crawler's output. If none is supplied, the Amazon Web Services account ID is used by default.
Raises:
-
AlreadyExistsException–A resource to be created or added already exists.
-
InvalidInputException–The input provided was not valid.
-
OperationTimeoutException–The operation timed out.
-
ResourceNumberLimitExceededException–A resource numerical limit was exceeded.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_glue/_services/glue.py
2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 | |