good morning!!!!

Skip to content
Snippets Groups Projects
Commit 2af5d53f authored by Garet Halliday's avatar Garet Halliday
Browse files

.

parent 4fcc23fa
Branches ferran/fix-ancient
Tags v0.2.11
No related merge requests found
...@@ -15,9 +15,9 @@ import ( ...@@ -15,9 +15,9 @@ import (
"pggat2/lib/bouncer/frontends/v0" "pggat2/lib/bouncer/frontends/v0"
"pggat2/lib/gat" "pggat2/lib/gat"
"pggat2/lib/gat/pool" "pggat2/lib/gat/pool"
"pggat2/lib/gat/pool/dialer"
"pggat2/lib/gat/pool/pools/session" "pggat2/lib/gat/pool/pools/session"
"pggat2/lib/gat/pool/pools/transaction" "pggat2/lib/gat/pool/pools/transaction"
dialer2 "pggat2/lib/gat/pool/recipe/dialer"
"pggat2/lib/gsql" "pggat2/lib/gsql"
"pggat2/lib/util/maps" "pggat2/lib/util/maps"
"pggat2/lib/util/strutil" "pggat2/lib/util/strutil"
...@@ -173,7 +173,7 @@ func (T *Pools) Lookup(user, database string) *pool.Pool { ...@@ -173,7 +173,7 @@ func (T *Pools) Lookup(user, database string) *pool.Pool {
Database: database, Database: database,
}, p) }, p)
var d dialer.Dialer var d dialer2.Dialer
dbCreds := creds dbCreds := creds
if db.Password != "" { if db.Password != "" {
...@@ -205,7 +205,7 @@ func (T *Pools) Lookup(user, database string) *pool.Pool { ...@@ -205,7 +205,7 @@ func (T *Pools) Lookup(user, database string) *pool.Pool {
dir = dir + ".s.PGSQL." + strconv.Itoa(port) dir = dir + ".s.PGSQL." + strconv.Itoa(port)
d = dialer.Net{ d = dialer2.Net{
Network: "unix", Network: "unix",
Address: dir, Address: dir,
AcceptOptions: acceptOptions, AcceptOptions: acceptOptions,
...@@ -219,7 +219,7 @@ func (T *Pools) Lookup(user, database string) *pool.Pool { ...@@ -219,7 +219,7 @@ func (T *Pools) Lookup(user, database string) *pool.Pool {
} }
// connect over tcp // connect over tcp
d = dialer.Net{ d = dialer2.Net{
Network: "tcp", Network: "tcp",
Address: address, Address: address,
AcceptOptions: acceptOptions, AcceptOptions: acceptOptions,
......
package pool package pool
import "pggat2/lib/gat/pool/dialer" import (
"pggat2/lib/gat/pool/recipe/dialer"
)
type Recipe struct { type Recipe struct {
Dialer dialer.Dialer Dialer dialer.Dialer
......
File moved
package recipe
import (
"pggat2/lib/gat/pool/recipe/dialer"
)
type Options struct {
Dialer dialer.Dialer
MinConnections int
// MaxConnections is the max number of simultaneous connections from this recipe. 0 = unlimited
MaxConnections int
}
package recipe
type Recipe struct {
options Options
}
func NewRecipe(options Options) *Recipe {
return &Recipe{
options: options,
}
}
func (T *Recipe) Dial() {
}
package recipe
type Server struct {
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment