Skip to content

Show custom integration error message when testing settings

Summary

In some cases we pass an additional service_response message from the integration at https://gitlab.com/gitlab-org/gitlab/blob/eaac30bf6e629e2e159b5c27858f3311d277cb7a/app/controllers/projects/services_controller.rb#L80, in addition to the main message.

Steps to reproduce

  1. Set up the Datadog integration in a project without CI pipelines.
  2. Click Test settings.

What is the current bug behavior?

A message Connection failed. Please check your settings. is shown.

What is the expected correct behavior?

The message Ensure the project has CI pipelines. from https://gitlab.com/gitlab-org/gitlab/blob/eaac30bf6e629e2e159b5c27858f3311d277cb7a/app/services/concerns/integrations/project_test_data.rb#L46 should also be shown.

Output of checks

This bug happens on GitLab.com

Possible fixes

Looks like we need to include the second message in https://gitlab.com/gitlab-org/gitlab/blob/eaac30bf6e629e2e159b5c27858f3311d277cb7a/app/assets/javascripts/integrations/edit/components/integration_form.vue#L130