[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
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

Add prefetch support for subnet cache entries #664

Merged
merged 1 commit into from
Jul 11, 2023

Conversation

tilan7663
Copy link
Contributor

Currently, only the entries in the global cache are being prefetched when prefetch is enable. However for queries with ECS option set, the results are being stored in subnet cache instead global cache which bypass the existing prefetch logic.

I think @gthess attempted to solve similar issue previously, but unfortunately the patch doesn't seem to work when we tested it. This PR follows a similar approach, but instead building the prefetch logic on top of the global cache, the prefetch is only applied to subnet cache queries.

Happy to chat more if people think there are better alternatives to implement this feature. Thanks.

Signed-off-by: Tian Lan tian.lan@twosigma.com

@gthess gthess self-assigned this Apr 29, 2022
@gthess
Copy link
Member
gthess commented Apr 29, 2022

Hi, the branch you are referring to is an attempt to fix an issue where prefetch queries (from the global cache) will not follow any ECS logic. Prefetch logic was never part of the subnet cache but I see this PR tries to change that!
I'll try to merge my previous branch and then happy to have a look here.

@tilan7663
Copy link
Contributor Author

Thanks @gthess , I will look into the test failures, the tests did pass locally for me before I opened the PR.

@gthess
Copy link
Member
gthess commented Apr 29, 2022

It's because the tests are now ran with make test (because of the rename; .crpls run conditionally based on compiled options as part of the 03-testbound tests). That works fine for you where you compile with subnet but not for the default case.

@tilan7663
Copy link
Contributor Author

oh I see, so I should rename the tests names back to *.crpl.

- Entries in the subnet cache should now be prefetched.

- Rename testdata subnet_*.crpl to subnet_*.rpl so they are visible to
  make test

Signed-off-by: Tian Lan <tian.lan@twosigma.com>
@tilan7663 tilan7663 force-pushed the subnet_cache_prefetch branch from 9d1bcdc to 8afbc09 Compare April 29, 2022 15:46
@gthess gthess added this to the 1.17.1 milestone Nov 29, 2022
@gthess gthess modified the milestones: 1.17.1, 1.18.0 Jan 3, 2023
gthess added a commit that referenced this pull request Jul 7, 2023
@gthess gthess mentioned this pull request Jul 7, 2023
gthess added a commit that referenced this pull request Jul 11, 2023
  entries.
- For #664: Easier code flow for subnetcache prefetching.
- For #664: Add testcase.
- For #664: Rename subnet_prefetch tests to subnet_global_prefetch to
  differentiate from the new subnet prefetch support.
@gthess gthess merged commit 91c298c into NLnetLabs:master Jul 11, 2023
jedisct1 added a commit to jedisct1/unbound that referenced this pull request Jul 15, 2023
* nlnet/master: (43 commits)
  - More clear description of the different auth-zone behaviors on the   man page.
  - Merge NLnetLabs#880 from chipitsine: services/authzone.c: remove redundant   check.
  - Merge NLnetLabs#664 from tilan7763: Add prefetch support for subnet cache   entries. - For NLnetLabs#664: Easier code flow for subnetcache prefetching. - For NLnetLabs#664: Add testcase. - For NLnetLabs#664: Rename subnet_prefetch tests to subnet_global_prefetch to   differentiate from the new subnet prefetch support.
  - For NLnetLabs#664: easier code flow for subnetcache prefetching. - For NLnetLabs#664: add testcase.
  - Skip the 00-lint test. splint is not maintained; it either does not   work or produces false positives. Static analysis is handled in the   clang test.
  - For NLnetLabs#802: Cleanup comments and add RCODE check for CD bit test case.
  - Fix dereference of NULL variable warning in mesh_do_callback.
  - Code cleanup for sldns_str2wire_svcparam_key_lookup.
  - Fix NLnetLabs#906: warning: ‘Py_SetProgramName’ is deprecated.
  - For NLnetLabs#739: minor cleanup for testcases.
  - More fixes for reference counting for python module and clean up   failure code.
  - Fix python modules with multiple scripts, by incrementing reference   counts.
  - Remove warning about unknown cast-function-type warning pragma.
  Add changelog and contrib/README mention for NLnetLabs#903 - Merge NLnetLabs#903: contrib: add yocto compatible init script.
  contrib: add yocto compatible init script
  Changelog for NLnetLabs#887 and NLnetLabs#516
  - Properly handle all return values of worker_check_request during   early EDE code. - Do not check the incoming request more than once.
  - Fix for uncertain unit test for doh buffer size events.
  Changelog note for NLnetLabs#895 - Fix NLnetLabs#895: python + sysconfig gives ANOTHER path comparing to   distutils.
  - Merge NLnetLabs#896: Fix: NLnetLabs#895: pythonmodule: add all site-packages   directories to sys.path.
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants