Class DynamoDBTableResolver


  • public class DynamoDBTableResolver
    extends Object
    This class helps with resolving the differences in casing between DynamoDB and Presto. Presto expects all databases, tables, and columns to be lower case. This class allows us to resolve DynamoDB tables which may have captial letters in them without issue. It does so by fetching all table names and doing a case insensitive search over them. It will first try to do a targeted get to reduce the penalty for tables which don't have capitalization. TODO add caching
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      DynamoDBTable getTableMetadata​(String tableName, software.amazon.awssdk.awscore.AwsRequestOverrideConfiguration awsRequestOverrideConfiguration)
      Fetches table metadata by first doing a DescribeTable on the given table table, falling back to case insensitive resolution if the table isn't found.
      org.apache.arrow.vector.types.pojo.Schema getTableSchema​(String tableName, software.amazon.awssdk.awscore.AwsRequestOverrideConfiguration requestOverrideConfiguration)
      Fetches table schema by first doing a Scan on the given table name, falling back to case insensitive resolution if the table isn't found.
      DynamoDBPaginatedTables listTables​(String token, int pageSize, software.amazon.awssdk.awscore.AwsRequestOverrideConfiguration awsRequestOverrideConfiguration)
      Fetches the list of tables from DynamoDB via paginated ListTables calls