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

ben-manes / caffeine / 1698
100%

Build:
DEFAULT BRANCH: master
Ran 14 Apr 2016 06:04PM UTC
Jobs 1
Files 64
Run time 3s
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
1698

push

travis-ci

ben-manes
CASSANDRA-11452: Improved resistence to hash collision attacks

When the candidate and victim's hash code are equal they have the same
estimated frequency. This results in the candidate being rejected. If
a hash collision attack then the cache will not admit any new entries
and the hit rate will be very low (causing poor response times).

Ideally we'd use a 64-bit hash, but Java does not provide that natively
and, for now, I'd prefer not exposing a builder function (K -> long). A
longHashCode() would not fix the problem, but greatly reduce its
likelihood.

This patch evicts the victim in the case of a collision. This should
allow candidates to flow through the eden -> probation segments. This
should have a similar effect as using freq1 >= freq2 comparision (not
strictly >) without degrading the hit rate in the LIRS traces.

@blambov please review so that we can iterate and find a good
compromise solution

5069 of 5373 relevant lines covered (94.34%)

0.94 hits per line

Jobs
ID Job ID Ran Files Coverage
1 1698.1 (TERM=dumb) 14 Apr 2016 06:04PM UTC 0
94.34
Travis Job 1698.1
Source Files on build 1698
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #1698
  • 9372ffcb on github
  • Prev Build on master (#1696)
  • Next Build on master (#1699)
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