Help us shape the future of Go! Take the 2026 Go Developer Survey

client_examples/

directory
v0.1.6 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2026 License: BSD-3-Clause

README

irodsfsd client examples

The examples use the reusable Go client in client/ and connect to the gRPC endpoint. The default endpoint is unix:///var/lib/irodsfsd/comm.sock; use -endpoint tcp://host:13020 when the daemon listens on TCP. They enable background reconnection and attach a command field to the logger; the client adds a unique clientID field.

Mount

mount reads one JSON file containing a protobuf MountConfig. It asks the server to generate a mount ID unless -mount-id is supplied.

cp client_examples/mount/mount_config.json.example /tmp/mount.json
# Edit /tmp/mount.json before running it; it contains placeholder credentials.
go run ./client_examples/mount -endpoint tcp://127.0.0.1:13020 /tmp/mount.json
go run ./client_examples/mount -mount-id my-mount /tmp/mount.json

A successful request prints the assigned mount ID and the state returned by the server:

mount_id: my-mount
state: MOUNT_STATE_MOUNTING

List mounts

go run ./client_examples/mount_list -endpoint tcp://127.0.0.1:13020

The command prints mount ID, current state, and local mount path as a table.

Unmount

go run ./client_examples/unmount -endpoint tcp://127.0.0.1:13020 my-mount

DAVFS unmount may wait for cache synchronization, so the default unmount RPC timeout is five minutes. Override it with -timeout when necessary.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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