Class GcsFetcherConfig

java.lang.Object
com.norconex.crawler.core.fetch.BaseFetcherConfig
com.norconex.crawler.fs.fetch.impl.gcs.GcsFetcherConfig

public class GcsFetcherConfig extends BaseFetcherConfig

Configuration for GcsFetcher.

Authentication is delegated to the official Google Cloud NIO provider, which uses the standard Google Application Default Credentials chain. When an endpoint is set, the fetcher assumes an emulator or local test server and connects without authentication.

  • Constructor Details

    • GcsFetcherConfig

      public GcsFetcherConfig()
  • Method Details

    • getEndpoint

      public String getEndpoint()
      Optional endpoint override, mainly intended for GCS-compatible test servers such as fake-gcs-server.
    • getCredentials

      public Credentials getCredentials()
      Credentials holding a Google service account key: the JSON key file content as the password (the username is not used). The password can be encrypted, so the key stays out of the configuration. When empty, the Google Application Default Credentials of the environment are used (the file the GOOGLE_APPLICATION_CREDENTIALS variable points to, the account the machine is logged in as), or the bucket is read anonymously if there are none. Ignored when getEndpoint() is set.
    • setEndpoint

      public GcsFetcherConfig setEndpoint(String endpoint)
      Optional endpoint override, mainly intended for GCS-compatible test servers such as fake-gcs-server.
      Returns:
      this.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class BaseFetcherConfig
    • canEqual

      protected boolean canEqual(Object other)
      Overrides:
      canEqual in class BaseFetcherConfig
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class BaseFetcherConfig
    • toString

      public String toString()
      Overrides:
      toString in class BaseFetcherConfig