camlistore: github.com/ginabythebay/camlistore/pkg/blobserver/replica Index | Files

package replica

import "github.com/ginabythebay/camlistore/pkg/blobserver/replica"

Package replica registers the "replica" blobserver storage type, providing synchronous replication to one more backends.

Writes wait for minWritesForSuccess (default: all). Reads are attempted in order and not load-balanced, randomized, or raced by default.

Example config:

"/repl/": {
    "handler": "storage-replica",
    "handlerArgs": {
        "backends": ["/b1/", "/b2/", "/b3/"],
        "minWritesForSuccess": 2
    }
},

Index

Package Files

replica.go

func NewForTest Uses

func NewForTest(sto []blobserver.Storage) blobserver.Storage

NewForTest returns a replicated storage that writes, reads, and deletes from all the provided storages.

Package replica imports 10 packages (graph). Updated 2018-04-16. Refresh now. Tools for package owners.