storages

package
v0.0.0-...-9a65306 Latest Latest
Warning

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

Go to latest
Published: May 1, 2015 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cassandra

type Cassandra struct {
	Session *gocql.Session
	Storage
}

Cassandra .

func NewCassandraSession

func NewCassandraSession(storage *Storage) *Cassandra

NewCassandraSession .

func (*Cassandra) Connect

func (d *Cassandra) Connect() error

Connect DB

func (*Cassandra) GetAll

func (d *Cassandra) GetAll() ([]map[string]interface{}, error)

GetAll returns all data (ID, Created, Updated) in Keyspace/Table

type Driver

type Driver interface {
	Connect() error
	GetAll() ([]map[string]interface{}, error)
}

Driver interface

type ElasticSearch

type ElasticSearch struct {
	Storage
	// contains filtered or unexported fields
}

ElasticSearch .

func NewElasticSearchSession

func NewElasticSearchSession(storage *Storage) *ElasticSearch

NewElasticSearchSession .

func (*ElasticSearch) Connect

func (d *ElasticSearch) Connect() error

Connect DB

func (*ElasticSearch) GetAll

func (d *ElasticSearch) GetAll() ([]map[string]interface{}, error)

GetAll returns all data (ID, Created, Updated) in Index/Type

type Storage

type Storage struct {
	Driver   string
	Host     string
	Port     string
	Keyspace string
	Index    string
	Table    string
	ID       string
	Created  string
	Updated  string
}

Storage .

Jump to

Keyboard shortcuts

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