I setup my iOS app with the AWS Mobile Hub. The services I'm using are AWS Cognito and AWS DynamoDB.
I created on AWS DynamoDB a private table that has by default the partition key userId. As far as I can tell, AWS DynamoDB only allows the userId to be the identityId from e.g. AWSIdentityManager.
I'm able to successfully establish an user session via AWSCognitoIdentityUserPool.default().currentUser()?.getSession().
I read/write to AWS DynamoDB with the identityId, that I get through AWSIdentityManager.default().identityId, as userId.
However, the identityId stays always the same on the device, even if I have established an user session.
How can I get an identityId from AWSIdentityManager that is specific for an AWS Cognito user?