java.lang.Object
software.amazon.awssdk.services.glue.model.Crawler
All Implemented Interfaces:
Serializable, SdkPojo, ToCopyableBuilder<Crawler.Builder,Crawler>

@Generated("software.amazon.awssdk:codegen") public final class Crawler extends Object implements SdkPojo, Serializable, ToCopyableBuilder<Crawler.Builder,Crawler>

Specifies a crawler program that examines a data source and uses classifiers to try to determine its schema. If successful, the crawler records metadata concerning the data source in the Glue Data Catalog.

See Also:
  • Method Details

    • name

      public final String name()

      The name of the crawler.

      Returns:
      The name of the crawler.
    • role

      public final String role()

      The Amazon Resource Name (ARN) of an IAM role that's used to access customer resources, such as Amazon Simple Storage Service (Amazon S3) data.

      Returns:
      The Amazon Resource Name (ARN) of an IAM role that's used to access customer resources, such as Amazon Simple Storage Service (Amazon S3) data.
    • targets

      public final CrawlerTargets targets()

      A collection of targets to crawl.

      Returns:
      A collection of targets to crawl.
    • databaseName

      public final String databaseName()

      The name of the database in which the crawler's output is stored.

      Returns:
      The name of the database in which the crawler's output is stored.
    • description

      public final String description()

      A description of the crawler.

      Returns:
      A description of the crawler.
    • hasClassifiers

      public final boolean hasClassifiers()
      For responses, this returns true if the service returned a value for the Classifiers property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
    • classifiers

      public final List<String> classifiers()

      A list of UTF-8 strings that specify the custom classifiers that are associated with the crawler.

      Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

      This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasClassifiers() method.

      Returns:
      A list of UTF-8 strings that specify the custom classifiers that are associated with the crawler.
    • recrawlPolicy

      public final RecrawlPolicy recrawlPolicy()

      A policy that specifies whether to crawl the entire dataset again, or to crawl only folders that were added since the last crawler run.

      Returns:
      A policy that specifies whether to crawl the entire dataset again, or to crawl only folders that were added since the last crawler run.
    • schemaChangePolicy

      public final SchemaChangePolicy schemaChangePolicy()

      The policy that specifies update and delete behaviors for the crawler.

      Returns:
      The policy that specifies update and delete behaviors for the crawler.
    • lineageConfiguration

      public final LineageConfiguration lineageConfiguration()

      A configuration that specifies whether data lineage is enabled for the crawler.

      Returns:
      A configuration that specifies whether data lineage is enabled for the crawler.
    • state

      public final CrawlerState state()

      Indicates whether the crawler is running, or whether a run is pending.

      If the service returns an enum value that is not available in the current SDK version, state will return CrawlerState.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from stateAsString().

      Returns:
      Indicates whether the crawler is running, or whether a run is pending.
      See Also:
    • stateAsString

      public final String stateAsString()

      Indicates whether the crawler is running, or whether a run is pending.

      If the service returns an enum value that is not available in the current SDK version, state will return CrawlerState.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from stateAsString().

      Returns:
      Indicates whether the crawler is running, or whether a run is pending.
      See Also:
    • tablePrefix

      public final String tablePrefix()

      The prefix added to the names of tables that are created.

      Returns:
      The prefix added to the names of tables that are created.
    • schedule

      public final Schedule schedule()

      For scheduled crawlers, the schedule when the crawler runs.

      Returns:
      For scheduled crawlers, the schedule when the crawler runs.
    • crawlElapsedTime

      public final Long crawlElapsedTime()

      If the crawler is running, contains the total time elapsed since the last crawl began.

      Returns:
      If the crawler is running, contains the total time elapsed since the last crawl began.
    • creationTime

      public final Instant creationTime()

      The time that the crawler was created.

      Returns:
      The time that the crawler was created.
    • lastUpdated

      public final Instant lastUpdated()

      The time that the crawler was last updated.

      Returns:
      The time that the crawler was last updated.
    • lastCrawl

      public final LastCrawlInfo lastCrawl()

      The status of the last crawl, and potentially error information if an error occurred.

      Returns:
      The status of the last crawl, and potentially error information if an error occurred.
    • version

      public final Long version()

      The version of the crawler.

      Returns:
      The version of the crawler.
    • configuration

      public final String configuration()

      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.

      Returns:
      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.
    • crawlerSecurityConfiguration

      public final String crawlerSecurityConfiguration()

      The name of the SecurityConfiguration structure to be used by this crawler.

      Returns:
      The name of the SecurityConfiguration structure to be used by this crawler.
    • lakeFormationConfiguration

      public final LakeFormationConfiguration lakeFormationConfiguration()

      Specifies whether the crawler should use Lake Formation credentials for the crawler instead of the IAM role credentials.

      Returns:
      Specifies whether the crawler should use Lake Formation credentials for the crawler instead of the IAM role credentials.
    • toBuilder

      public Crawler.Builder toBuilder()
      Description copied from interface: ToCopyableBuilder
      Take this object and create a builder that contains all of the current property values of this object.
      Specified by:
      toBuilder in interface ToCopyableBuilder<Crawler.Builder,Crawler>
      Returns:
      a builder for type T
    • builder

      public static Crawler.Builder builder()
    • serializableBuilderClass

      public static Class<? extends Crawler.Builder> serializableBuilderClass()
    • hashCode

      public final int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public final boolean equals(Object obj)
      Overrides:
      equals in class Object
    • equalsBySdkFields

      public final boolean equalsBySdkFields(Object obj)
      Description copied from interface: SdkPojo
      Indicates whether some other object is "equal to" this one by SDK fields. An SDK field is a modeled, non-inherited field in an SdkPojo class, and is generated based on a service model.

      If an SdkPojo class does not have any inherited fields, equalsBySdkFields and equals are essentially the same.

      Specified by:
      equalsBySdkFields in interface SdkPojo
      Parameters:
      obj - the object to be compared with
      Returns:
      true if the other object equals to this object by sdk fields, false otherwise.
    • toString

      public final String toString()
      Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
      Overrides:
      toString in class Object
    • getValueForField

      public final <T> Optional<T> getValueForField(String fieldName, Class<T> clazz)
    • sdkFields

      public final List<SdkField<?>> sdkFields()
      Specified by:
      sdkFields in interface SdkPojo
      Returns:
      List of SdkField in this POJO. May be empty list but should never be null.