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 caching issues which render remote ref caching ineffective #466

Merged
merged 2 commits into from
Jul 27, 2024

Commits on Jul 27, 2024

  1. Fix flake8 config to load properly in precommit

    Also set B019 as ignored.
    sirosen committed Jul 27, 2024
    Configuration menu
    Copy the full SHA
    74b003b View commit details
    Browse the repository at this point in the history
  2. Fix rebuild of validator per instance & cache bug

    The schema loader is asked to retrieve a validator per instance, in
    order to support the interface of metaschema evaluation. However, this
    results in a complete rebuild of the validator even when there is one
    schema being used for many instances (as in the `--schemafile` usage
    mode).
    
    Introducing an LRU cache on the validator builder results in the same
    validator being reused (and is sensitive to changes in
    settings/parameters).
    
    Additionally fix a bug in the remote ref download caching in which the
    key used for lookup was incorrect, rendering the cache completely
    ineffective.
    
    A new regression test confirms that the caching is fully effective by
    only observing the number of requests made by the program over "N"
    instancefiles, where N>=1.
    sirosen committed Jul 27, 2024
    Configuration menu
    Copy the full SHA
    f9645ee View commit details
    Browse the repository at this point in the history