brndnmtthws / marathon-lb-autoscale Goto Github PK
View Code? Open in Web Editor NEWAutoscale your apps on Marathon
License: Apache License 2.0
Autoscale your apps on Marathon
License: Apache License 2.0
opts.on("--target-rps Integer", Integer, "Target number of requests per second per " +
should be
opts.on("--target_rps Integer", Integer, "Target number of requests per second per " +
current it does not support marathon http auth
Was scratching my head trying to figure out whats up with this not auto scaling. So I had outputted the stats from the sample function for ALL apps on marathon-lb and noticed that my app I was trying to monitor, the stats are all at 0, but marathon_http_in contains accurate readings. I used blitz.io to stress test the app and it worked, however without the proper stats this method won't work.
Here's the output from a sample query to marathon-lb. Converted to JSON.
{"stats":{"pxname":"stats", "svname":"FRONTEND", "qcur":"", "qmax":"", "scur":"1", "smax":"2", "slim":"10000", "stot":"5810", "bin":"773865", "bout":"2098977", "dreq":"0", "dresp":"0", "ereq":"1", "econ":"", "eresp":"", "wretr":"", "wredis":"", "status":"OPEN", "weight":"", "act":"", "bck":"", "chkfail":"", "chkdown":"", "lastchg":"", "downtime":"", "qlimit":"", "pid":"1", "iid":"2", "sid":"0", "throttle":"", "lbtot":"", "tracked":"", "type":"0", "rate":"1", "rate_lim":"0", "rate_max":"2", "check_status":"", "check_code":"", "check_duration":"", "hrsp_1xx":"0", "hrsp_2xx":"5808", "hrsp_3xx":"0", "hrsp_4xx":"1", "hrsp_5xx":"0", "hrsp_other":"0", "hanafail":"", "req_rate":"1", "req_rate_max":"2", "req_tot":"5810", "cli_abrt":"", "srv_abrt":"", "comp_in":"0", "comp_out":"0", "comp_byp":"0", "comp_rsp":"0", "lastsess":"", "last_chk":"", "last_agt":"", "qtime":"", "ctime":"", "rtime":"", "ttime":""}, "marathon_http_in":{"pxname":"marathon_http_in", "svname":"FRONTEND", "qcur":"", "qmax":"", "scur":"10", "smax":"219", "slim":"10000", "stot":"12048", "bin":"24596669", "bout":"990074899", "dreq":"0", "dresp":"0", "ereq":"5269", "econ":"", "eresp":"", "wretr":"", "wredis":"", "status":"OPEN", "weight":"", "act":"", "bck":"", "chkfail":"", "chkdown":"", "lastchg":"", "downtime":"", "qlimit":"", "pid":"1", "iid":"3", "sid":"0", "throttle":"", "lbtot":"", "tracked":"", "type":"0", "rate":"0", "rate_lim":"0", "rate_max":"184", "check_status":"", "check_code":"", "check_duration":"", "hrsp_1xx":"0", "hrsp_2xx":"96898", "hrsp_3xx":"326", "hrsp_4xx":"5345", "hrsp_5xx":"10", "hrsp_other":"0", "hanafail":"", "req_rate":"0", "req_rate_max":"414", "req_tot":"102579", "cli_abrt":"", "srv_abrt":"", "comp_in":"0", "comp_out":"0", "comp_byp":"0", "comp_rsp":"0", "lastsess":"", "last_chk":"", "last_agt":"", "qtime":"", "ctime":"", "rtime":"", "ttime":""}, "marathon_http_appid_in":{"pxname":"marathon_http_appid_in", "svname":"FRONTEND", "qcur":"", "qmax":"", "scur":"0", "smax":"0", "slim":"10000", "stot":"0", "bin":"0", "bout":"0", "dreq":"0", "dresp":"0", "ereq":"0", "econ":"", "eresp":"", "wretr":"", "wredis":"", "status":"OPEN", "weight":"", "act":"", "bck":"", "chkfail":"", "chkdown":"", "lastchg":"", "downtime":"", "qlimit":"", "pid":"1", "iid":"4", "sid":"0", "throttle":"", "lbtot":"", "tracked":"", "type":"0", "rate":"0", "rate_lim":"0", "rate_max":"0", "check_status":"", "check_code":"", "check_duration":"", "hrsp_1xx":"0", "hrsp_2xx":"0", "hrsp_3xx":"0", "hrsp_4xx":"0", "hrsp_5xx":"0", "hrsp_other":"0", "hanafail":"", "req_rate":"0", "req_rate_max":"0", "req_tot":"0", "cli_abrt":"", "srv_abrt":"", "comp_in":"0", "comp_out":"0", "comp_byp":"0", "comp_rsp":"0", "lastsess":"", "last_chk":"", "last_agt":"", "qtime":"", "ctime":"", "rtime":"", "ttime":""}, "marathon_https_in":{"pxname":"marathon_https_in", "svname":"FRONTEND", "qcur":"", "qmax":"", "scur":"0", "smax":"1", "slim":"10000", "stot":"2", "bin":"76", "bout":"424", "dreq":"0", "dresp":"0", "ereq":"0", "econ":"", "eresp":"", "wretr":"", "wredis":"", "status":"OPEN", "weight":"", "act":"", "bck":"", "chkfail":"", "chkdown":"", "lastchg":"", "downtime":"", "qlimit":"", "pid":"1", "iid":"5", "sid":"0", "throttle":"", "lbtot":"", "tracked":"", "type":"0", "rate":"0", "rate_lim":"0", "rate_max":"1", "check_status":"", "check_code":"", "check_duration":"", "hrsp_1xx":"0", "hrsp_2xx":"0", "hrsp_3xx":"0", "hrsp_4xx":"0", "hrsp_5xx":"2", "hrsp_other":"0", "hanafail":"", "req_rate":"0", "req_rate_max":"1", "req_tot":"2", "cli_abrt":"", "srv_abrt":"", "comp_in":"0", "comp_out":"0", "comp_byp":"0", "comp_rsp":"0", "lastsess":"", "last_chk":"", "last_agt":"", "qtime":"", "ctime":"", "rtime":"", "ttime":""}, "gradtest_10102":{"pxname":"gradtest_10102", "svname":"FRONTEND", "qcur":"", "qmax":"", "scur":"0", "smax":"0", "slim":"10000", "stot":"0", "bin":"0", "bout":"0", "dreq":"0", "dresp":"0", "ereq":"0", "econ":"", "eresp":"", "wretr":"", "wredis":"", "status":"OPEN", "weight":"", "act":"", "bck":"", "chkfail":"", "chkdown":"", "lastchg":"", "downtime":"", "qlimit":"", "pid":"1", "iid":"6", "sid":"0", "throttle":"", "lbtot":"", "tracked":"", "type":"0", "rate":"0", "rate_lim":"0", "rate_max":"0", "check_status":"", "check_code":"", "check_duration":"", "hrsp_1xx":"0", "hrsp_2xx":"0", "hrsp_3xx":"0", "hrsp_4xx":"0", "hrsp_5xx":"0", "hrsp_other":"0", "hanafail":"", "req_rate":"0", "req_rate_max":"0", "req_tot":"0", "cli_abrt":"", "srv_abrt":"", "comp_in":"0", "comp_out":"0", "comp_byp":"0", "comp_rsp":"0", "lastsess":"", "last_chk":"", "last_agt":"", "qtime":"", "ctime":"", "rtime":"", "ttime":""}}
is there any particular reason for which it is not possibile to specify a target-rps
lower than 1? while dealing with long running tasks having an integer property is quite limiting.
it would be really interesting add options to allow basic authentication in Marathon (user/pass) and to Haproxy
What do you think about it?
I try to add it by myself in my free time...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.