opensearch-project / security-analytics-dashboards-plugin

Front end (UI) plugin to support security-analytics
Apache License 2.0
8 stars 41 forks source link

Fixed rule object to yaml conversion for timeframe #1020

Closed amsiglan closed 3 weeks ago

amsiglan commented 2 months ago

Description

Currently the values specified for Selection in the visual editor are parsed to lists by default, as a result the timeframe also gets converted to a list in the yaml payload which is incorrect. This PR adds a check for timeframe and parses it as string as expected.

timeframe:
  - 1d

After this change we get:

timeframe: 1d

Check List

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. For more information on following Developer Certificate of Origin and signing off your commits, please check here.