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

[WIP] FEAT(#3038): iplocation command #3085

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

kenrickyap
Copy link

@kenrickyap kenrickyap commented Oct 18, 2024

Description

[Describe what this change achieves]

Related Issues

Resolves #3038

Check List

  • New functionality includes testing.
  • New functionality has been documented.
  • New functionality has javadoc added.
  • New functionality has a user manual doc added.
  • API changes companion pull request created.
  • Commits are signed per the DCO using --signoff.
  • Public documentation issue/PR created.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@@ -46,6 +46,8 @@ pitest {
}

dependencies {
implementation "org.opensearch:opensearch-geospatial-spi:${opensearch_build}"
Copy link

Choose a reason for hiding this comment

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

I don't see why core needs to depend on geospatial.

@kenrickyap kenrickyap changed the title [WIP] FEAT(AOS-2230): iplocation command [WIP] FEAT(3038): iplocation command Oct 21, 2024
public GeoipExpression(Expression datasource, Expression ipAddress, String properties) {
this.datasource = datasource;
this.ipAddress = ipAddress;
this.properties = properties.split(",");
Copy link

Choose a reason for hiding this comment

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

You probably want the parser to do this for you rather than splitting manually during logical planning.

@kenrickyap kenrickyap changed the title [WIP] FEAT(3038): iplocation command [WIP] FEAT(#3038): iplocation command Oct 25, 2024
import org.opensearch.sql.ast.expression.When;
import org.opensearch.sql.ast.expression.WindowFunction;
import org.opensearch.sql.ast.expression.Xor;
import org.opensearch.sql.ast.expression.*;
Copy link
Contributor

Choose a reason for hiding this comment

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

Avoid using * imports.

import org.opensearch.sql.ast.expression.When;
import org.opensearch.sql.ast.expression.WindowFunction;
import org.opensearch.sql.ast.expression.Xor;
import org.opensearch.sql.ast.expression.*;
Copy link
Contributor

Choose a reason for hiding this comment

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

Avoid using * imports. May need to change your IDE configuration.

import org.opensearch.sql.ast.expression.When;
import org.opensearch.sql.ast.expression.WindowFunction;
import org.opensearch.sql.ast.expression.Xor;
import org.opensearch.sql.ast.expression.*;
Copy link
Contributor

Choose a reason for hiding this comment

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

Avoid using * imports.

import java.util.stream.Collectors;

/**
* Expression node of scalar function. Params include function name (@funcName) and function
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't understand this Javadoc comment.

Copy link
Contributor

@normanj-bitquill normanj-bitquill left a comment

Choose a reason for hiding this comment

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

Some formatting comments.

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

Successfully merging this pull request may close these issues.

[FEATURE]Add geoip function to PPL for IP address geolocation
4 participants