ttrpcurl

package module
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2023 License: ISC Imports: 9 Imported by: 0

README

ttRPCurl

ttrpcurl is a command-line tool that lets you interact with ttRPC servers. It's basically curl for ttRPC servers, and is heavily influenced by gRPCurl, which does the same thing for gRPC.

[!NOTE]
This project is still in development. Please open an issue if anything doesn't work out for you.

Installation

Install via the Go command:

go install github.com/katexochen/ttrpcurl/cmd/ttrpcurl@latest

Usage

The CLI comes with help flags, both global and on each command:

ttrpcurl --help
ttrpcurl <command> --help

Syntax compatibility with gRPCurl

This tool tries to provide intuitive usability for people familiar with grpcurl. However, as ttrpcurl isn't using Go's native flag package there are some differences. Flags in ttrpcurl require two dashes (--help).

TODOs

  • Improve client-server testscript
  • Support multiple proto files
  • Write unit tests
  • Write e2e tests
  • Support streaming calls
  • Support bidirectional streaming calls
  • Support data from file with @filename
  • Support protobuf text format
  • Use timeout and other limits

Limitations

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(conn net.Conn, source *proto.Source, marsh proto.Marshaler) *Client

func (*Client) Call

func (c *Client) Call(ctx context.Context, method string, reqBytes []byte) error

Directories

Path Synopsis
cmd
hack
testserver/grpctest
Code generated by protoc-gen-go-ttrpc.
Code generated by protoc-gen-go-ttrpc.

Jump to

Keyboard shortcuts

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