You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If this is a feature request, explain why it should be added. Specific use-cases are best.
For bug reports, please provide as much relevant info as possible.
When Connection closed, it unable to open again.
Steps to Reproduce the Problem
Please describe in painful detail what you did (so others can play along with you) to get to this point. This includes things like the exact command(s) you used, or the curl command you used, that sort of thing.
users:= []User{}
fori:=0; i<2; i++ {
conn, err:=pop.Connect("development")
iferr!=nil {
fmt.Println(err)
}
err=conn.All(&users)
iferr!=nil {
fmt.Println(err)
os.Exit(1)
}
for_, u:=rangeusers {
fmt.Println(u)
}
err=conn.Close()
// conn.Store = nil // make Store to nil will continue the loopiferr!=nil {
fmt.Println(err)
}
}
Expected Behavior
connection will recconnect after closing
Actual Behavior
unable to fetch records: sql: database is closed
Info
Should set Store = nil in Connection's Close method.
The text was updated successfully, but these errors were encountered:
ofofofofo
changed the title
Recconect DB after closing.
Reconnect DB after closing.
Jan 10, 2020
sio4
added
s: accepted
This proposal was accepted. Someone can start working on it.
and removed
s: triage
Some tests need to be run to confirm the issue
labels
Sep 24, 2022
sio4
added
bug
Something isn't working
s: fixed
was fixed or solution offered
and removed
s: accepted
This proposal was accepted. Someone can start working on it.
labels
Sep 24, 2022
Description
If this is a feature request, explain why it should be added. Specific use-cases are best.
For bug reports, please provide as much relevant info as possible.
When
Connection
closed, it unable to open again.Steps to Reproduce the Problem
Please describe in painful detail what you did (so others can play along with you) to get to this point. This includes things like the exact command(s) you used, or the
curl
command you used, that sort of thing.Expected Behavior
connection will recconnect after closing
Actual Behavior
Info
Should set
Store = nil
in Connection's Close method.The text was updated successfully, but these errors were encountered: