Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(subscriber): correct retain logic #447

Merged
merged 2 commits into from
Aug 1, 2023
Merged

Commits on Jul 5, 2023

  1. fix(subscriber): correct retain logic

    The current logic present in `IdData::drop_closed` marks an item (task,
    resource, and async op stats) to be dropped in the case that the item
    **is** dirty and there **are** watchers: `(dirty && has_watchers)`.
    
    This causes a case where if an item is first received and then completes
    in between the aggregator push cycle, it will be discarded immediately
    and never sent.
    
    This logic has been in place since the concepts of watchers and dirty
    items was introduced in #77. However since an item that is created and
    then dropped within a single update cycle isn't likely to be missed in
    the UI, it may never have been noticed.
    
    Instead the logic should be to **retain** an item if **any** of the
    following is true:
    * there are watchers and the item is dirty: `(dirty && has_watchers)`
    * item has been dropped less time than the retention period:
      `dropped_for <= retention`.
    hds committed Jul 5, 2023
    Configuration menu
    Copy the full SHA
    57daced View commit details
    Browse the repository at this point in the history

Commits on Aug 1, 2023

  1. Configuration menu
    Copy the full SHA
    39ad05f View commit details
    Browse the repository at this point in the history