-
Notifications
You must be signed in to change notification settings - Fork 72
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
91d11d2
commit 75a8c6d
Showing
17 changed files
with
167 additions
and
151 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,25 @@ | ||
# Mesher command Line | ||
when you start mesher process, you can use mesher command line to specify configurations like below | ||
When you start a mesher process, you can use mesher command line to specify configurations as follows: | ||
```shell | ||
mesher --config=mesher.yaml --service-ports=rest:8080 | ||
``` | ||
|
||
|
||
### Options | ||
|
||
|
||
**--config** | ||
>*(optional, string)* the path to mesher configuration file, default value is {current_bin_work_dir}/conf/mesher.yaml | ||
|
||
>*(optional, string)* The path to mesher configuration file, default value is {current_bin_work_dir}/conf/mesher.yaml | ||
**--mode** | ||
>*(optional, string)* mesher has 2 work mode, sidecar and edge, default is sidecar | ||
|
||
>*(optional, string)* Mesher has 2 work modes, sidecar and edge, default is sidecar | ||
**--service-ports** | ||
>*(optional, string)* running as sidecar, mesher need to know local service ports, | ||
|
||
>*(optional, string)* Running as sidecar, mesher needs to know local service ports, | ||
this is to tell mesher service port list, | ||
The value format is {protocol}-{suffix} or {protocol} | ||
if service has multiple protocol, you can separate with comma "rest-admin:8080,grpc:9000". | ||
default is empty, in that case mesher will use header X-Forwarded-Port as local service port, | ||
if it is empty also mesher can not communicate to your local service | ||
The value format is {protocol}-{suffix} or {protocol}. | ||
If service has multiple protocols, you can separate with comma "rest-admin:8080, grpc:9000", | ||
default is empty. In that case mesher will use header X-Forwarded-Port as local service port, | ||
if header X-Forwarded-Port is also empty, mesher can not communicate to your local service. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,45 +1,49 @@ | ||
# Local Health check | ||
you can use health checker to check local service health, | ||
when service instance is not healthy, mesher will update the instance status in registry service to "DOWN" | ||
so that other service | ||
can not discover this instance. If the service is healthy again, mesher will update status to "UP", | ||
You can use health checker to check local service health. | ||
When service instance is unhealthy, mesher will update the instance status in registry service to "DOWN" | ||
so that other services | ||
can not discover this instance. After the service becoming healthy again, mesher will update the status to "UP", | ||
then other instance can discover it again. | ||
currently this function works only when you use service center as registry | ||
|
||
examples: | ||
|
||
Check local http service | ||
```yaml | ||
localHealthCheck: | ||
- port: 8080 | ||
protocol: rest | ||
uri: /health | ||
interval: 30s | ||
match: | ||
status: 200 | ||
body: ok | ||
``` | ||
Currently this function works only when using service center as registry. | ||
|
||
### Options | ||
Examples: | ||
|
||
- Check local http service | ||
|
||
```yaml | ||
localHealthCheck: | ||
- port: 8080 | ||
protocol: rest | ||
uri: /health | ||
interval: 30s | ||
match: | ||
status: 200 | ||
body: ok | ||
``` | ||
|
||
### Options | ||
|
||
**port** | ||
>*(require, string)* must be a port number, mesher is only responsible to check local service, | ||
it use 127.0.0.1:{port} to check service | ||
|
||
>*(require, string)* Must be a port number, mesher is only responsible to check local services, | ||
it use 127.0.0.1:{port} to check services. | ||
|
||
**protocol** | ||
>*(optional, string)* mesher has a built-in checker "rest",for other protocol, | ||
will use default TCP checker unless you implement your own checker | ||
|
||
>*(optional, string)* Mesher has a built-in checker "rest",for other protocols, | ||
will use default TCP checker unless implementing your own checker. | ||
|
||
**uri** | ||
>*(optional, string)* uri start with /. | ||
|
||
>*(optional, string)* Uri start with /. | ||
|
||
**interval** | ||
>*(optional, string)* check interval, you can use number with unit: 1m, 10s. | ||
>*(optional, string)* Check interval, you can use number with unit: 1m, 10s. | ||
**match.status** | ||
>*(optional, string)* the http response status must match status code | ||
>*(optional, string)* The http response status must match status code. | ||
**match.body** | ||
>*(optional, string)* the http response body must match body | ||
|
||
>*(optional, string)* The http response body must match body. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
# Build mesher | ||
you need to build and release your mesher after the customization | ||
You need to build and release your mesher after customization. | ||
|
||
### Build binary | ||
you can refer to build/build_proxy to see how we build mesher binary and docker image. | ||
You can refer to build/build_proxy to see how we build mesher binary and docker image. | ||
|
||
build/docker/proxy/Dockerfile is a example about how to make a docker image | ||
build/docker/proxy/Dockerfile is a example about making a docker image |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.