Skip to content

Commit

Permalink
print testing
Browse files Browse the repository at this point in the history
  • Loading branch information
yecs1999 authored May 19, 2022
1 parent 079ba81 commit 68dda67
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,14 @@ func (t timeoutDriver) Open(connection string) (_ driver.Conn, err error) {
return nil, err
}
}

fmt.Printf("%s\n",connection)
for _, setting := range strings.Fields(connection) {
s := strings.Split(setting, "=")
fmt.Printf("Strings split: %s\n",s)
if s[0] == "read_timeout" {
fmt.Printf("Value: %s\n",s[1])
val, err := strconv.Atoi(s[1])
fmt.Printf("%s %s\n",val,err)
if err != nil {
return nil, fmt.Errorf("Error interpreting value for read_timeout")
}
Expand Down

0 comments on commit 68dda67

Please sign in to comment.