An interactive web UI for gRPC, along the lines of postman
MIT License
Bot releases are hidden (Show)
Published by gpassini 6 months ago
Published by gpassini 6 months ago
Published by gpassini 12 months ago
Published by gpassini about 1 year ago
Published by dragonsinth about 2 years ago
Published by jhump over 2 years ago
This release includes numerous new features and some bug fixes. The release binaries on GitHub and the published docker images also now include options for arm64 architecture.
These changes impact usage of both the command-line tool and the Go packages.
google.protobuf.Any
messages that may be attached to any RPC error. Previously, if an error contained details, the UI would not show them.bytes
fields.google.protobuf.Value
would result in the UI continuing to show "unset", instead of providing a text input for defining the value. This has been fixed.google.protobuf.Timestamp
fields would cause errors in Safari browsers, due to the use of a date format that was not universally accepted by all browsers. This has been fixed.standalone
Go package), they would also be served using "public" cache control headers.
This release adds some additional command-line flags:
-base-path
flag allows the UI to be served from a path other than /
. This can be useful when grpcui
is behind a reverse proxy, so /
gets routed to other servers and some other sub-path can be routed to grpcui
.-H
, -rpc-header
, and -expand-header
flags supported by grpcurl
are now also supported by grpcui
. Headers defined this way will not appear in the web form UI, but will be added to the RPC request.-use-reflection
flag supported by grpcurl
is now also supported by grpcui
. This allows the UI augment the set of descriptors retrieved from a server (via service reflection) with local proto sources. This can be useful for the UI to understand extensions and custom options that the server may not actually be aware of.-preserve-header
flag has been added that allows the "invoke" XHR endpoint to propagate HTTP headers it receives as request metadata to the server. This can be useful if grpcui
is behind an authenticating proxy, like where a JWT (or other credential) header is transparently added to each request which should be forwarded to backend RPC servers.-vvv
flag previously would log the body of all HTTP requests and responses that the grpcui
web server received. When the body was binary and the log was streaming to a terminal, this could result in unpleasant output -- not only because the binary data is unreadable, but also because some binary data could be interpreted as control/escape sequences by the terminal. Binary responses are now hex-encoded in the log.-extra-js
and -extra-css
flags can be used to inject custom JS and CSS resources into the index page. This allows for a wide variety of customizations not previously possible without a browser extension.-also-serve
flag can be used to have the grpcui
web server host other files/assets. This can be useful, for example, if a custom CSS resource is used which references things like custom fonts or images.-examples
flag allows configuring the UI to show a library of canned "example" requests, loaded from a JSON file.AllMethodsViaInProcess
and AllFilesViaInProcess
, have been added to further simplify the use case where a gRPC UI is embedded into a Go gRPC server. They populate the list of exposed services and file descriptors using the actual services registered with a *grpc.Server
and can utilize every proto file generated and linked into the program (even those that are not used or imported by the files that define the services).AddJSFile
, AddCSSFile
, and ServeAssetFile
(similar to existing functions AddJS
, AddCSS
, and ServeAsset
). Furthermore, a new ServeAssetDirectory
allows easily adding an entire folder of static resources to be served by the handler.WithExamples
and WithExampleData
, allow specifying a library of canned "example" requests, which will be shown in the UI.Published by jhump about 3 years ago
This release includes several fixes and improvements to the web UI and some additional features in the command-line tool.
These changes impact usage of both the command-line tool and the Go packages.
math.MaxInt64
nanoseconds, operations would timeout almost immediately. This was due to the overflow leading to a negative timeout, which was expired immediately upon creation. This has been fixed: on overflow, a value of math.MaxInt64
nanoseconds is used instead (which is nearly 300 years, so will certainly suffice).grpcui
would accept a protobuf source file that could not actually be compiled with protoc
. Some were the opposite, where grpcui
would fail to parse a source file that protoc
would accept and compile. More details can be found in the release notes for the changes to the protoparse
library, versions v1.9.0, v1.10.0, and v1.10.1.optional
keyword, even when a syntax = "proto3"
is present. This is a new feature that adds the ability to detect presence of a scalar field, even if it has a default/zero value.-connect-fail-fast=false
command-line flag that causes the server to keep retrying (with backoff between attempts) in the face of what would otherwise be considered permanent failures. For example, errors resolving DNS host names and "connection refused" errors will not cause the program to abort. Instead, the server will keep retrying until a connection is established or until the -connect-timeout
has elapsed. This can be useful if grpcui
is deployed alongside a server such that the server may not yet be ready and listening on the port when grpcui
first tries to connect.Published by jhump about 4 years ago
This release includes a fix for a bug in the web UI, a small fix for users that build grpcui
from source, and some new features.
These changes impact usage of both the command-line tool and the Go packages.
This release adds some additional command-line flags:
-default-header
flag allows you to define request metadata headers from the command-line. Since request metadata is defined in the web UI, via form, the values indicated on the command-line are populated as defaults. So when you load the web UI, the metadata table will be populated with those values instead of being empty.-debug-client
flag allows you to enable debug logging inside the web UI client. The log messages are logged to the browser's JavaScript console. At the moment, these are fairly sparse, and related to internal callbacks during handling of updates to the UI when the request form is modified. But additional more useful log messages may be added in the future.This release fixes a build issue related to the removal of a package from a recent version of the "golang.google.com/grpc"
module. This impacted users that linked in this package to their own module or that attempted to build grpcui
from source in their own module workspace where the newer version of the gRPC module was in use. The work-arounds were to either explicitly upgrade the version of "github.com/fullstorydev/grpcurl"
(a dependency of grpcui
) to v1.6.1 or newer or to downgrade the version of "golang.google.com/grpc"
to v1.31.0. This has now been remedied so upgrading to v1.1.0 of grpcui
no longer requires either of these work-arounds and should be compatible with any constraints in one's go.mod
file.
Published by jhump over 4 years ago
This release marks grpcui
reaching a stable state with fundamental features all working correctly.
There are numerous changes and fixes since the previous release, v0.2.1.
These changes impact usage of both the command-line tool and the Go packages.
uint32
and fixed32
field types, making it impossible to enter half of the valid values for these fields. This has been corrected.json_name
field option can override this to a custom JSON key. So now the JSON keys can refer to the correct JSON field names and be successfully processed. Instead of requiring the protobuf field name, it only accepts protobuf field names as a last resort (if a given JSON key does not match the camel-case version of a field name or a json_name
option).-open-browser
flag.AllFilesViaReflection
and AllMethodsViaReflection
functions have been updated to accept a grpc.ClientConnInterface
argument, instead of a *grpc.ClientConn
. This makes them more flexible as any concrete type can be used that implements the correct interface. This change to the API should be backwards-compatible at the source level.HandlerViaReflection
function has been updated to accept a grpc.ClientConnInterface
argument, instead of a *grpc.ClientConn
. This makes it more flexible as any concrete type can be used that implements the correct interface. This change to the API should be backwards-compatible at the source level.github.com/fullstorydev/grpcui
package. But now they can be supplied as options to standalone.Handler
to create a single, fully-self-contained handler which serves customized content.Published by jhump about 5 years ago
This fixes an issue in the go.mod
file that would prevent earlier versions from working with modules when using Go 1.13.
Published by jhump over 5 years ago
This release addresses numerous issues that have been filed since the initial v0.1.0 release. The major version is still zero; we still want a little more activity and to tackle some other open issues before creating a 1.0 release.
-unix
command-line flag, for connecting to a server that is listening on a Unix domain socket.-max-time
command-line flag, which applies default timeouts to RPCs issued via the UI.-max-msg-size
command-line flag, which can override the default response message size limit of 4mb.grpcui
's connection to an RPC server would never recover if the connection were broken (such as transient network issue or restarting the backend server). It now reconnects automatically, though may take some time to recover (subject to the Go gRPC client's auto-reconnect and exponential backoff policies).google.protobuf.Any
could result in error messages in the web UI or be rendered incorrectly.Published by jhump almost 6 years ago
This first release has major version zero because the repo is not very mature yet. To our knowledge, the tool is feature-complete and fully functional. But the code base is young, and is lacking things like automated tests (so there are likely some bugs lurking, and maybe even a key missing feature or two).
We'd like to get more miles on the tool before we're ready to call it "1.0". Please file an issue if you find problems with the tool or have features you'd like to see added.