question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

5.2 clearScroll spec fails

See original GitHub issue

clearScroll function doesn’t work as expected when using it with elastic version 5.2, when passing the scroll id it blows up and sends an error saying unknown parameter in the request body, when we use an older commit of the 5.2 api featuring just “paramAsBody:‘scrollId’” everything works as expected.

Im not sure why its not working correctly, but I can get it to function properly by reverting the api.clearScroll to an older commit.

5.2 6/21/17 commit

api.clearScroll = ca({ urls: [ { fmt: '/_search/scroll/<%=scrollId%>', req: { scrollId: { type: 'list' } } }, { fmt: '/_search/scroll' } ], paramAsBody: 'scrollId', method: 'DELETE' });

paramAsBody: ‘scrollId’

5.2 7/31/17 commit

api.clearScroll = ca({ urls: [ { fmt: '/_search/scroll/<%=scrollId%>', req: { scrollId: { type: 'list' } } }, { fmt: '/_search/scroll' } ], paramAsBody: { param: 'scrollId', body: 'scroll_id' }, method: 'DELETE' });

paramAsBody: { param: ‘scrollId’, body: ‘scroll_id’ }

Error Received

{ error: { reason: Unknown parameter [scroll_id] in request body or parameter is of the wrong type[VALUE_STRING] , root_cause: [ { reason: Unknown parameter [scroll_id] in request body or parameter is of the wrong type[VALUE_STRING] , type: illegal_argument_exception } ], type: illegal_argument_exception }, status: 400 }

Even when testing it in Kibana with the test code taken straight from the docs it still fails to work.

screen shot 2018-03-27 at 10 32 37 am screen shot 2018-03-27 at 10 31 55 am screen shot 2018-03-27 at 10 31 37 am

elasticsearch-js works as expected from 5.3^

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
Mattrachwalcommented, Mar 29, 2018

Hey, thanks for the quick response. I used the new fix and it worked perfectly! Thanks again! @spalger

0reactions
spalgercommented, Mar 29, 2018

Just published the changes in v14.2.2

Read more comments on GitHub >

github_iconTop Results From Across the Web

Troubleshooting monitoring | Elasticsearch Guide [8.5] | Elastic
If you are collecting monitoring data by using Metricbeat the indices have -mb in their names. If the indices do not exist, review...
Read more >
API Documentation — Elasticsearch 7.16.0 documentation
lenient – Specify whether format-based query failures (such as providing text to a numeric field) should be ignored; min_score – Include only documents...
Read more >
Failed to clear scroll - how to solve related issues - Opster
How to troubleshoot Elasticsearch/OpenSearch log "Failed to clear scroll" a detailed guide ... given the cluster size, number of nodes, hardware specs etc....
Read more >
Spring Data Elasticsearch - Reference Documentation
Uses Spring 5.2. ... 5.2.12. 2.3.x. Moore. 3.2.x. 6.8.12. 5.2.12. 2.2.x. Lovelace ... This is not an error in Spring Data Elasticsearch.
Read more >
Chapter 5 Notes 13th Ed - Section 5.2 - 5 Binomial Probability ...
5.2 Binomial Probability Distributions ... Press 2nd, then DISTR (the button to the left of CLEAR) Scroll down to 0 or A:binompdf (...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found