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

Dump routes to Go radix tree #1992

Merged
merged 19 commits into from
Nov 16, 2022
Merged

Conversation

Anaethelion
Copy link
Contributor

This PR introduces a cli target that outputs the Elasticsearch routes as a Go radix-tree.

Copy link
Contributor

@sethmlarson sethmlarson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks excellent! 🤩 Only had one question:

.catch(reason => console.error(reason))
.finally(() => console.log('Routes extraction complete.', outputPath))

function defaultRoutes (): Trees {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This defaultRoutes routine doesn't need to be kept up-to-date? Is this only used when we don't know the version of the server or for something else?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, that's the one! I've extracted that list from existing targets.

@Anaethelion Anaethelion merged commit 4ca0cc0 into elastic:main Nov 16, 2022
@Anaethelion Anaethelion deleted the proxy/extract/routes branch November 16, 2022 10:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants