AshDynamo.DataLayer.Info (ash_dynamo v0.2.1)

View Source

Introspection helpers for the Ash DynamoDB data layer.

These functions are thin wrappers around the resource DSL configuration.

Summary

Functions

Global secondary index definitions.

Local secondary index definitions.

Partition (hash) key attribute name.

Sort (range) key attribute name, if any.

Table name for the resource, defaulting to the underscored module name.

Functions

global_secondary_indexes(resource)

@spec global_secondary_indexes(Ash.Resource.t() | Spark.Dsl.t()) :: list()

Global secondary index definitions.

local_secondary_indexes(resource)

@spec local_secondary_indexes(Ash.Resource.t() | Spark.Dsl.t()) :: list()

Local secondary index definitions.

partition_key(resource)

@spec partition_key(Ash.Resource.t() | Spark.Dsl.t()) :: atom() | nil

Partition (hash) key attribute name.

sort_key(resource)

@spec sort_key(Ash.Resource.t() | Spark.Dsl.t()) :: atom() | nil

Sort (range) key attribute name, if any.

table(resource)

@spec table(Ash.Resource.t() | Spark.Dsl.t()) :: String.t()

Table name for the resource, defaulting to the underscored module name.