Discover Packages
github.com/batchcorp/plumber-schemas
command
module
Version:
v0.0.51
Opens a new window with list of versions in this module.
Published: Sep 11, 2021
License: Apache-2.0
Opens a new window with license information.
Imports: 7
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
README
README
¶
plumber-schemas
This repo contains protobuf schemas that are used by plumber
and plumber-ui
when communicating over gRPC.
IMPORTANT
The proto schemas are used to generate CLI flags in plumber
. protos/cli.proto:CLIOptions
is the entry point.
If you want to modify/add/remove cmds/args/flags, you will want to:
Clone this repo
Create a branch
Make changes to the schemas and include associated // @gotags: kong:""
comments
Run make generate/all
Copy the generated PB's into the plumber/vendor/github.com/batchcorp/plumber-schemas/...
dir
Verify that plumber works with your new flags
If yes, create a PR for the plumber-schemas
repo
Once the PR is merged, update plumber-schemas entry in plumber's go.mod
to point to new release version
Run go mod vendor
to ensure plumber fetches the appropriate plumber-schemas
version
Making changes
git co -b username/change
make generate/all
// this will run generate/go, generate/ts and run the struct tag injector
git add -a
git commit -a -m "updated schema XYZ
git push origin head
Open PR, review, merge
The build
workflow will automatically create a tag for the last commit.
Expand ▾
Collapse ▴
Documentation
¶
Code generated via protoc creates private interfaces for oneoff's. Because
there is no public interface, you must rely on verbose type switching if you
need to do dynamically instantiate things.
This script is intended to be ran after protoc code generation. It will:
Search through all *.pb.go files for private interfaces that start with is*
If a private interface is found, it will write a "extra.pb.go" file in
the pkg directory that will contain a _public_ type alias for the private
interface.
Source Files
¶
Directories
¶
build
Click to show internal directories.
Click to hide internal directories.