Documentation
¶
Index ¶
- func ExecAt(nodeID, fnName string, fn func() error)
- func Init()
- func NewIPC(data map[string]int, toID string) (string, error)
- func ReadIPC(subPath string) (map[string]string, error)
- func ResolveNodeID(peerID string) int
- func SendIPC(fileName string) error
- func SendRPC(addr string, payload map[string]interface{}) (map[string]interface{}, error)
- func WaitForAckIPC(fileName string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Init ¶
func Init()
Init inits the samchelper package It sets:
- nodeID from NODE_ID env
- ipcDir from IPC_DIR env
- ipcPrefix from IPC_PREFIX env
- nodesFile from NODES_FILE
func NewIPC ¶
NewIPC writes data into subPath The data will be written into ipcDir/subPath/md5(data) It uses NODES environment variable to determine node number from toID
func ResolveNodeID ¶
ResolveNodeID resolves ethereum peerID into nodeID
func WaitForAckIPC ¶
func WaitForAckIPC(fileName string)
WaitForAckIPC waits until given fileName exists inside ack folder
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.