alexedwards / scs

HTTP Session Management for Go
MIT License
2.09k stars 166 forks source link

Implement session store based on GORM #84

Closed lafriks closed 2 years ago

lafriks commented 4 years ago

Session store based on GORM - https://gorm.io/

alexedwards commented 4 years ago

I don't use GORM so sorry if I'm missing something, but it looks to me like you can call CommonDB on your GORM db to expose the underlying sql.DB. And then you can pass that to the existing SCS postgresql package. It looks to me like an additional store isn't necessary?

lafriks commented 4 years ago

@alexedwards if your app support multiple database engines it would make hard to uses scs as you would have to detect database server used by gorm and than use specific scs storage. Also gorm does support also MS SQL that are not supported by scs