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

[BUG] MD: datasource id is required if there is no open-search hosts config #5880

Closed
Tracked by #5752
xinruiba opened this issue Feb 15, 2024 · 2 comments
Closed
Tracked by #5752
Assignees
Labels
bug Something isn't working multiple datasource multiple datasource project v2.13.0

Comments

@xinruiba
Copy link
Member

Describe the bug

When datasource id is empty the search returns 500 error which is unexpected since this is more of input error.

To Reproduce
Steps to reproduce the behavior:

  1. Turn On "data_source.enabled" config
  2. Run OSD
  3. Send following request:
    curl 'localhost:5601/internal/search/opensearch' --data '{"params": {"index":"movies*","body":{},"preference":1697624613679}}' -H 'x-amzn-aosd-app-id:random' -H 'osd-xsrf:osd-fetch' -H 'Content-Type:application/json'
  4. See returned error code is 500

Expected behavior
When datasourceid is empty or datasouce context is empty and there is no opernsearch hosts specified, then the request is invalid and should return 400 error code

OpenSearch Version
2.12

Dashboards Version
Please list the version of OpenSearch Dashboards being used.

Plugins

DataSource

Screenshots
N/A

Host/Environment (please complete the following information):

  • OS: [e.g. iOS]
  • Browser and version [e.g. 22]

Additional context
N/A

@xinruiba xinruiba added bug Something isn't working untriaged labels Feb 15, 2024
@xinruiba
Copy link
Member Author

Happy to work on it

@xinruiba
Copy link
Member Author

fixed in #5882 . Closing this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working multiple datasource multiple datasource project v2.13.0
Projects
None yet
Development

No branches or pull requests

2 participants