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 iter function for fetching hostmaps #1275

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

maggie44
Copy link

Changes:

  1. Use copy instead of loops to create certificate copies. Not sure why it was a loop before.
  2. Two new functions:
ListHostmapHostsIter
ListHostmapIndexesIter

Provides the same functionality as listHostMapHosts and listHostMapIndexes but provides an iter (https://pkg.go.dev/iter) that can be looped over instead of making the entire ControlHostInfo slice before returning. It provides a more efficient means of accessing the hostmap.

Requires Golang 1.23 to use the iter functionality, therefore marked as a draft until Nebula is bumped to the latest version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant