What is the bug?
Detectors search returns 'no such index' when there are no indexes created. Status code returned is 404.
How can one reproduce the bug?
Steps to reproduce the behavior:
Deploy OpenSearch, start, and open the application in a browser.
The first page that loads is the overview page
There is a backend API call to http://localhost:5601/_plugins/_security_analytics/detectors/_search
The result of the request is
Original server response: statusCode: 404, response: '{"error":{"root_cause":[{"type":"index_not_found_exception","reason":"no such index [.opensearch-sap-detectors-config]","index":".opensearch-sap-detectors-config","resource.id":".opensearch-sap-detectors-config","resource.type":"index_or_alias","index_uuid":"_na_"}],"type":"index_not_found_exception","reason":"no such index [.opensearch-sap-detectors-config]","index":".opensearch-sap-detectors-config","resource.id":".opensearch-sap-detectors-config","resource.type":"index_or_alias","index_uuid":"_na_"},"status":404}',
What is the expected behavior?
This should not be an error but a response with status 200 with an empty array response.
Do you have any screenshots?

What is the bug?
Detectors search returns 'no such index' when there are no indexes created. Status code returned is 404.
How can one reproduce the bug?
Steps to reproduce the behavior:
Deploy OpenSearch, start, and open the application in a browser.
The first page that loads is the overview page
There is a backend API call to http://localhost:5601/_plugins/_security_analytics/detectors/_search
The result of the request is
Original server response: statusCode: 404, response: '{"error":{"root_cause":[{"type":"index_not_found_exception","reason":"no such index [.opensearch-sap-detectors-config]","index":".opensearch-sap-detectors-config","resource.id":".opensearch-sap-detectors-config","resource.type":"index_or_alias","index_uuid":"_na_"}],"type":"index_not_found_exception","reason":"no such index [.opensearch-sap-detectors-config]","index":".opensearch-sap-detectors-config","resource.id":".opensearch-sap-detectors-config","resource.type":"index_or_alias","index_uuid":"_na_"},"status":404}',What is the expected behavior?
This should not be an error but a response with status 200 with an empty array response.
Do you have any screenshots?
