Revert the Datadog fields DSL refactor

What does this MR do and why?

This MR reverts the Datadog integration changes introduced in !90921 (merged)

The changes lead to a bug where the archive_trace_events flag was not stored in the database column, but in the properties field. This way, archive trace hooks could not be executed.

The problem might be that fields automatically create a prop_accessor even thought it looks like we check if an accessor already exists when creating a boolean field. This can be addressed in a follow-up.

How to set up and validate locally

  1. Switch to the master branch
  2. In rails console, activate the datadog_integration_logs_collection feature. Feature.enable(:datadog_integration_logs_collection)
  3. Go to a project -> Settings -> Integrations -> Datadog
  4. Enter 123 as API key
  5. Check the Enable logs collection checkbox
  6. Click Save changes
  7. In rails console, run Integration.archive_trace_hooks
  8. Observe that the Datadog integration you created is not included in the result
  9. Switch to the andysoiron/revert-datadog-fields-refactor branch
  10. Reload the page
  11. Observe that the checkbox is not checked anymore because the value is now read from the database column
  12. Check the Enable logs collection checkbox
  13. Click Save changes
  14. In rails console, run Integration.archive_trace_hooks
  15. Observe that now the Datadog integration is now included in the result

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Andy Schoenen

Merge request reports

Loading