tarantool / go-tarantool

Tarantool 1.10+ client for Go language
https://pkg.go.dev/github.com/tarantool/go-tarantool/v2
BSD 2-Clause "Simplified" License
180 stars 57 forks source link

pool: add Instance type #373

Closed oleg-jukovec closed 7 months ago

oleg-jukovec commented 7 months ago

The type Instance:

type Instance struct {
    // Name is an unique name of the instance.
    Name   string
    // Dialer will be used to create a connection to the instance.
    Dialer tarantool.Dialer
    // Opts will be used to specify a connection options.
    Opts   tarantool.Opts
}

The type allows to specify a dialer and connection options per a pool instance. It is used in pool.Connect, pool.ConnectWithOpts and pool.Add to specify an instance configuration now.

Closes https://github.com/tarantool/go-tarantool/issues/356