Giter VIP home page Giter VIP logo

envoy_control_plane's Introduction

Envoy control plane Example

Topology

This repository represents my experiments while trying to understand in detail how the Envoy control plane worked. As compared to envoy proxy proper there isn't a lot of detailed HOW-TOs on the control plane, but fortunately I found a few good references, specially this one: Envoy hello World

As far code examples, there a few gems that provide great building blocks:

So, why go through this exercise? Several reasons:

  • The code the article above did not work anymore due to changes in the Envoy API code
  • I wanted to learn by doing it mostly from scratch
  • I wanted to use Golang's core library as much as possible. In other words, the least number of third-party dependencies.

This is still a work in progress. I am still polishing the example.

Environment

This was tested with the following:

  • MacOS Mojave 10.14.3
  • go1.11.5 darwin/amd64
  • Envoy v1.9.0

Topology Details

One of the challenges in this exercise was to have the Envoy Proxy run as a container and the application natively. It is not straightforward to have a container access an application running on the host. It took me a while but I finally managed to get the right envoy configuration.

I wanted to have the control plane running natively on the host because I wanted to tinker with it: change, step debug, rerun, stop, Printf, etc.

I had to use two main tricks to have this working:

Running the example

Assuming you have docker installed and all the other basic stuff, everything you need to run the example should be under testdata.

Run:

./build_all.sh

If everything goes well, you should see the following docker images and a running container

REPOSITORY                         TAG                 IMAGE ID            CREATED              SIZE
envoy_control_plane                v1.9.0              d21d40d3f20a        About a minute ago   189MB
envoyproxy/envoy                   v1.9.0              b02c1418b106        4 months ago         164MB


CONTAINER ID        IMAGE                        COMMAND                  CREATED             STATUS              PORTS                                                NAMES
fb862e600bb0        envoy_control_plane:v1.9.0   "/usr/bin/dumb-init …"   2 minutes ago       Up 2 minutes        0.0.0.0:10000->10000/tcp, 0.0.0.0:19000->19000/tcp   envoy_1_9_0

envoy_control_plane's People

Contributors

benderscript avatar salrashid123 avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

yiqinguo

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.