Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • BIND BIND
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 598
    • Issues 598
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 95
    • Merge requests 95
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • ISC Open Source ProjectsISC Open Source Projects
  • BINDBIND
  • Merge requests
  • !4145

add asynchrony support to BIND 9 query plugins

  • Review changes

  • Download
  • Email patches
  • Plain diff
Closed Jinmei Tatuya requested to merge jtatuya/bind9:2141-asynchrony-support-for-bind-9-query-plugins into main Sep 18, 2020
  • Overview 23
  • Commits 17
  • Pipelines 3
  • Changes 11

Closes #2141 (closed)

See comments added to hooks.h and query.h for a high level (and somewhat more detailed) description of the changes. Newly added unit tests to query_test.c will also help understand how it works.

Some other notes:

  • I've confirmed make check passed.
  • The first few commits (cc973537..c502bc53) are relatively trivial refactoring, on top of which the main changes are made. 1f11cf4b just extracts the recursion quota check without any change. Commit f1f2ae73 should also preserve the behavior (but the main change depends on it).
  • As noted in hooks.h, this implementation may not work well if multiple plugins are used at the same time. I have an idea to mititage this issue, but also as noted I suspect it would be already fragile to use multiple indendent plugins even without this MR's change anyway. So I chose not to make it unnecessarily more complicated. But if this can be a blocking issue I'll incrementally update the branch to address this point.
  • In the added unit tests, I used BIND 9's assertion macro (INSIST) instead of cmocka's macros like assert_int_equal, since the latter often caused hangup on failure (I suspect it's due to referece leak but didn't fully figure it out). Now that all tests pass anyway, I don't mind changing it to cmokca's macros if this can be a blocking issue. This implementation shares ns_client_t.fetchhandle with normal DNS recursion, assuming !4124 (merged) will be eventually merged, at which point it should be safe since these two types of recursion shouldn't run at the same time.
Edited Sep 18, 2020 by Jinmei Tatuya
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: 2141-asynchrony-support-for-bind-9-query-plugins