Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Connection ¶
Connection Database connection
func (*Connection) Close ¶
func (conn *Connection) Close()
Close Returning a database connection to the connection pool
type DbPool ¶
type DbPool struct { Url string InitialSize int ExpandSize int MaxOpen int MinOpen int TestConn bool PoolQueue DbPoolQueue // contains filtered or unexported fields }
DbPool Connection Pool
func (*DbPool) Close ¶
func (pool *DbPool) Close(conn *Connection)
Close Returning used connections to the connection pool
func (*DbPool) GetConn ¶
func (pool *DbPool) GetConn() (*Connection, error)
GetConn Get a connection
type DbPoolQueue ¶
type DbPoolQueue struct { First *DbPoolQueueItem Last *DbPoolQueueItem Size int // contains filtered or unexported fields }
DbPoolQueue Queue
func (*DbPoolQueue) Poll ¶
func (dp *DbPoolQueue) Poll() *Connection
Poll Taking elements out of the queue
type DbPoolQueueItem ¶
type DbPoolQueueItem struct { Conn *Connection Next *DbPoolQueueItem }
DbPoolQueueItem Elements inside the queue
Click to show internal directories.
Click to hide internal directories.