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

Fix bug with plugin security policy for GeoJSON output #63

Open
wants to merge 9 commits into
base: master
Choose a base branch
from

Conversation

fulups
Copy link
Contributor

@fulups fulups commented Dec 11, 2020

  • fix bug with plugin security policy for GeoJSON output
  • update tests to correctly support variable docNumber

add support for new json object list output format
# Conflicts:
#	README.md
#	src/main/java/org/codelibs/elasticsearch/df/content/ContentType.java
#	src/main/java/org/codelibs/elasticsearch/df/rest/RestDataAction.java
#	src/test/java/org/codelibs/elasticsearch/df/DataFormatPluginTest.java
# Conflicts:
#	src/main/java/org/codelibs/elasticsearch/df/content/geojson/GeoJsonContent.java
#	src/test/java/org/codelibs/elasticsearch/df/DataFormatPluginTest.java
@@ -366,15 +377,6 @@ public void dumpJson() throws IOException {
assertTrue(lines[1].startsWith("{\"aaa\":\"test 1\","));
}

// Download 10 docs as JSON
Copy link
Contributor

Choose a reason for hiding this comment

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

Why did you remove this code?

@@ -193,7 +196,9 @@ public void dumpCsvWithQuery() throws IOException {
// Download All as CSV with Query and from
try (CurlResponse curlResponse = EcrCurl.get(node, "/dataset0/_data")
.header("Content-Type", "application/json")
.param("format", "csv").body(queryWithFrom).execute()) {
.param("format", "csv")
.param("size", Integer.toString(docNumber))
Copy link
Contributor

Choose a reason for hiding this comment

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

size is in queryWithFrom.

@@ -204,6 +209,7 @@ public void dumpCsvWithQuery() throws IOException {
.header("Content-Type", "application/json")
.param("format", "csv").param("source", queryWithFrom)
.param("source_content_type", "application/json")
.param("size", String.valueOf(docNumber))
Copy link
Contributor

Choose a reason for hiding this comment

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

size is in queryWithFrom.

@@ -168,14 +170,15 @@ public void dumpCsvWithQuery() throws IOException {
assertLineContains(lines[0], "\"aaa\"", "\"bbb\"", "\"ccc\"", "\"eee.fff\"", "\"eee.ggg\"");
assertLineContains(lines[1], "\"1\"");
}

Copy link
Contributor

Choose a reason for hiding this comment

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

please remove spaces.

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.

2 participants