db

package
v1.1.23 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package db contains helper functions for working with Cassandra

Index

Constants

View Source
const ErrorPrefixDb string = "dberror:"

Variables

This section is empty.

Functions

func IsDbConnError

func IsDbConnError(err error) bool

func NewSession

func NewSession(envConfig *env.EnvConfig, keyspace string, createKeyspace CreateKeyspaceEnumType) (*gocql.Session, error)

func WrapDbErrorWithQuery

func WrapDbErrorWithQuery(msg string, query string, dbErr error) error

Types

type CreateKeyspaceEnumType

type CreateKeyspaceEnumType int
const CreateKeyspaceOnConnect CreateKeyspaceEnumType = 1
const DoNotCreateKeyspaceOnConnect CreateKeyspaceEnumType = 0

Jump to

Keyboard shortcuts

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