Beispiel #1
0
// Connect makes a singled connection, returning a simplified result struct.
func Connect(path string, verbose bool) *results.Result {
	conn := connector.Connector{}.New(path, 0)
	conn.Verbose = verbose

	result := conn.Connect()
	return &result
}
Beispiel #2
0
// Setup Connector via Configurator
func setup(config *Configurator) *connector.Connector {
	validate(config)
	header(config)
	conn := connector.Connector{}.New(config.Path, config.NumConns)
	conn.Rate = config.Rate
	conn.Verbose = config.Verbose
	return &conn
}