[GH-ISSUE #3087] resolver(docs): MAX_TTL is not public #1127

Closed
opened 2026-03-16 01:41:13 +03:00 by kerem · 1 comment
Owner

Originally created by @Kriskras99 on GitHub (Jun 25, 2025).
Original GitHub issue: https://github.com/hickory-dns/hickory-dns/issues/3087

Describe the bug
(ResolverOpts.positive_max_ttl)[https://docs.rs/hickory-resolver/0.25.2/hickory_resolver/config/struct.ResolverOpts.html#structfield.positive_max_ttl] and ResolverOpts.negative_max_ttl refer to MAX_TTL as the default value. However this value is pub(crate) and therefore not accessible. The link in the docs does not work and returns a 404.

To Reproduce
Go to https://docs.rs/hickory-resolver/0.25.2/hickory_resolver/config/struct.ResolverOpts.html#structfield.positive_max_ttl and click on MAX_TTL.

Expected behavior
Being able to view MAX_TTL or have it specified as Otherwise, this will default to a unspecified amount of seconds.

Version:
Crate: resolver
Version: 0.25.2

Additional context
I can open a PR for making MAX_TTL public or removing the link and not specifying a default.

Originally created by @Kriskras99 on GitHub (Jun 25, 2025). Original GitHub issue: https://github.com/hickory-dns/hickory-dns/issues/3087 **Describe the bug** (`ResolverOpts.positive_max_ttl`)[https://docs.rs/hickory-resolver/0.25.2/hickory_resolver/config/struct.ResolverOpts.html#structfield.positive_max_ttl] and `ResolverOpts.negative_max_ttl` refer to MAX_TTL as the default value. However this value is `pub(crate)` and therefore not accessible. The link in the docs does not work and returns a 404. **To Reproduce** Go to https://docs.rs/hickory-resolver/0.25.2/hickory_resolver/config/struct.ResolverOpts.html#structfield.positive_max_ttl and click on `MAX_TTL`. **Expected behavior** Being able to view `MAX_TTL` or have it specified as `Otherwise, this will default to a unspecified amount of seconds.` **Version:** Crate: resolver Version: 0.25.2 **Additional context** I can open a PR for making `MAX_TTL` public or removing the link and not specifying a default.
kerem closed this issue 2026-03-16 01:41:18 +03:00
Author
Owner

@djc commented on GitHub (Jun 25, 2025):

Sorry for the oversight, happy to review your PR!

<!-- gh-comment-id:3004472163 --> @djc commented on GitHub (Jun 25, 2025): Sorry for the oversight, happy to review your PR!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hickory-dns#1127
No description provided.