• Home
  • History
  • Annotate
  • only in this directory
Name Date Size

..11-Feb-20204 KiB

.gitignoreH A D11-Feb-2020149

.travis.ymlH A D11-Feb-202098

audit.goH A D11-Feb-2020985

cbdatasource/H11-Feb-20204 KiB

client.goH A D11-Feb-202033.8 KiB

client_test.goH A D11-Feb-2020569

conn_pool.goH A D11-Feb-20208.5 KiB

conn_pool_test.goH A D11-Feb-20208.5 KiB

ddocs.goH A D11-Feb-20205.9 KiB

examples/H11-Feb-20204 KiB

LICENSEH A D11-Feb-20201 KiB

observe.goH A D11-Feb-20206.1 KiB

perf/H11-Feb-20204 KiB

platform/H11-Feb-20204 KiB

pools.goH A D11-Feb-202030.5 KiB

pools_test.goH A D11-Feb-202010.2 KiB

populate/H11-Feb-20204 KiB

README.markdownH A D11-Feb-20201.1 KiB

streaming.goH A D11-Feb-20204.5 KiB

tap.goH A D11-Feb-20203.4 KiB

tools/H11-Feb-20204 KiB

trace/H11-Feb-20204 KiB

upr.goH A D11-Feb-202010.1 KiB

users.goH A D11-Feb-20202.9 KiB

users_test.goH A D11-Feb-20202.4 KiB

util/H11-Feb-20204 KiB

util.goH A D11-Feb-2020973

util_test.goH A D11-Feb-20201.4 KiB

vbmap.goH A D11-Feb-20203.4 KiB

vbmap_test.goH A D11-Feb-20201.1 KiB

views.goH A D11-Feb-20205.6 KiB

views_test.goH A D11-Feb-20202.8 KiB

README.markdown

1# A smart client for couchbase in go
2
3This is a *unoffical* version of a Couchbase Golang client. If you are
4looking for the *Offical* Couchbase Golang client please see
5    [CB-go])[https://github.com/couchbaselabs/gocb].
6
7This is an evolving package, but does provide a useful interface to a
8[couchbase](http://www.couchbase.com/) server including all of the
9pool/bucket discovery features, compatible key distribution with other
10clients, and vbucket motion awareness so application can continue to
11operate during rebalances.
12
13It also supports view querying with source node randomization so you
14don't bang on all one node to do all the work.
15
16## Install
17
18    go get github.com/couchbase/go-couchbase
19
20## Example
21
22    c, err := couchbase.Connect("http://dev-couchbase.example.com:8091/")
23    if err != nil {
24    	log.Fatalf("Error connecting:  %v", err)
25    }
26
27    pool, err := c.GetPool("default")
28    if err != nil {
29    	log.Fatalf("Error getting pool:  %v", err)
30    }
31
32    bucket, err := pool.GetBucket("default")
33    if err != nil {
34    	log.Fatalf("Error getting bucket:  %v", err)
35    }
36
37    bucket.Set("someKey", 0, []string{"an", "example", "list"})
38