Class Connection

All Implemented Interfaces:
IAsset, IConnection, IReferenceable, AuditDetail, Serializable, Comparable<Reference>

@Generated("com.atlan.generators.ModelGeneratorV2") public class Connection extends Asset implements IConnection, IAsset, IReferenceable
Instance of a connection to a data source in Atlan.
See Also:
  • Field Details

  • Constructor Details

  • Method Details

    • trimToReference

      public Connection trimToReference() throws InvalidRequestException
      Builds the minimal object necessary to create a relationship to a Connection, from a potentially more-complete Connection object.
      Overrides:
      trimToReference in class Asset
      Returns:
      the minimal object necessary to relate to the Connection
      Throws:
      InvalidRequestException - if any of the minimal set of required properties for a Connection relationship are not found in the initial object
    • select

      public static FluentSearch.FluentSearchBuilder<?,?> select()
      Start a fluent search that will return all Connection assets. Additional conditions can be chained onto the returned search before any asset retrieval is attempted, ensuring all conditions are pushed-down for optimal retrieval. Only active (non-archived) Connection assets will be included.
      Returns:
      a fluent search that includes all Connection assets
    • select

      public static FluentSearch.FluentSearchBuilder<?,?> select(AtlanClient client)
      Start a fluent search that will return all Connection assets. Additional conditions can be chained onto the returned search before any asset retrieval is attempted, ensuring all conditions are pushed-down for optimal retrieval. Only active (non-archived) Connection assets will be included.
      Parameters:
      client - connectivity to the Atlan tenant from which to retrieve the assets
      Returns:
      a fluent search that includes all Connection assets
    • select

      public static FluentSearch.FluentSearchBuilder<?,?> select(boolean includeArchived)
      Start a fluent search that will return all Connection assets. Additional conditions can be chained onto the returned search before any asset retrieval is attempted, ensuring all conditions are pushed-down for optimal retrieval.
      Parameters:
      includeArchived - when true, archived (soft-deleted) Connections will be included
      Returns:
      a fluent search that includes all Connection assets
    • select

      public static FluentSearch.FluentSearchBuilder<?,?> select(AtlanClient client, boolean includeArchived)
      Start a fluent search that will return all Connection assets. Additional conditions can be chained onto the returned search before any asset retrieval is attempted, ensuring all conditions are pushed-down for optimal retrieval.
      Parameters:
      client - connectivity to the Atlan tenant from which to retrieve the assets
      includeArchived - when true, archived (soft-deleted) Connections will be included
      Returns:
      a fluent search that includes all Connection assets
    • refByGuid

      public static Connection refByGuid(String guid)
      Reference to a Connection by GUID. Use this to create a relationship to this Connection, where the relationship should be replaced.
      Parameters:
      guid - the GUID of the Connection to reference
      Returns:
      reference to a Connection that can be used for defining a relationship to a Connection
    • refByGuid

      public static Connection refByGuid(String guid, Reference.SaveSemantic semantic)
      Reference to a Connection by GUID. Use this to create a relationship to this Connection, where you want to further control how that relationship should be updated (i.e. replaced, appended, or removed).
      Parameters:
      guid - the GUID of the Connection to reference
      semantic - how to save this relationship (replace all with this, append it, or remove it)
      Returns:
      reference to a Connection that can be used for defining a relationship to a Connection
    • refByQualifiedName

      public static Connection refByQualifiedName(String qualifiedName)
      Reference to a Connection by qualifiedName. Use this to create a relationship to this Connection, where the relationship should be replaced.
      Parameters:
      qualifiedName - the qualifiedName of the Connection to reference
      Returns:
      reference to a Connection that can be used for defining a relationship to a Connection
    • refByQualifiedName

      public static Connection refByQualifiedName(String qualifiedName, Reference.SaveSemantic semantic)
      Reference to a Connection by qualifiedName. Use this to create a relationship to this Connection, where you want to further control how that relationship should be updated (i.e. replaced, appended, or removed).
      Parameters:
      qualifiedName - the qualifiedName of the Connection to reference
      semantic - how to save this relationship (replace all with this, append it, or remove it)
      Returns:
      reference to a Connection that can be used for defining a relationship to a Connection
    • get

      public static Connection get(String id) throws AtlanException
      Retrieves a Connection by one of its identifiers, complete with all of its relationships.
      Parameters:
      id - of the Connection to retrieve, either its GUID or its full qualifiedName
      Returns:
      the requested full Connection, complete with all of its relationships
      Throws:
      AtlanException - on any error during the API invocation, such as the NotFoundException if the Connection does not exist or the provided GUID is not a Connection
    • get

      public static Connection get(AtlanClient client, String id) throws AtlanException
      Retrieves a Connection by one of its identifiers, complete with all of its relationships.
      Parameters:
      client - connectivity to the Atlan tenant from which to retrieve the asset
      id - of the Connection to retrieve, either its GUID or its full qualifiedName
      Returns:
      the requested full Connection, complete with all of its relationships
      Throws:
      AtlanException - on any error during the API invocation, such as the NotFoundException if the Connection does not exist or the provided GUID is not a Connection
    • get

      public static Connection get(AtlanClient client, String id, boolean includeRelationships) throws AtlanException
      Retrieves a Connection by one of its identifiers, optionally complete with all of its relationships.
      Parameters:
      client - connectivity to the Atlan tenant from which to retrieve the asset
      id - of the Connection to retrieve, either its GUID or its full qualifiedName
      includeRelationships - if true, all of the asset's relationships will also be retrieved; if false, no relationships will be retrieved
      Returns:
      the requested full Connection, optionally complete with all of its relationships
      Throws:
      AtlanException - on any error during the API invocation, such as the NotFoundException if the Connection does not exist or the provided GUID is not a Connection
    • restore

      public static boolean restore(String qualifiedName) throws AtlanException
      Restore the archived (soft-deleted) Connection to active.
      Parameters:
      qualifiedName - for the Connection
      Returns:
      true if the Connection is now active, and false otherwise
      Throws:
      AtlanException - on any API problems
    • restore

      public static boolean restore(AtlanClient client, String qualifiedName) throws AtlanException
      Restore the archived (soft-deleted) Connection to active.
      Parameters:
      client - connectivity to the Atlan tenant on which to restore the asset
      qualifiedName - for the Connection
      Returns:
      true if the Connection is now active, and false otherwise
      Throws:
      AtlanException - on any API problems
    • getConnectorTypeFromQualifiedName

      public static AtlanConnectorType getConnectorTypeFromQualifiedName(String qualifiedName)
      Determine the connector type from the provided qualifiedName.
      Parameters:
      qualifiedName - of the connection
      Returns:
      the connector type, or null if the qualifiedName is not for a connected asset
    • getConnectorTypeFromQualifiedName

      public static AtlanConnectorType getConnectorTypeFromQualifiedName(String[] tokens)
      Determine the connector type from the provided qualifiedName.
      Parameters:
      tokens - of the qualifiedName, from which to determine the connector type
      Returns:
      the connector type, or null if the qualifiedName is not for a connected asset
    • creator

      public static Connection.ConnectionBuilder<?,?> creator(String name, AtlanConnectorType connectorType) throws AtlanException
      Builds the minimal object necessary to create a connection, using "All Admins" as the default set of connection admins.
      Parameters:
      name - of the connection
      connectorType - type of the connection's connector (this determines what logo appears for the assets)
      Returns:
      the minimal object necessary to create the connection, as a builder
      Throws:
      AtlanException - on any error related to the request, such as an inability to retrieve the existing admins in the system
    • creator

      public static Connection.ConnectionBuilder<?,?> creator(String name, AtlanConnectorType connectorType, List<String> adminRoles, List<String> adminGroups, List<String> adminUsers) throws AtlanException
      Builds the minimal object necessary to create a connection. Note: at least one of #adminRoles, #adminGroups, or #adminUsers must be provided or an InvalidRequestException will be thrown.
      Parameters:
      name - of the connection
      connectorType - type of the connection's connector (this determines what logo appears for the assets)
      adminRoles - the GUIDs of the roles that can administer this connection
      adminGroups - the (internal) names of the groups that can administer this connection
      adminUsers - the (internal) names of the users that can administer this connection
      Returns:
      the minimal object necessary to create the connection, as a builder
      Throws:
      InvalidRequestException - if no admin has been defined for the connection, or an invalid admin has been defined
      NotFoundException - if a non-existent admin has been defined for the connection
      AtlanException - on any other error related to the request, such as an inability to retrieve the existing admins in the system
    • creator

      public static Connection.ConnectionBuilder<?,?> creator(AtlanClient client, String name, AtlanConnectorType connectorType, List<String> adminRoles, List<String> adminGroups, List<String> adminUsers) throws AtlanException
      Builds the minimal object necessary to create a connection. Note: at least one of #adminRoles, #adminGroups, or #adminUsers must be provided or an InvalidRequestException will be thrown.
      Parameters:
      client - connectivity to the Atlan tenant where the connection is intended to be created
      name - of the connection
      connectorType - type of the connection's connector (this determines what logo appears for the assets)
      adminRoles - the GUIDs of the roles that can administer this connection
      adminGroups - the (internal) names of the groups that can administer this connection
      adminUsers - the (internal) names of the users that can administer this connection
      Returns:
      the minimal object necessary to create the connection, as a builder
      Throws:
      InvalidRequestException - if no admin has been defined for the connection, or an invalid admin has been defined
      NotFoundException - if a non-existent admin has been defined for the connection
      AtlanException - on any other error related to the request, such as an inability to retrieve the existing admins in the system
    • save

      public AsyncCreationResponse save() throws AtlanException
      If an asset with the same qualifiedName exists, updates the existing asset. Otherwise, creates the asset. No Atlan tags or custom metadata will be changed if updating an existing asset, irrespective of what is included in the asset itself when the method is called.
      Overrides:
      save in class Asset
      Returns:
      details of the created or updated asset
      Throws:
      AtlanException - on any error during the API invocation
      NotFoundException - if any of the provided connection admins do not actually exist
    • save

      public AsyncCreationResponse save(AtlanClient client) throws AtlanException
      If an asset with the same qualifiedName exists, updates the existing asset. Otherwise, creates the asset. No Atlan tags or custom metadata will be changed if updating an existing asset, irrespective of what is included in the asset itself when the method is called.
      Overrides:
      save in class Asset
      Parameters:
      client - connectivity to the Atlan tenant where this connection should be saved
      Returns:
      details of the created or updated asset
      Throws:
      AtlanException - on any error during the API invocation
      NotFoundException - if any of the provided connection admins do not actually exist
    • save

      public AsyncCreationResponse save(boolean replaceAtlanTags) throws AtlanException
      If no asset exists, has the same behavior as the save() method. If an asset does exist, optionally overwrites any Atlan tags. Custom metadata will always be entirely ignored using this method.
      Overrides:
      save in class Asset
      Parameters:
      replaceAtlanTags - whether to replace Atlan tags during an update (true) or not (false)
      Returns:
      details of the created or updated asset
      Throws:
      AtlanException - on any error during the API invocation
      NotFoundException - if any of the provided connection admins do not actually exist
    • save

      public AsyncCreationResponse save(AtlanClient client, boolean replaceAtlanTags) throws AtlanException
      If no asset exists, has the same behavior as the save() method. If an asset does exist, optionally overwrites any Atlan tags. Custom metadata will always be entirely ignored using this method.
      Overrides:
      save in class Asset
      Parameters:
      client - connectivity to the Atlan tenant where this connection should be saved
      replaceAtlanTags - whether to replace Atlan tags during an update (true) or not (false)
      Returns:
      details of the created or updated asset
      Throws:
      AtlanException - on any error during the API invocation
      NotFoundException - if any of the provided connection admins do not actually exist
    • addApiTokenAsAdmin

      public AssetMutationResponse addApiTokenAsAdmin(String impersonationToken) throws AtlanException
      Add the API token configured for the default client as an admin for this Connection. This is necessary to allow the API token to manage policies for the connection.
      Parameters:
      impersonationToken - a bearer token for an actual user who is already an admin for the Connection, NOT an API token
      Throws:
      AtlanException - on any error during API invocation
    • generateQualifiedName

      public static String generateQualifiedName(AtlanConnectorType connectorType)
      Generate a unique connection name.
      Parameters:
      connectorType - the name of the type of the connection's connector
      Returns:
      a unique name for the connection
    • updater

      public static Connection.ConnectionBuilder<?,?> updater(String qualifiedName, String name)
      Builds the minimal object necessary to update a Connection.
      Parameters:
      qualifiedName - of the Connection
      name - of the Connection
      Returns:
      the minimal request necessary to update the Connection, as a builder
    • trimToRequired

      public Connection.ConnectionBuilder<?,?> trimToRequired() throws InvalidRequestException
      Builds the minimal object necessary to apply an update to a Connection, from a potentially more-complete Connection object.
      Overrides:
      trimToRequired in class Asset
      Returns:
      the minimal object necessary to update the Connection, as a builder
      Throws:
      InvalidRequestException - if any of the minimal set of required properties for Connection are not found in the initial object
    • getEpochFromQualifiedName

      public static String getEpochFromQualifiedName(String qualifiedName)
      Retrieve the epoch component of the connection name from its qualifiedName.
      Parameters:
      qualifiedName - of the connection
      Returns:
      the epoch component of the qualifiedName
    • findByName

      public static List<Connection> findByName(String name, AtlanConnectorType type) throws AtlanException
      Find a connection by its human-readable name and type. Only the bare minimum set of attributes and no relationships will be retrieved for the connection, if found.
      Parameters:
      name - of the connection
      type - of the connection
      Returns:
      all connections with that name and type, if found
      Throws:
      AtlanException - on any API problems
      NotFoundException - if the connection does not exist
    • findByName

      public static List<Connection> findByName(String name, AtlanConnectorType type, Collection<String> attributes) throws AtlanException
      Find a connection by its human-readable name and type.
      Parameters:
      name - of the connection
      type - of the connection
      attributes - an optional collection of attributes (unchecked) to retrieve for the connection
      Returns:
      all connections with that name and type, if found
      Throws:
      AtlanException - on any API problems
      NotFoundException - if the connection does not exist
    • findByName

      public static List<Connection> findByName(String name, AtlanConnectorType type, List<AtlanField> attributes) throws AtlanException
      Find a connection by its human-readable name and type.
      Parameters:
      name - of the connection
      type - of the connection
      attributes - an optional collection of attributes (checked) to retrieve for the connection
      Returns:
      all connections with that name and type, if found
      Throws:
      AtlanException - on any API problems
      NotFoundException - if the connection does not exist
    • findByName

      public static List<Connection> findByName(AtlanClient client, String name, AtlanConnectorType type) throws AtlanException
      Find a connection by its human-readable name and type. Only the bare minimum set of attributes and no relationships will be retrieved for the connection, if found.
      Parameters:
      client - connectivity to the Atlan tenant in which to search for the connection
      name - of the connection
      type - of the connection
      Returns:
      all connections with that name and type, if found
      Throws:
      AtlanException - on any API problems
      NotFoundException - if the connection does not exist
    • findByName

      public static List<Connection> findByName(AtlanClient client, String name, AtlanConnectorType type, Collection<String> attributes) throws AtlanException
      Find a connection by its human-readable name and type.
      Parameters:
      client - connectivity to the Atlan tenant in which to search for the connection
      name - of the connection
      type - of the connection
      attributes - an optional collection of attributes to retrieve for the connection
      Returns:
      all connections with that name and type, if found
      Throws:
      AtlanException - on any API problems
      NotFoundException - if the connection does not exist
    • findByName

      public static List<Connection> findByName(AtlanClient client, String name, AtlanConnectorType type, List<AtlanField> attributes) throws AtlanException
      Find a connection by its human-readable name and type.
      Parameters:
      client - connectivity to the Atlan tenant in which to search for the connection
      name - of the connection
      type - of the connection
      attributes - an optional collection of attributes (checked) to retrieve for the connection
      Returns:
      all connections with that name and type, if found
      Throws:
      AtlanException - on any API problems
      NotFoundException - if the connection does not exist
    • getAllQualifiedNames

      public static List<String> getAllQualifiedNames() throws AtlanException
      Retrieve the qualifiedNames of all connections that exist in Atlan.
      Returns:
      list of all connection qualifiedNames
      Throws:
      AtlanException - on any API problems
    • getAllQualifiedNames

      public static List<String> getAllQualifiedNames(AtlanClient client) throws AtlanException
      Retrieve the qualifiedNames of all connections that exist in Atlan.
      Parameters:
      client - connectivity to the Atlan tenant from which to retrieve the qualifiedNames
      Returns:
      list of all connection qualifiedNames
      Throws:
      AtlanException - on any API problems
    • removeDescription

      public static Connection removeDescription(String qualifiedName, String name) throws AtlanException
      Remove the system description from a Connection.
      Parameters:
      qualifiedName - of the Connection
      name - of the Connection
      Returns:
      the updated Connection, or null if the removal failed
      Throws:
      AtlanException - on any API problems
    • removeDescription

      public static Connection removeDescription(AtlanClient client, String qualifiedName, String name) throws AtlanException
      Remove the system description from a Connection.
      Parameters:
      client - connectivity to the Atlan tenant on which to remove the asset's description
      qualifiedName - of the Connection
      name - of the Connection
      Returns:
      the updated Connection, or null if the removal failed
      Throws:
      AtlanException - on any API problems
    • removeUserDescription

      public static Connection removeUserDescription(String qualifiedName, String name) throws AtlanException
      Remove the user's description from a Connection.
      Parameters:
      qualifiedName - of the Connection
      name - of the Connection
      Returns:
      the updated Connection, or null if the removal failed
      Throws:
      AtlanException - on any API problems
    • removeUserDescription

      public static Connection removeUserDescription(AtlanClient client, String qualifiedName, String name) throws AtlanException
      Remove the user's description from a Connection.
      Parameters:
      client - connectivity to the Atlan tenant on which to remove the asset's description
      qualifiedName - of the Connection
      name - of the Connection
      Returns:
      the updated Connection, or null if the removal failed
      Throws:
      AtlanException - on any API problems
    • removeOwners

      public static Connection removeOwners(String qualifiedName, String name) throws AtlanException
      Remove the owners from a Connection.
      Parameters:
      qualifiedName - of the Connection
      name - of the Connection
      Returns:
      the updated Connection, or null if the removal failed
      Throws:
      AtlanException - on any API problems
    • removeOwners

      public static Connection removeOwners(AtlanClient client, String qualifiedName, String name) throws AtlanException
      Remove the owners from a Connection.
      Parameters:
      client - connectivity to the Atlan tenant from which to remove the Connection's owners
      qualifiedName - of the Connection
      name - of the Connection
      Returns:
      the updated Connection, or null if the removal failed
      Throws:
      AtlanException - on any API problems
    • updateCertificate

      public static Connection updateCertificate(String qualifiedName, CertificateStatus certificate, String message) throws AtlanException
      Update the certificate on a Connection.
      Parameters:
      qualifiedName - of the Connection
      certificate - to use
      message - (optional) message, or null if no message
      Returns:
      the updated Connection, or null if the update failed
      Throws:
      AtlanException - on any API problems
    • updateCertificate

      public static Connection updateCertificate(AtlanClient client, String qualifiedName, CertificateStatus certificate, String message) throws AtlanException
      Update the certificate on a Connection.
      Parameters:
      client - connectivity to the Atlan tenant on which to update the Connection's certificate
      qualifiedName - of the Connection
      certificate - to use
      message - (optional) message, or null if no message
      Returns:
      the updated Connection, or null if the update failed
      Throws:
      AtlanException - on any API problems
    • removeCertificate

      public static Connection removeCertificate(String qualifiedName, String name) throws AtlanException
      Remove the certificate from a Connection.
      Parameters:
      qualifiedName - of the Connection
      name - of the Connection
      Returns:
      the updated Connection, or null if the removal failed
      Throws:
      AtlanException - on any API problems
    • removeCertificate

      public static Connection removeCertificate(AtlanClient client, String qualifiedName, String name) throws AtlanException
      Remove the certificate from a Connection.
      Parameters:
      client - connectivity to the Atlan tenant from which to remove the Connection's certificate
      qualifiedName - of the Connection
      name - of the Connection
      Returns:
      the updated Connection, or null if the removal failed
      Throws:
      AtlanException - on any API problems
    • updateAnnouncement

      public static Connection updateAnnouncement(String qualifiedName, AtlanAnnouncementType type, String title, String message) throws AtlanException
      Update the announcement on a Connection.
      Parameters:
      qualifiedName - of the Connection
      type - type of announcement to set
      title - (optional) title of the announcement to set (or null for no title)
      message - (optional) message of the announcement to set (or null for no message)
      Returns:
      the result of the update, or null if the update failed
      Throws:
      AtlanException - on any API problems
    • updateAnnouncement

      public static Connection updateAnnouncement(AtlanClient client, String qualifiedName, AtlanAnnouncementType type, String title, String message) throws AtlanException
      Update the announcement on a Connection.
      Parameters:
      client - connectivity to the Atlan tenant on which to update the Connection's announcement
      qualifiedName - of the Connection
      type - type of announcement to set
      title - (optional) title of the announcement to set (or null for no title)
      message - (optional) message of the announcement to set (or null for no message)
      Returns:
      the result of the update, or null if the update failed
      Throws:
      AtlanException - on any API problems
    • removeAnnouncement

      public static Connection removeAnnouncement(String qualifiedName, String name) throws AtlanException
      Remove the announcement from a Connection.
      Parameters:
      qualifiedName - of the Connection
      name - of the Connection
      Returns:
      the updated Connection, or null if the removal failed
      Throws:
      AtlanException - on any API problems
    • removeAnnouncement

      public static Connection removeAnnouncement(AtlanClient client, String qualifiedName, String name) throws AtlanException
      Remove the announcement from a Connection.
      Parameters:
      client - connectivity to the Atlan client from which to remove the Connection's announcement
      qualifiedName - of the Connection
      name - of the Connection
      Returns:
      the updated Connection, or null if the removal failed
      Throws:
      AtlanException - on any API problems
    • replaceTerms

      public static Connection replaceTerms(String qualifiedName, String name, List<IGlossaryTerm> terms) throws AtlanException
      Replace the terms linked to the Connection.
      Parameters:
      qualifiedName - for the Connection
      name - human-readable name of the Connection
      terms - the list of terms to replace on the Connection, or null to remove all terms from the Connection
      Returns:
      the Connection that was updated (note that it will NOT contain details of the replaced terms)
      Throws:
      AtlanException - on any API problems
    • replaceTerms

      public static Connection replaceTerms(AtlanClient client, String qualifiedName, String name, List<IGlossaryTerm> terms) throws AtlanException
      Replace the terms linked to the Connection.
      Parameters:
      client - connectivity to the Atlan tenant on which to replace the Connection's assigned terms
      qualifiedName - for the Connection
      name - human-readable name of the Connection
      terms - the list of terms to replace on the Connection, or null to remove all terms from the Connection
      Returns:
      the Connection that was updated (note that it will NOT contain details of the replaced terms)
      Throws:
      AtlanException - on any API problems
    • appendTerms

      public static Connection appendTerms(String qualifiedName, List<IGlossaryTerm> terms) throws AtlanException
      Link additional terms to the Connection, without replacing existing terms linked to the Connection. Note: this operation must make two API calls — one to retrieve the Connection's existing terms, and a second to append the new terms.
      Parameters:
      qualifiedName - for the Connection
      terms - the list of terms to append to the Connection
      Returns:
      the Connection that was updated (note that it will NOT contain details of the appended terms)
      Throws:
      AtlanException - on any API problems
    • appendTerms

      public static Connection appendTerms(AtlanClient client, String qualifiedName, List<IGlossaryTerm> terms) throws AtlanException
      Link additional terms to the Connection, without replacing existing terms linked to the Connection. Note: this operation must make two API calls — one to retrieve the Connection's existing terms, and a second to append the new terms.
      Parameters:
      client - connectivity to the Atlan tenant on which to append terms to the Connection
      qualifiedName - for the Connection
      terms - the list of terms to append to the Connection
      Returns:
      the Connection that was updated (note that it will NOT contain details of the appended terms)
      Throws:
      AtlanException - on any API problems
    • removeTerms

      public static Connection removeTerms(String qualifiedName, List<IGlossaryTerm> terms) throws AtlanException
      Remove terms from a Connection, without replacing all existing terms linked to the Connection. Note: this operation must make two API calls — one to retrieve the Connection's existing terms, and a second to remove the provided terms.
      Parameters:
      qualifiedName - for the Connection
      terms - the list of terms to remove from the Connection, which must be referenced by GUID
      Returns:
      the Connection that was updated (note that it will NOT contain details of the resulting terms)
      Throws:
      AtlanException - on any API problems
    • removeTerms

      public static Connection removeTerms(AtlanClient client, String qualifiedName, List<IGlossaryTerm> terms) throws AtlanException
      Remove terms from a Connection, without replacing all existing terms linked to the Connection. Note: this operation must make two API calls — one to retrieve the Connection's existing terms, and a second to remove the provided terms.
      Parameters:
      client - connectivity to the Atlan tenant from which to remove terms from the Connection
      qualifiedName - for the Connection
      terms - the list of terms to remove from the Connection, which must be referenced by GUID
      Returns:
      the Connection that was updated (note that it will NOT contain details of the resulting terms)
      Throws:
      AtlanException - on any API problems
    • appendAtlanTags

      public static Connection appendAtlanTags(String qualifiedName, List<String> atlanTagNames) throws AtlanException
      Add Atlan tags to a Connection, without replacing existing Atlan tags linked to the Connection. Note: this operation must make two API calls — one to retrieve the Connection's existing Atlan tags, and a second to append the new Atlan tags.
      Parameters:
      qualifiedName - of the Connection
      atlanTagNames - human-readable names of the Atlan tags to add
      Returns:
      the updated Connection
      Throws:
      AtlanException - on any API problems
    • appendAtlanTags

      public static Connection appendAtlanTags(AtlanClient client, String qualifiedName, List<String> atlanTagNames) throws AtlanException
      Add Atlan tags to a Connection, without replacing existing Atlan tags linked to the Connection. Note: this operation must make two API calls — one to retrieve the Connection's existing Atlan tags, and a second to append the new Atlan tags.
      Parameters:
      client - connectivity to the Atlan tenant on which to append Atlan tags to the Connection
      qualifiedName - of the Connection
      atlanTagNames - human-readable names of the Atlan tags to add
      Returns:
      the updated Connection
      Throws:
      AtlanException - on any API problems
    • appendAtlanTags

      public static Connection appendAtlanTags(String qualifiedName, List<String> atlanTagNames, boolean propagate, boolean removePropagationsOnDelete, boolean restrictLineagePropagation) throws AtlanException
      Add Atlan tags to a Connection, without replacing existing Atlan tags linked to the Connection. Note: this operation must make two API calls — one to retrieve the Connection's existing Atlan tags, and a second to append the new Atlan tags.
      Parameters:
      qualifiedName - of the Connection
      atlanTagNames - human-readable names of the Atlan tags to add
      propagate - whether to propagate the Atlan tag (true) or not (false)
      removePropagationsOnDelete - whether to remove the propagated Atlan tags when the Atlan tag is removed from this asset (true) or not (false)
      restrictLineagePropagation - whether to avoid propagating through lineage (true) or do propagate through lineage (false)
      Returns:
      the updated Connection
      Throws:
      AtlanException - on any API problems
    • appendAtlanTags

      public static Connection appendAtlanTags(AtlanClient client, String qualifiedName, List<String> atlanTagNames, boolean propagate, boolean removePropagationsOnDelete, boolean restrictLineagePropagation) throws AtlanException
      Add Atlan tags to a Connection, without replacing existing Atlan tags linked to the Connection. Note: this operation must make two API calls — one to retrieve the Connection's existing Atlan tags, and a second to append the new Atlan tags.
      Parameters:
      client - connectivity to the Atlan tenant on which to append Atlan tags to the Connection
      qualifiedName - of the Connection
      atlanTagNames - human-readable names of the Atlan tags to add
      propagate - whether to propagate the Atlan tag (true) or not (false)
      removePropagationsOnDelete - whether to remove the propagated Atlan tags when the Atlan tag is removed from this asset (true) or not (false)
      restrictLineagePropagation - whether to avoid propagating through lineage (true) or do propagate through lineage (false)
      Returns:
      the updated Connection
      Throws:
      AtlanException - on any API problems
    • removeAtlanTag

      public static void removeAtlanTag(String qualifiedName, String atlanTagName) throws AtlanException
      Remove an Atlan tag from a Connection.
      Parameters:
      qualifiedName - of the Connection
      atlanTagName - human-readable name of the Atlan tag to remove
      Throws:
      AtlanException - on any API problems, or if the Atlan tag does not exist on the Connection
    • removeAtlanTag

      public static void removeAtlanTag(AtlanClient client, String qualifiedName, String atlanTagName) throws AtlanException
      Remove an Atlan tag from a Connection.
      Parameters:
      client - connectivity to the Atlan tenant from which to remove an Atlan tag from a Connection
      qualifiedName - of the Connection
      atlanTagName - human-readable name of the Atlan tag to remove
      Throws:
      AtlanException - on any API problems, or if the Atlan tag does not exist on the Connection
    • _internal

      public static Connection.ConnectionBuilder<?,?> _internal()
    • toBuilder

      public Connection.ConnectionBuilder<?,?> toBuilder()
      Overrides:
      toBuilder in class Reference
    • getAllowQuery

      public Boolean getAllowQuery()
      Whether using this connection to run queries on the source is allowed (true) or not (false).
      Specified by:
      getAllowQuery in interface IConnection
    • getAllowQueryPreview

      public Boolean getAllowQueryPreview()
      Whether using this connection to run preview queries on the source is allowed (true) or not (false).
      Specified by:
      getAllowQueryPreview in interface IConnection
    • getCategory

      public AtlanConnectionCategory getCategory()
      Type of connection, for example WAREHOUSE, RDBMS, etc.
      Specified by:
      getCategory in interface IConnection
    • getConnectionDbtEnvironments

      public SortedSet<String> getConnectionDbtEnvironments()
      TBC
      Specified by:
      getConnectionDbtEnvironments in interface IConnection
    • getConnectionSSOCredentialGuid

      public String getConnectionSSOCredentialGuid()
      Unique identifier (GUID) for the SSO credentials to use for this connection.
      Specified by:
      getConnectionSSOCredentialGuid in interface IConnection
    • getConnectorIcon

      public String getConnectorIcon()
      Unused. Only the value of connectorType impacts icons.
      Specified by:
      getConnectorIcon in interface IConnection
    • getConnectorImage

      public String getConnectorImage()
      Unused. Only the value of connectorType impacts icons.
      Specified by:
      getConnectorImage in interface IConnection
    • getCredentialStrategy

      public String getCredentialStrategy()
      Credential strategy to use for this connection for queries.
      Specified by:
      getCredentialStrategy in interface IConnection
    • getDefaultCredentialGuid

      public String getDefaultCredentialGuid()
      Unique identifier (GUID) for the default credentials to use for this connection.
      Specified by:
      getDefaultCredentialGuid in interface IConnection
    • getHasPopularityInsights

      public Boolean getHasPopularityInsights()
      Whether this connection has popularity insights (true) or not (false).
      Specified by:
      getHasPopularityInsights in interface IConnection
    • getHost

      public String getHost()
      Host name of this connection's source.
      Specified by:
      getHost in interface IConnection
    • getIsSampleDataPreviewEnabled

      public Boolean getIsSampleDataPreviewEnabled()
      Whether sample data can be previewed for this connection (true) or not (false).
      Specified by:
      getIsSampleDataPreviewEnabled in interface IConnection
    • getObjectStorageUploadThreshold

      public Long getObjectStorageUploadThreshold()
      Number of rows after which results should be uploaded to storage.
      Specified by:
      getObjectStorageUploadThreshold in interface IConnection
    • getPolicyStrategy

      public String getPolicyStrategy()
      Policy strategy is a configuration that determines whether the Atlan policy will be applied to the results of insight queries and whether the query will be rewritten, applicable for stream api call made from insight screen
      Specified by:
      getPolicyStrategy in interface IConnection
    • getPolicyStrategyForSamplePreview

      public String getPolicyStrategyForSamplePreview()
      Policy strategy is a configuration that determines whether the Atlan policy will be applied to the results of insight queries and whether the query will be rewritten. policyStrategyForSamplePreview config is applicable for sample preview call from assets screen
      Specified by:
      getPolicyStrategyForSamplePreview in interface IConnection
    • getPopularityInsightsTimeframe

      public Long getPopularityInsightsTimeframe()
      Number of days over which popularity is calculated, for example 30 days.
      Specified by:
      getPopularityInsightsTimeframe in interface IConnection
    • getPort

      public Integer getPort()
      Port number to this connection's source.
      Specified by:
      getPort in interface IConnection
    • getPreviewCredentialStrategy

      public String getPreviewCredentialStrategy()
      Credential strategy to use for this connection for preview queries.
      Specified by:
      getPreviewCredentialStrategy in interface IConnection
    • getQueryConfig

      public String getQueryConfig()
      Query config for this connection.
      Specified by:
      getQueryConfig in interface IConnection
    • getQueryPreviewConfig

      public Map<String,String> getQueryPreviewConfig()
      Configuration for preview queries.
      Specified by:
      getQueryPreviewConfig in interface IConnection
    • getQueryTimeout

      public Long getQueryTimeout()
      Maximum time a query should be allowed to run before timing out.
      Specified by:
      getQueryTimeout in interface IConnection
    • getQueryUsernameStrategy

      public QueryUsernameStrategy getQueryUsernameStrategy()
      Username strategy to use for this connection for queries.
      Specified by:
      getQueryUsernameStrategy in interface IConnection
    • getRowLimit

      public Long getRowLimit()
      Maximum number of rows that can be returned for the source.
      Specified by:
      getRowLimit in interface IConnection
    • getSourceLogo

      public String getSourceLogo()
      Unused. Only the value of connectorType impacts icons.
      Specified by:
      getSourceLogo in interface IConnection
    • getSubCategory

      public String getSubCategory()
      Subcategory of this connection.
      Specified by:
      getSubCategory in interface IConnection
    • getUseObjectStorage

      public Boolean getUseObjectStorage()
      Whether to upload to S3, GCP, or another storage location (true) or not (false).
      Specified by:
      getUseObjectStorage in interface IConnection
    • getVectorEmbeddingsEnabled

      public Boolean getVectorEmbeddingsEnabled()
      TBC
      Specified by:
      getVectorEmbeddingsEnabled in interface IConnection
    • getVectorEmbeddingsUpdatedAt

      public Long getVectorEmbeddingsUpdatedAt()
      TBC
      Specified by:
      getVectorEmbeddingsUpdatedAt in interface IConnection
    • equals

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

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

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

      public String toString()
      Description copied from class: AtlanObject
      Overrides:
      toString in class Asset
    • getTypeName

      public String getTypeName()
      Fixed typeName for Connections.
      Specified by:
      getTypeName in interface AuditDetail
      Specified by:
      getTypeName in interface IAsset
      Specified by:
      getTypeName in interface IConnection
      Specified by:
      getTypeName in interface IReferenceable
      Overrides:
      getTypeName in class Reference