OpenSearch-Dashboards icon indicating copy to clipboard operation
OpenSearch-Dashboards copied to clipboard

[BUG] JSON.parse: expected ',' or '}' with long numeral comma-separated keyword string

Open nikAizuddin opened this issue 1 year ago • 2 comments

Describe the bug

Got JSON.parse: expected ',' or '}' after property value in object at line 1 column 175 of the JSON data when passing "10080214256450617947,2031884987996059597,1" To Reproduce Steps to reproduce the behavior:

  1. Go to Dev Tools
  2. Execute:
POST myindex/_doc
{
  "@timestamp" : "2024-03-04T09:40:08.2531122Z",
  "JustAKeyword" : "10080214256450617947,2031884987996059597,1"
}
  1. You'll see the JSON.parse error.

Expected behavior There should be no error.

OpenSearch Version Main branch commit https://github.com/opensearch-project/OpenSearch/tree/87ac37460c16a5b3cfa1cd85cad2cb7468b430a3

Dashboards Version Main branch commit https://github.com/opensearch-project/OpenSearch-Dashboards/tree/9901bea341904421eb802a004476cdd313811b1e

Plugins OpenSearch plugins:

opensearch-alerting
opensearch-asynchronous-search
opensearch-cross-cluster-replication
opensearch-custom-codecs
opensearch-flow-framework
opensearch-geospatial
opensearch-index-management
opensearch-job-scheduler
opensearch-knn
opensearch-ml
opensearch-neural-search
opensearch-notifications
opensearch-notifications-core
opensearch-observability
opensearch-performance-analyzer
opensearch-reports-scheduler
opensearch-security
opensearch-security-analytics
opensearch-skills
opensearch-sql
opensearch-time-series-analytics

Dashboard plugins:

[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]

Screenshots

image

Host/Environment (please complete the following information):

  • OS: Fedora 38
  • Browser and version:
    • Firefox 123.0 (64-bit)
    • Google Chrome 122.0.6261.94 (Official Build) (64-bit)
  • Node: v18.19.0
  • Java: Java(TM) SE Runtime Environment Oracle GraalVM 21.0.2+13.1 (build 21.0.2+13-LTS-jvmci-23.1-b30)

Additional context

All OpenSearch and Dashboard plugins are build from source

nikAizuddin avatar Mar 04 '24 15:03 nikAizuddin

Have the same/similar issue but when searching data, extremely intermittent and cannot reproduce reliably.

  1. Searching index - Sysmon in this example - produce data as expected, refresh a few times works no issues.
  2. Search a minute later, error occurs.
  3. Give it a minute or two, search the same data frame and same data set, works again.
  4. The time frame or data is irrelevant as I tested with dev tools, checked for valid json, various time frames.
  5. Sounds wishy-washy I know.

image

When the discover query is executed in dev tools: image

Tested getting data from the same index without the query parameters from discover and it produces data fine.

OpenSearch Version v2.12.0 tar.gz

Dashboards Version v2.12.0 tar.gz

Plugins OpenSearch plugins:

opensearch-alerting opensearch-anomaly-detection opensearch-asynchronous-search opensearch-cross-cluster-replication opensearch-custom-codecs opensearch-flow-framework opensearch-geospatial opensearch-index-management opensearch-job-scheduler opensearch-knn opensearch-ml opensearch-neural-search opensearch-notifications opensearch-notifications-core opensearch-observability opensearch-performance-analyzer opensearch-reports-scheduler opensearch-security opensearch-security-analytics opensearch-skills opensearch-sql

Dashboard plugins: [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected]

Host/Environment OS: Ubuntu 22.04 Browser: Chrome version 122.0.6261.94 (Official Build) (64-bit)

MarkusAdvantage avatar Mar 04 '24 20:03 MarkusAdvantage

@AMoo-Miki could you comment on this? is this fixed?

ananzh avatar Mar 05 '24 18:03 ananzh

We have same issue after upgrade, searches worked fine before upgrade in discover but not afterwards upgrade to 2.12.0 and same search works fine in dev tools or direct API search.

brian-grabau avatar Mar 19 '24 12:03 brian-grabau

This was fixed with https://github.com/opensearch-project/OpenSearch-Dashboards/pull/5956 which will be included in the 2.13.0 release.

AMoo-Miki avatar Mar 20 '24 19:03 AMoo-Miki

This was fixed with https://github.com/opensearch-project/OpenSearch-Dashboards/pull/5956 which will be included in the 2.13.0 release.

But I was using commit https://github.com/opensearch-project/OpenSearch-Dashboards/tree/9901bea341904421eb802a004476cdd313811b1e which already include the fix.

nikAizuddin avatar Mar 20 '24 22:03 nikAizuddin

I have a version with more generalized rules but am having trouble testing them all.

@nikAizuddin using your sample query from the first post, I found a combination that allowed me to reproduce the issue.

@MarkusAdvantage intermittent problems indicate that your problem is something different; maybe you have a mix of version in your cluster?

AMoo-Miki avatar Mar 22 '24 18:03 AMoo-Miki

@AMoo-Miki No, was the version indicated in my entry. I had to painfully downgrade to 2.11 and delete indices to get it working. In any case, will see if it is fixed with the new version, thank you.

MarkusAdvantage avatar Mar 26 '24 20:03 MarkusAdvantage

Have the same/similar issue but when searching data, extremely intermittent and cannot reproduce reliably.

  1. Searching index - Sysmon in this example - produce data as expected, refresh a few times works no issues.
  2. Search a minute later, error occurs.
  3. Give it a minute or two, search the same data frame and same data set, works again.
  4. The time frame or data is irrelevant as I tested with dev tools, checked for valid json, various time frames.
  5. Sounds wishy-washy I know.

image

When the discover query is executed in dev tools: image

Tested getting data from the same index without the query parameters from discover and it produces data fine.

OpenSearch Version v2.12.0 tar.gz

Dashboards Version v2.12.0 tar.gz

Plugins OpenSearch plugins:

opensearch-alerting opensearch-anomaly-detection opensearch-asynchronous-search opensearch-cross-cluster-replication opensearch-custom-codecs opensearch-flow-framework opensearch-geospatial opensearch-index-management opensearch-job-scheduler opensearch-knn opensearch-ml opensearch-neural-search opensearch-notifications opensearch-notifications-core opensearch-observability opensearch-performance-analyzer opensearch-reports-scheduler opensearch-security opensearch-security-analytics opensearch-skills opensearch-sql

Dashboard plugins: [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected] [email protected]

Host/Environment OS: Ubuntu 22.04 Browser: Chrome version 122.0.6261.94 (Official Build) (64-bit)

was the issue solved after upgrade to 2.13.0? We have the same issue after upgrade to 2.12.0

amirkkn avatar Apr 08 '24 19:04 amirkkn

@amirkkn yes this was fixed in the 2.13 release

ashwin-pc avatar Apr 09 '24 02:04 ashwin-pc