• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

kyuupichan / aiorpcX / 170
99%

Build:
DEFAULT BRANCH: master
Ran 10 Apr 2019 11:29AM UTC
Jobs 3
Files 7
Run time 21s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
170

push

travis-ci

kyuupichan
SessionBase: move to a generalized cost metric

I've long wanted a more generic cost metric for requests than
simply bandwidth.  SomberNight's https://github.com/kyuupichan/electrumx/pull/785
prompted me to implement something reasonably generic and configurable.

Features:

- generalized res_usage metric with time decay
- bandwidth consumption contributes to the resource consumption
- derived classes can add to the resource usage count freely, such as
  on a per-request basis
- derived classes can provide an extra "soft" cost.  This could come
  from IP address bucketing, session grouping, or anything.  This is
  soft because it is not counted as part of the session's recorded
  resource usage, it is only temporarily added for the purpose of
  calculating the throttling rate.
- soft and hard limits.  Once resource usage (including the soft amount)
  hits the soft limit, request concurrency for the session begins to reduce
  and each request sleeps a little.  As resource usage grows to the hard
  limit, the sleeps increase and the concurrency reduces further.  If the
  hard limit is exceeded the session is closed
- most limits and parameters are configurable

1376 of 1377 relevant lines covered (99.93%)

2.99 hits per line

Jobs
ID Job ID Ran Files Coverage
1 170.1 10 Apr 2019 11:29AM UTC 0
99.86
Travis Job 170.1
3 170.3 10 Apr 2019 11:29AM UTC 0
99.78
Travis Job 170.3
4 170.4 10 Apr 2019 11:30AM UTC 0
99.78
Travis Job 170.4
Source Files on build 170
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #170
  • 2884b946 on github
  • Prev Build on master (#169)
  • Next Build on master (#171)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc