Class DynamoDBUtils

java.lang.Object
net.javacrumbs.shedlock.provider.dynamodb2.DynamoDBUtils

public class DynamoDBUtils extends Object
  • Constructor Details

    • DynamoDBUtils

      public DynamoDBUtils()
  • Method Details

    • createLockTable

      public static String createLockTable(software.amazon.awssdk.services.dynamodb.DynamoDbClient ddbClient, String tableName, software.amazon.awssdk.services.dynamodb.model.ProvisionedThroughput throughput)
      Creates a locking table with the given name.

      This method does not check if a table with the given name exists already.

      Parameters:
      ddbClient - v2 of DynamoDBClient
      tableName - table to be used
      throughput - AWS throughput requirements for the given lock setup
      Returns:
      the table name
      Throws:
      software.amazon.awssdk.services.dynamodb.model.ResourceInUseException - The operation conflicts with the resource's availability. You attempted to recreate an existing table.