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

nats-io / nats-server / 8091126815
83%

Build:
DEFAULT BRANCH: main
Ran 29 Feb 2024 05:21AM UTC
Jobs 1
Files 54
Run time 1min
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

28 Feb 2024 10:50PM UTC coverage: 85.264% (-0.009%) from 85.273%
8091126815

push

github

web-flow
[FIXED] update consumer config fails to check OptStartTime properly (#5127)

while working on a pull request for the nats rust client, implementing
the update_consumer method (which updates a consumer with a new config),
i ran into a weird issue.
consumers that had the "by_start_time" delivery_policy could not be
updated - they would throw the error "start time can not be updated"
even though the OptStartTime would be set to the same value.

reading through the server/consumer.go code it seems like even though
OptStartTime is a pointer to a time, the comparison in
checkNewConsumerConfig does not take that into account and just checks
for equality. therefore - if both the old config had their OptStartTime
set and the new config has the same time.Time - they would be different,
as they are different pointers.

this is my attempt at fixing the issue following the logic that the
values should only be compared if both are not nil, and if that is not
true, if any of them are not nil - it means they are also different
values (one being nil and the other is not).

i manually tested this using my rust client test suite and it seems to
work fine for all cases.

Signed-off-by: Tom Keidar

Co-authored-by: Tom Keidar <tom.keidar@gmail.com>

64444 of 75582 relevant lines covered (85.26%)

187860.64 hits per line

Jobs
ID Job ID Ran Files Coverage
1 8091126815.1 29 Feb 2024 05:21AM UTC 0
85.26
GitHub Action Run
Source Files on build 8091126815
Detailed source file information is not available for this build.
  • Back to Repo
  • Github Actions Build #8091126815
  • d9ded28b on github
  • Prev Build on main (#8075385872)
  • Next Build on main (#8106665886)
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