Commit 62117b70 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 4eaaf186
......@@ -17,7 +17,7 @@
// See COPYING file for full licensing terms.
// See https://www.nexedi.com/licensing for rationale and options.
// Package client provides ZODB interface for accessing NEO cluster.
// Package client provides ZODB storage interface for accessing NEO cluster.
package client
import (
......@@ -41,7 +41,7 @@ import (
"lab.nexedi.com/kirr/neo/go/xcommon/xnet"
)
// Client talks to NEO cluster and exposes access to it via ZODB interfaces
// Client talks to NEO cluster and exposes access to it via ZODB interfaces.
type Client struct {
node neo.NodeCommon
......@@ -73,7 +73,8 @@ func (c *Client) StorageName() string {
}
// NewClient creates new client node.
// it will connect to master @masterAddr and identify with sepcified cluster name
//
// It will connect to master @masterAddr and identify with sepcified cluster name.
func NewClient(clusterName, masterAddr string, net xnet.Networker) *Client {
cli := &Client{
node: neo.NodeCommon{
......
......@@ -42,12 +42,15 @@ func RegisterStorage(scheme string, opener StorageOpener) {
storageRegistry[scheme] = opener
}
// OpenStorage opens ZODB storage by URL
// OpenStorage opens ZODB storage by URL.
//
// Only URL schemes registered to zodb package are handled.
// Users should user import in storage packages they use or zodb/wks package to
// get support work well-known storages.
// Storage authors should register their storages with RegisterStorage
// Users should import in storage packages they use or zodb/wks package to
// get support for well-known storages.
//
// Storage authors should register their storages with RegisterStorage.
//
// TODO automatically wrap a storage with Cache.
// TODO readonly
func OpenStorageURL(ctx context.Context, storageURL string) (IStorage, error) {
// no scheme -> file://
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment