utils

package
v0.0.0-...-b2c9b18 Latest Latest
Warning

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

Go to latest
Published: May 10, 2019 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TxLevelReadCommitted = iota + 1
	TxLevelRepeatableRead
	TxLevelSerializable
)

Variables

This section is empty.

Functions

func BeginTransaction

func BeginTransaction(orm *xorm.Engine) (*xorm.Session, error)

BeginTansaction starts transaction for ORM with default isolation level Returns transaction pointer and error (nil or prefixed) In case of error the transaction is always closed

func GetEvent

func GetEvent(c echo.Context) string

GetEvent return string description of request from Echo.context

func GetSHA3Hash

func GetSHA3Hash(data string) string

GetSHA3Hash return base64 encoded sha3hash

func RollbackTransaction

func RollbackTransaction(tx *xorm.Session, err error) error

RollbackTransaction rolls transaction back returns error (nil or prefixed)

Types

This section is empty.

Jump to

Keyboard shortcuts

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