divan_data_manager

package module
Version: v0.3.10 Latest Latest
Warning

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

Go to latest
Published: Jan 11, 2021 License: MIT Imports: 4 Imported by: 0

README

Divan Data Manager

Lightweight api to manage couchbase information from Go server.

go get github.com/a-novel/divan-data-manager@v0.3.10

Usage

package my_package

import(
	"github.com/a-novel/divan-data-manager"
)

func main() {
	clusterUsername := "Administrator"
	clusterPassword := "password"
	clusterURL := "127.0.0.1" // You can also leave it blank if on localhost.
	
	buckets, _ := divan_data_manager.GetBucketsData(clusterUsername, clusterPassword, clusterURL)
	
	// Find a bucket by name.
	myBucket := divan_data_manager.FindBucket("bucket_1", buckets)
	
	if myBucket != nil {
		// Do something.
    } else {
    	// Bucket not found.
    }
}

License

Licensed under MIT, for A-Novel.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindBucket

func FindBucket(name string, buckets []*divan_types.BucketData) *divan_types.BucketData

func GetBucketsData

func GetBucketsData(username, password, url string) ([]*divan_types.BucketData, error)

func GetClusterData

func GetClusterData(username, password, url string) (*divan_types.ClusterData, error)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL