Copyright | (c) 2013-2018 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Creates a global table from an existing table. A global table creates a replication relationship between two or more DynamoDB tables with the same table name in the provided regions.
Tables can only be added as the replicas of a global table group under the following conditions:
- The tables must have the same name.
- The tables must contain no items.
- The tables must have the same hash key and sort key (if present).
- The tables must have DynamoDB Streams enabled (NEW_AND_OLD_IMAGES).
- The tables must have same provisioned and maximum write capacity units.
If global secondary indexes are specified, then the following conditions must also be met:
- The global secondary indexes must have the same name.
- The global secondary indexes must have the same hash key and sort key (if present).
- The global secondary indexes must have the same provisioned and maximum write capacity units.
Synopsis
- createGlobalTable :: Text -> CreateGlobalTable
- data CreateGlobalTable
- cgtGlobalTableName :: Lens' CreateGlobalTable Text
- cgtReplicationGroup :: Lens' CreateGlobalTable [Replica]
- createGlobalTableResponse :: Int -> CreateGlobalTableResponse
- data CreateGlobalTableResponse
- cgtrsGlobalTableDescription :: Lens' CreateGlobalTableResponse (Maybe GlobalTableDescription)
- cgtrsResponseStatus :: Lens' CreateGlobalTableResponse Int
Creating a Request
Creates a value of CreateGlobalTable
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
cgtGlobalTableName
- The global table name.cgtReplicationGroup
- The regions where the global table needs to be created.
data CreateGlobalTable Source #
See: createGlobalTable
smart constructor.
Instances
Request Lenses
cgtGlobalTableName :: Lens' CreateGlobalTable Text Source #
The global table name.
cgtReplicationGroup :: Lens' CreateGlobalTable [Replica] Source #
The regions where the global table needs to be created.
Destructuring the Response
createGlobalTableResponse Source #
Creates a value of CreateGlobalTableResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
cgtrsGlobalTableDescription
- Contains the details of the global table.cgtrsResponseStatus
- -- | The response status code.
data CreateGlobalTableResponse Source #
See: createGlobalTableResponse
smart constructor.
Instances
Response Lenses
cgtrsGlobalTableDescription :: Lens' CreateGlobalTableResponse (Maybe GlobalTableDescription) Source #
Contains the details of the global table.
cgtrsResponseStatus :: Lens' CreateGlobalTableResponse Int Source #
- - | The response status code.