https://github.com/ardikabs/gonvoy
A thin Go framework to write an HTTP Filter extension on Envoy Proxy
https://github.com/ardikabs/gonvoy
envoy-plugin envoy-proxy golang
Last synced: 10 months ago
JSON representation
A thin Go framework to write an HTTP Filter extension on Envoy Proxy
- Host: GitHub
- URL: https://github.com/ardikabs/gonvoy
- Owner: ardikabs
- License: mit
- Created: 2023-10-07T06:06:11.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-09-16T07:53:22.000Z (almost 2 years ago)
- Last Synced: 2024-09-16T09:23:39.428Z (almost 2 years ago)
- Topics: envoy-plugin, envoy-proxy, golang
- Language: Go
- Homepage:
- Size: 476 KB
- Stars: 3
- Watchers: 3
- Forks: 1
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Gonvoy
[](https://pkg.go.dev/github.com/ardikabs/gonvoy)
[](https://goreportcard.com/report/github.com/ardikabs/gonvoy)
[](https://github.com/ardikabs/gonvoy/actions/workflows/test.yaml)
[](https://codecov.io/gh/ardikabs/gonvoy)
A thin Go framework to write an HTTP Filter extension on Envoy Proxy. It leverages the Envoy [HTTP Golang Filter](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/golang_filter) as its foundation.
## Features
* Full Go experience for building Envoy HTTP Filter extension.
* Porting `net/http` interface experience to extend Envoy Proxy behavior with [HTTP Golang Filter](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/golang_filter).
* Logging with [go-logr](https://github.com/go-logr/logr).
* [Stats](https://www.envoyproxy.io/docs/envoy/latest/intro/arch_overview/observability/statistics#arch-overview-statistics) support; Enabling users to generate their own custom metrics.
* Panic-free support; If a panic does occur, it is ensured that it won't break the user experience, particularly the Envoy proxy processes, as it will be handled in a graceful manner by returning a configurable response, defaults to `500`.
### Compatibility Matrix
| Gonvoy | Envoy Proxy |
|-----------------|-----------------|
| v0.3 | v1.29 |
| v0.4 | v1.30 |
| [latest](https://github.com/ardikabs/gonvoy) | v1.31 |
## Installation
```bash
go get github.com/ardikabs/gonvoy
```
## Development Guide
### Prerequisites
* Go 1.23 or later. Follow [Golang installation guideline](https://golang.org/doc/install).
### Setup
* Install Git.
* Install Go 1.23.
* Clone the project.
```bash
git clone -b plugin git@github.com:ardkabs/gonvoy.git
```
* Create a meaningful branch
```bash
git checkout -b
```
* Test your changes.
```bash
make test
```
* We highly recommend instead of only run test, please also do audit which include formatting, linting, vetting, and testing.
```bash
make audit
```
* Add, commit, and push changes to repository
```bash
git add .
git commit -s -m ""
git push origin
```
For writing commit message, please use [conventionalcommits](https://www.conventionalcommits.org/en/v1.0.0/) as a reference.
* Create a Pull Request (PR). In your PR's description, please explain the goal of the PR and its changes.
### Testing
#### Unit Test
```bash
make test
```
### Try It
To try this framework in action, heads to [example](./example) directory.
## License
[MIT](./LICENSE)