solmul

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2022 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

func ParseEndpoint

func ParseEndpoint(input string) (endpoint endPoint, err error)

ParseEndpoint translates a string into proper solana endpoint.

• mainnet-beta, localhost, devnet, testnet, and mainnet-beta-serum is translated into proper urls.

• other strings are treated like urls.

• web socket port will be rpc port number if rpc port number is explicitly set; otherwise it assumes web socket and rpc are running on same port.

func RunServer

func RunServer(ctx context.Context, rpc_urls, ws_urls []string, rpc_port, ws_port int) (<-chan struct{}, error)

RunServer launches servers for rpc and websockets in a separate go routine.

• the servers can be shut down by cancelling the input context.

• if rpc_port and ws_port is the same, only one single server will be launched.

• returned channel can be used to wait on the process to finish.

Types

type UnknownJsonMap

type UnknownJsonMap map[string]bson.RawValue

UnknownJsonMap contains all the value that is in json but not explicitly defined in struct

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL