Skip to content

Why does maxTimeout have no effect on getStats().average? #81

@TimDaub

Description

@TimDaub
  • According to the docs: https://github.com/diamondio/better-queue#queue-statistics, getStats().average is the time in milliseconds a task spends executing in the queue
  • So if maxTimeout is set to Infinity then, we'd expect getStats().average to be anywhere between 0 and Infinity
  • However, shouldn't we expect getStats().average to be maximally 5000 if maxTimeout: 5000?

Locally, I've set maxTimeout: 5000 but my average is still climbing. I'm receiving task_timeout in task_failed listener, but I'm wondering why average is higher.
Another contributor opened an issue saying that maxTimeout may not work #75. Is there something to it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions