conn

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// TMENDICANT Ends a recovery scan.
	TMENDRSCAN = 0x00800000

	/**
	 * Disassociates the caller and marks the transaction branch
	 * rollback-only.
	 */
	TMFAIL = 0x20000000

	/**
	 * Caller is joining existing transaction branch.
	 */
	TMJOIN = 0x00200000

	/**
	 * Use TMNOFLAGS to indicate no flags value is selected.
	 */
	TMNOFLAGS = 0x00000000

	/**
	 * Caller is using one-phase optimization.
	 */
	TMONEPHASE = 0x40000000

	/**
	 * Caller is resuming association with a suspended
	 * transaction branch.
	 */
	TMRESUME = 0x08000000

	/**
	 * Starts a recovery scan.
	 */
	TMSTARTRSCAN = 0x01000000

	/**
	 * Disassociates caller from a transaction branch.
	 */
	TMSUCCESS = 0x04000000

	/**
	 * Caller is suspending (not ending) its association with
	 * a transaction branch.
	 */
	TMSUSPEND = 0x02000000

	/**
	 * The transaction branch has been read-only and has been committed.
	 */
	XA_RDONLY = 0x00000003

	/**
	 * The transaction work has been prepared normally.
	 */
	XA_OK = 0
)

Variables

This section is empty.

Functions

This section is empty.

Types

type OracleXAConn

type OracleXAConn struct {
	driver.Conn
}

func (*OracleXAConn) Commit

func (c *OracleXAConn) Commit(xid string, onePhase bool) error

func (*OracleXAConn) End

func (c *OracleXAConn) End(xid string, flags int) error

func (*OracleXAConn) Forget

func (c *OracleXAConn) Forget(xid string) error

func (*OracleXAConn) GetTransactionTimeout

func (c *OracleXAConn) GetTransactionTimeout() time.Duration

func (*OracleXAConn) IsSameRM

func (c *OracleXAConn) IsSameRM(resource XAResource) bool

func (*OracleXAConn) Recover

func (c *OracleXAConn) Recover(flag int) []string

func (*OracleXAConn) Rollback

func (c *OracleXAConn) Rollback(xid string) error

func (*OracleXAConn) SetTransactionTimeout

func (c *OracleXAConn) SetTransactionTimeout(duration time.Duration) bool

func (*OracleXAConn) Start

func (c *OracleXAConn) Start(xid string, flags int) error

func (*OracleXAConn) XAPrepare

func (c *OracleXAConn) XAPrepare(xid string) (int, error)

type XAResource

type XAResource interface {
	Commit(xid string, onePhase bool) error
	End(xid string, flags int) error
	Forget(xid string) error
	GetTransactionTimeout() time.Duration
	IsSameRM(resource XAResource) bool
	XAPrepare(xid string) (int, error)
	Recover(flag int) []string
	Rollback(xid string) error
	SetTransactionTimeout(duration time.Duration) bool
	Start(xid string, flags int) error
}

Jump to

Keyboard shortcuts

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