github.com/hellofresh/janus@v0.0.0-20230925145208-ce8de8183c67/examples/plugin-cb/apis/example.json (about) 1 { 2 "name" : "example", 3 "active" : true, 4 "proxy" : { 5 "preserve_host" : false, 6 "listen_path" : "/example/*", 7 "upstreams" : { 8 "balancing": "roundrobin", 9 "targets": [ 10 {"target": "http://service1:8080/"} 11 ] 12 }, 13 "strip_path" : false, 14 "append_path" : false, 15 "methods" : ["GET"] 16 }, 17 "health_check": { 18 "url": "http://service1:8080/status", 19 "timeout": 3 20 }, 21 "plugins": [ 22 { 23 "name" : "retry", 24 "enabled" : false, 25 "config" : { 26 "attempts" : 3, 27 "backoff": "1s" 28 } 29 }, 30 { 31 "name" : "cb", 32 "enabled" : true, 33 "config" : { 34 "timeout" : 1000, 35 "max_concurrent_requests": 100, 36 "error_percent_threshold": 50, 37 "request_volume_threshold": 20, 38 "sleep_window": 5000, 39 "predicate": "statusCode == 0 || statusCode >= 500" 40 } 41 } 42 ] 43 }