Class BucketDetails


  • public class BucketDetails
    extends AssetDetails
    Utility class for capturing the full details provided about a table.
    • Method Detail

      • getIdentity

        public java.lang.String getIdentity()
        Retrieve the unique identity of this asset for deduplication across rows.
        Specified by:
        getIdentity in class AssetDetails
        Returns:
        String giving the unique identity of the asset
      • getQualifiedName

        public static java.lang.String getQualifiedName​(java.util.Map<ConnectionDetails,​java.lang.String> connectionCache,
                                                        java.util.Map<java.lang.String,​java.lang.String> row)
        Construct a bucket's qualifiedName from the row of data and cache of connections.
        Parameters:
        connectionCache - cache of connections
        row - of data
        Returns:
        the qualifiedName for the bucket on that row of data
      • getFromRow

        public static BucketDetails getFromRow​(java.util.Map<ConnectionDetails,​java.lang.String> connectionCache,
                                               java.util.Map<java.lang.String,​java.lang.String> row,
                                               java.lang.String delim)
        Build up details about the bucket on the provided row.
        Parameters:
        connectionCache - a cache of connections that have first been resolved across the spreadsheet
        row - a row of data from the spreadsheet, as a map from column name to value
        delim - delimiter used in cells that can contain multiple values
        Returns:
        the bucket details for that row
      • upsert

        public static void upsert​(java.util.Map<java.lang.String,​BucketDetails> buckets,
                                  int batchSize,
                                  boolean updateOnly)
        Create buckets in bulk, if they do not exist, or update them if they do (idempotent).
        Parameters:
        buckets - the set of buckets to ensure exist
        batchSize - maximum number of buckets to create per batch
        updateOnly - if true, only attempt to update existing assets, otherwise allow assets to be created as well
      • getConnectionQualifiedName

        public java.lang.String getConnectionQualifiedName()
      • getAccountName

        public java.lang.String getAccountName()
      • getName

        public java.lang.String getName()
      • getArn

        public java.lang.String getArn()
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class AssetDetails
      • canEqual

        protected boolean canEqual​(java.lang.Object other)
        Overrides:
        canEqual in class AssetDetails