I have create a new ASP.NET MVC 5 Project. I have installed through Nuget the AWS SDK for .NET and Session Provider and I have read this article in Amazon: Article
I have this configuration in the Web.Config
<sessionState
mode="Custom"
customProvider="DynamoDBSessionStoreProvider">
<providers>
<add name="DynamoDBSessionStoreProvider"
type="Amazon.SessionProvider.DynamoDBSessionStateStore, AWS.SessionProvider"
AWSProfileName="default"
Table="ASP.NET_SessionState"
Region="eu-west-1"
/>
</providers>
</sessionState>
I run the web app using the IIS Express and all works fine (I can login and logoff), but if I access to my DynamoDB I don't have any item in the table ASP.NET_SessionState.
It's working like the custom state provider is ignored...
What am I doing wrong?
Thanks!!
This is what i have done
In the web config in the system.web section
Then in the model you have give serializable Attribute. Some thing like below
Then in the code you need to set session, something like this
No need to worry about connection amazon sdk will take care of it. You need to mention the correct Access key and Secret Key.