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

Near: "_ip" support in prepared queries #3798

Closed
kyhavlov opened this issue Jan 12, 2018 · 1 comment
Closed

Near: "_ip" support in prepared queries #3798

kyhavlov opened this issue Jan 12, 2018 · 1 comment
Assignees
Milestone

Comments

@kyhavlov
Copy link
Contributor

Prepared queries should support a special ?near=_ip lookup to sort results by proximity to an IP similar to how ?near=_agent sorts by proximity to the local agent (using coordinates).

@slackpad slackpad added this to the Next milestone Jan 24, 2018
@pearkes pearkes modified the milestones: Next, 1.0.7 Mar 13, 2018
@mkeeler mkeeler self-assigned this Apr 10, 2018
mkeeler added a commit that referenced this issue Apr 11, 2018
Also fixed an issue where we need to have the X-Forwarded-For header processed before the RemoteAddr. This shouldn’t have any functional difference for prod code but for mocked request objects it allows them to work.
mkeeler added a commit that referenced this issue Apr 11, 2018
mkeeler added a commit that referenced this issue Apr 11, 2018
Allow DNS peer IP as the source IP.
Break early when the right node was found for executing the preapred query.
Update docs
mkeeler added a commit that referenced this issue Apr 12, 2018
mkeeler added a commit that referenced this issue Apr 12, 2018
Test HTTP/DNS source IP without header/extra EDNS data.
Add WARN log for when prepared query with near=_ip is executed without specifying the source ip
mkeeler added a commit that referenced this issue Apr 12, 2018
Update docs a little
Update/add tests. Make sure all the various ways of determining the source IP work
Update X-Forwarded-For header parsing. This can be a comma separated list with the first element being the original IP so we now handle csv data there.
Got rid of error return from sourceAddrFromRequest
@pearkes
Copy link
Contributor

pearkes commented Apr 17, 2018

This is done in #4023 and is part of 1.0.7.

@pearkes pearkes closed this as completed Apr 17, 2018
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

No branches or pull requests

4 participants