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

nats-io / nats-streaming-server / 892
95%
main: 92%

Build:
Build:
LAST BUILD BRANCH: add-eol-note
DEFAULT BRANCH: main
Ran 25 Aug 2017 07:52PM UTC
Jobs 1
Files 15
Run time 2s
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
892

push

travis-ci

kozlovic
Fixed SubStore handling of subscriptions count

The `genericSubStore` was keep track of the subscriptions count
using a simple integer. The problem is that on DeleteSub(), the
count would be decreased, regardless if this subscription either
existed or had been already deleted or never existed.
This was not really a problem since the server should not delete
the same subscription twice.
However, it is safer to make the DeleteSub() store operation
idempotent. To that effect, the count is replaced with a map
in the genericSubStore. The test for max number of subscriptions
now relies on the length of the map. If a subscription is deleted
twice, it will be removed from the map only once and again, the
count is based on size of map, not a separate counter.
Since FileSubStore used a map due to the need during compaction
of the subscriptions file, the field has been removed and instead
the FileSubStore is now using the map from the genericSubStore.
That map uses interface{} for the values. The FileSubStore therefore
type cast the value to (*subscription).

6944 of 7335 relevant lines covered (94.67%)

53957.45 hits per line

Jobs
ID Job ID Ran Files Coverage
1 892.1 25 Aug 2017 07:52PM UTC 0
94.67
Travis Job 892.1
Source Files on build 892
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #892
  • ae5f69d5 on github
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