/NeonRabbitGW

NeonRabbitGW is a gateway for micro service, support Dapr and some funny features

Primary LanguageRust

NeonRabbitGW

A common micro-service API gateway, support normal http/rpc service, can support dapr framework also.
Production use in project NeonRabbit

Feature

  • support invoke Dapr service
  • support Dapr sidebar, single two models
  • Dapr service auto descovery
  • support HTTP/HTTP2 proxy
  • support websockety
  • support traffic cache
  • rate limit
  • security configuration, ip whitelist, ip block, url block for ip etc.
  • support plugin system

Usage

running model is config by config.rs model setting

# single model: connect to regiter centre directly, not depend on dapr
# can not tracking the Gateway service in Dapr default `zipkin`, add tracking
# process by `NeonRabbitGW` self
cargo run

# dapr model:
dapr.exe run --app-id neon_gw  --app-protocol http  --app-port 8080  --dapr-http-port 4500   -- cargo.exe run

Compnent

when developing, need run the compnent of project

# Consul
consul.exe agent -dev -ui -client 0.0.0.0

# Zipkin
java -jar zipkin-server-2.24.0-exec.jar

Call Sample

# gw -->>> schedule -->>> sp
http://localhost:8080/neon_schedule/job

Devops

java -jar jenkins-cli.jar -s http://xxxxxx:8080/ -auth xx:xxxxx  delete-builds xxxxx 0-40

curl -X GET http://xxxxxxxx:5000/v2/_catalog

curl -X GET http://xxxxxxx:5000/v2/neon-rabbit-gw/tags/list

kubectl create namespace neon