GithubHelp home page GithubHelp logo

Comments (12)

cstyan avatar cstyan commented on June 14, 2024 1

Bryan and I discussed on Slack; over text we'd misunderstood each other. His config changes were definitely valid given the low scrape load he had. Remote write has some gaps when it comes to handling timely sending of data in that kind of a scenario, the hard coding of the reshard check ticker is just one of those gaps.

I'll be opening a few issues soon for some things we can try out, there are a number of people interested in taking on some smaller tasks in RW and those could be good first issues for them.

from prometheus.

bboreham avatar bboreham commented on June 14, 2024

I notice in a similar previous issue @csmarchbanks said #7124 (comment)

At very low remote write volumes it is very easy to go through multiple batch send durations without new samples coming in

Which matches the situation in this case (volume was about 500 series, scraped every 5s).
Anyway this judgement seems highly dependent on the value of BatchSendDeadline; is it unreasonable to set it to 100ms?

low volumes are unlikely to ever reshard above the minimum anyway

More context: the machine was occasionally under heavy CPU load; I believe this generated a backlog on the send queue.
(Sadly I don't have metrics to confirm this)

from prometheus.

kushalShukla-web avatar kushalShukla-web commented on June 14, 2024

is this good @bboreham or do we need to wait for others review .

from prometheus.

bboreham avatar bboreham commented on June 14, 2024

Best to comment on the PR within the PR itself.

from prometheus.

kushalShukla-web avatar kushalShukla-web commented on June 14, 2024

okay @bboreham .

from prometheus.

cstyan avatar cstyan commented on June 14, 2024

Which matches the situation in this case (volume was about 500 series, scraped every 5s).
Anyway this judgement seems highly dependent on the value of BatchSendDeadline; is it unreasonable to set it to 100ms?

I would have suggested/assumed people would drop the batch size max_samples_per_send a lot lower before dropping the BatchSendDeadline that low.

from prometheus.

bboreham avatar bboreham commented on June 14, 2024

I don't think that helps. In my example, Prometheus scraped 509 series every 5 seconds; I wanted it to send those 509 series without waiting 5 seconds.
If I reduce max_samples_per_send from 2000 default to 100, say, it will send 500 of them, but I still want it to send all 509 series.

from prometheus.

cstyan avatar cstyan commented on June 14, 2024

Personally I would still lower the batch size before the send deadline timeout, but even so I think guarding against excessive resharding checks is a valid change. Reviewing the PR again today.

from prometheus.

bboreham avatar bboreham commented on June 14, 2024

I don't think I am understanding your point. What would you lower max_samples_per_send to, given my example?

from prometheus.

cstyan avatar cstyan commented on June 14, 2024

I don't think I am understanding your point. What would you lower max_samples_per_send to, given my example?

Something below 509? Or even just 1000 or so and lower the send deadline to ~1s. I don't know exactly what your use case is but scraping a small amount of samples and then always sending all of them via remote write ASAP isn't really a situation we've designed for. Setting the send deadline to 100ms is just a workaround that's worked in your case.

This is separate from the issue of the the resharding check happening too often when the send deadline is < 5s, which I don't have any issue with merging a fix for.

from prometheus.

bboreham avatar bboreham commented on June 14, 2024

lower the send deadline to ~1s

OK, that case still shows the issue I am talking about, because two times 1 second is way less than the 10s interval it checks at.

always sending all of them via remote write ASAP

That isn't what I asked for; I asked for:

in a timely manner

and

without waiting 5 seconds

Setting the send deadline to 100ms is just a workaround that's worked in your case.

I disagree, it matches what I wanted.

Bryan

from prometheus.

kushalShukla-web avatar kushalShukla-web commented on June 14, 2024

yeah after seeing and understanding code @bboreham assumption here is valid as we dont need to wait for 5 seconds , and yeah as @bboreham also asked for feeding data timely manner . and also we need to remove that hard coding of the resharding check ticker .

from prometheus.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.