sqlconn

package
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 7, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package sqlconn holds the handling of a dedicated *sql.Conn that both the advisory lock and the notransaction execution path need. It exists so the two do not each carry their own copy of logic that must not drift: getting it wrong strands a lock or leaks session state into the caller's pool.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Destroy

func Destroy(conn *sql.Conn)

Destroy terminates the underlying session instead of returning the connection to the pool.

This is the only way to be certain a connection carries nothing forward. (*sql.Conn).Close merely returns it to the pool with its session — and so its GUCs, temporary tables and session-level advisory locks — intact. Use it whenever the connection's state cannot be vouched for.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL