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

[FEATURE] Add the ability to configure the report record count limit from the UI. #328

Closed
ganilmca opened this issue Mar 19, 2024 · 4 comments · Fixed by #395
Closed

[FEATURE] Add the ability to configure the report record count limit from the UI. #328

ganilmca opened this issue Mar 19, 2024 · 4 comments · Fixed by #395
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@ganilmca
Copy link

Hi Team,

Not able to download report as saved in opensearch more than 10000 records.

Can any one please help us to download the report even we have millions of records.

Please let us know if anything required from my end.

Thanks,
Anil

@ganilmca ganilmca added bug Something isn't working untriaged labels Mar 19, 2024
@ashwin-pc
Copy link
Member

May not be possible at the moment but someone from the reporting plugin should take a look and see what the limitation here is.
@opensearch-project/admin can you transfer this issue to the dashboard reporting plugin?

@bbarani bbarani transferred this issue from opensearch-project/OpenSearch-Dashboards Mar 19, 2024
@Swiddis Swiddis removed the untriaged label Mar 25, 2024
@Swiddis
Copy link
Collaborator

Swiddis commented Mar 25, 2024

This is possible in the API but not in the UI. The limit is specified by the report_params.core_params.limit field in the request to the Backend, so you can recreate a report with a new limit and delete the old report.

image

Full cURL request with a new limit of 1000000:

> curl 'http://localhost:5601/api/reporting/reportDefinition' -X POST --data-raw '{"report_params":{"report_name":"Test report","report_source":"Saved search","description":"Test desc","core_params":{"base_url":"/gmu/app/discover#/view/571aaf70-4c88-11e8-b3d7-01146121b73d","report_format":"csv","time_duration":"PT30M","saved_search_id":"571aaf70-4c88-11e8-b3d7-01146121b73d","limit":1000000,"excel":true}},"delivery":{"configIds":[],"title":"","textDescription":"","htmlDescription":""},"trigger":{"trigger_type":"On demand"}}'
{"state":"Report definition created","scheduler_response":{"reportDefinitionId":"ayJ5do4B3PbVp9bUHek4"}}

This is a one-time setup that adds a duplicate report to the list of available reports, so this only needs to be done once per report definition.1

It might still be useful to make this limit configurable in the UI, so you don't need to write a curl directly. Marking this as a UI feature request instead of a bug. Thanks for the issue!

Footnotes

  1. For best results, I configured the report as normal in the UI and used my browser's "Copy as cURL" functionality from the network inspector to get a correct request where I could change the limit.

@Swiddis Swiddis added enhancement New feature or request and removed bug Something isn't working labels Mar 25, 2024
@Swiddis Swiddis changed the title [BUG]Not able to download report as saved in opensearch-dashboard more than 10000 records [FEATURE] Add the ability to configure the report record count limit from the UI. Mar 25, 2024
@Swiddis
Copy link
Collaborator

Swiddis commented Mar 25, 2024

More steps/discussion at #60.

@Swiddis
Copy link
Collaborator

Swiddis commented Mar 25, 2024

Going to mark this as a good first issue. The limit is set in the request in report_settings.tsx. The different input fields are specified in the same file, consider adding another input field that updates this limit. It should only be enabled for saved search types, I think?

I don't specifically work on reporting that often (@sumukhswamy is a good point of contact here), but for some inspiration on how to set up a text input with a default value, I can link a setup form I made for another plugin, and the docs for Oui are some of the friendliest docs for a UI framework I've read in a while.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants