sxds

module
Version: v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2018 License: MIT

README

sxds

Release Software License Go Doc

Simple-xds for data-plane in ServiceMesh.
This works as control-plane with the minimum function.

In the beginning

This README is written on the premise that you understand data-plane-api to a certain extent.

Motivation

In realizing Service Mesh, istio is really a wonderful choice.
But istio is big and complicated!
If you want a control-plane with minimal functionality, sxds will be sufficiently effective.
This xds supports any service proxy that conforms to data-plane-api.
Currently only envoy is compliant, but envoy author Matt Klein says in the blog that data-plane-api should be generic.

Installation

Please see Github Releases.

Usage

Run

Two servers, xds and cacher will listen.

$ /path/to/sxds
Required settings
Set resources

sxds caches resources and returns DiscoverResponse for data-plane.
so you need to put the json file to the cacher server.

Please create json file with reference to sample and put json to the path resources/{node_type}.
Put each node type.

$ curl -XPUT http://{IP_ADDRESS}:8082/resources/sidecar -d @sidecar.json

The json format has the same format as DiscoveryResponse in data-plane-api.
For DiscoveryResponse, see proto file of data-plane-api.
Also do not forget to update the version when updating.

Data-Plane settings

In order to suppress memory consumption, sxds cache resources for each node type.
And sxds gets node type from node id, so you need to follow the naming convention.
Please add node_type to prefix like "sidecar-app1" for naming node id of data-plane.

e.g.) envoy

[envoy-config]

Please set dynamic_resources and static_resources like sample.

[specification of node id]

Add node_type to the prefix of the name given to the --service-node option.

$ envoy --service-node sidecar-1
Optional settings
SXDS_PRODUCTION=false # default: false
SXDS_ADS_MODE=false   # default: false
SXDS_XDS_PORT=8081    # default: 8081
SXDS_CACHER_PORT=8082 # default: 8082

For ADS mode, please click here

Architecture

architecture

xDS

gRPC server that return response to data-plane.

cacher

REST server that caches resources.

Terms

term meaning
node type The role of node which put each data-plane(e.g. sidecar, router)
resources Data to use for DiscoveryResponse(e.g. listeners, clusters)

TODO

  • Make sxdsctl that is cli tool for put resources
  • Make detailed documentation on resource json
  • Automatic generation of resources json
  • More test...

Directories

Path Synopsis
xds

Jump to

Keyboard shortcuts

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