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

kyuupichan / aiorpcX / 168 / 1
99%
master: 99%

Build:
DEFAULT BRANCH: master
Ran 10 Apr 2019 10:30AM UTC
Files 7
Run time 0s
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

10 Apr 2019 10:27AM UTC coverage: 99.493% (-0.4%) from 99.852%
168.1

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

1373 of 1380 relevant lines covered (99.49%)

0.99 hits per line

Source Files on job 168.1
  • Tree
  • List 0
  • Changed 2
  • Source Changed 2
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 95
  • Travis Job 168.1
  • 962a8269 on github
  • Prev Job for on master (#167.2)
  • Next Job for on master (#169.4)
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