Documentation ¶
Index ¶
- func ComputeAddrsEdge(as []PeerAddr) uint64
- func ComputeHeadsEdge(hs []LogHead) uint64
- func DefaultBoostrapPeers() []peer.AddrInfo
- func FreeLocalAddr() ma.Multiaddr
- func GenerateRandomBytes(n int) []byte
- func InstanceFromJSON(b []byte, i interface{})
- func JSONFromInstance(i interface{}) []byte
- func LevelFromDebugFlag(debug bool) logging.LogLevel
- func MakeToken(n int) string
- func MustParseAddr(str string) ma.Multiaddr
- func NewBadgerDatastore(dirPath, name string, lowMem bool) (kt.TxnDatastoreExtended, error)
- func NewDatastore(repoPath string, opts *badger.Options) (kt.TxnDatastoreExtended, error)
- func ParseBootstrapPeers(addrs []string) ([]peer.AddrInfo, error)
- func SchemaFromInstance(i interface{}, expandedStruct bool) *jsonschema.Schema
- func SchemaFromSchemaString(s string) *jsonschema.Schema
- func SetJSONID(id core.InstanceID, json []byte) []byte
- func SetJSONProperty(name string, value interface{}, json []byte) []byte
- func SetLogLevels(systems map[string]logging.LogLevel) error
- func SetupDefaultLoggingConfig(file string) error
- func StopGRPCServer(server *grpc.Server)
- func TCPAddrFromMultiAddr(maddr ma.Multiaddr) (addr string, err error)
- type LogHead
- type PeerAddr
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ComputeAddrsEdge ¶
func ComputeHeadsEdge ¶
func DefaultBoostrapPeers ¶
func FreeLocalAddr ¶
func GenerateRandomBytes ¶
func InstanceFromJSON ¶
func InstanceFromJSON(b []byte, i interface{})
func JSONFromInstance ¶
func JSONFromInstance(i interface{}) []byte
func LevelFromDebugFlag ¶
LevelFromDebugFlag returns the debug or info log level.
func MustParseAddr ¶
func NewBadgerDatastore ¶
func NewBadgerDatastore(dirPath, name string, lowMem bool) (kt.TxnDatastoreExtended, error)
NewBadgerDatastore returns a badger based datastore.
func NewDatastore ¶ added in v0.0.2
NewDatastore returns a badger based datastore.
func SchemaFromInstance ¶
func SchemaFromInstance(i interface{}, expandedStruct bool) *jsonschema.Schema
func SchemaFromSchemaString ¶
func SchemaFromSchemaString(s string) *jsonschema.Schema
func SetJSONProperty ¶
func SetLogLevels ¶
SetLogLevels sets levels for the given systems.
func SetupDefaultLoggingConfig ¶
SetupDefaultLoggingConfig sets up a standard logging configuration.
func StopGRPCServer ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.