fasthttp / session

Session implementation for fasthttp

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

I forked this as I thought I can contribute but...

hiqsociety opened this issue · comments

I'm getting this error when forked. Anyone tried? I only use the "memory" option for storage.

2019/06/09 18:25:26 session set provider error, memory not registered!

How to resolve?

Are you using the example of examples folder??

no. i'm using my own program. just by replacing my github repo with /fasthttp/, it will work. otherwise it work wont.

Could you share your code?? it's a bit difficult for me to know how is the error

can u try
go get github.com/hiqsociety/session
?

You must implement with a fasthttp server, it's not standalone

Have you try the examples? https://github.com/fasthttp/session/tree/master/examples

I tried the examples of your fork and works properly.

i did. how would you have done it after
go get github.com/hiqsociety/session

import (
"github.com/hiqsociety/session"
"github.com/hiqsociety/router"
"github.com/valvaya/fasthttp"
)

?

I need to see more code! It's too difficult for me to help you.

Share it with me via email, if you want.

ok i finally got it.
need to change link of /memory/types.go
and /memory/provider.go 's fasthttp to hiqsociety...

@hiqsociety if you need support or an answer about your particular case, you need to provide enough information. if your case includes any sources, try to create a minimal reproducing snippet and share it via play.golang.org. We don't need your business information, but we still need something more detailed. If you have any question, please, put it here in form of one self-contained message.

your exact question from the first message is pretty straightforward. you did not imported any working implementation of memory storage. it's not enough to import fasthttp/session, you also need a functional implementation for your storage: https://github.com/fasthttp/session/blob/master/examples/main.go#L7-L15