diff --git a/.gitlab/ci/qa-common/variables.gitlab-ci.yml b/.gitlab/ci/qa-common/variables.gitlab-ci.yml index 44b8186f433..7ecd8336e91 100644 --- a/.gitlab/ci/qa-common/variables.gitlab-ci.yml +++ b/.gitlab/ci/qa-common/variables.gitlab-ci.yml @@ -16,7 +16,7 @@ variables: # Retry failed specs in separate process QA_RETRY_FAILED_SPECS: "true" # Helm chart ref used by test-on-cng pipeline - GITLAB_HELM_CHART_REF: "4073ca4932209fc3d64d20ef48dd6f1e6c58cb15" + GITLAB_HELM_CHART_REF: "0e35aaeaaf6a85ab70a89c67c5f39bc08f11d669" # Specific ref for cng-mirror project to trigger builds for GITLAB_CNG_MIRROR_REF: "df7aafcccafdbab732a7cf757efb3b7b74c851dd" # Makes sure some of the common scripts from pipeline-common use bundler to execute commands diff --git a/app/services/spam/spam_action_service.rb b/app/services/spam/spam_action_service.rb index 343243eb1d1..6e97ad4f1ec 100644 --- a/app/services/spam/spam_action_service.rb +++ b/app/services/spam/spam_action_service.rb @@ -106,6 +106,7 @@ module Spam user_id: user.id, title: target.spam_title, description: target.spam_description, + target_id: target.id, source_ip: spam_params&.ip_address, user_agent: spam_params&.user_agent, noteable_type: noteable_type, diff --git a/db/migrate/20250606013519_add_target_id_to_spam_logs.rb b/db/migrate/20250606013519_add_target_id_to_spam_logs.rb new file mode 100644 index 00000000000..b954d009842 --- /dev/null +++ b/db/migrate/20250606013519_add_target_id_to_spam_logs.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +class AddTargetIdToSpamLogs < Gitlab::Database::Migration[2.3] + milestone '18.1' + + def change + add_column :spam_logs, :target_id, :bigint + end +end diff --git a/db/schema_migrations/20250606013519 b/db/schema_migrations/20250606013519 new file mode 100644 index 00000000000..0f068c231ce --- /dev/null +++ b/db/schema_migrations/20250606013519 @@ -0,0 +1 @@ +bc9f990b0a4781386f58eee418405808343cf9f6d12b4d4e04d59a338638c25a \ No newline at end of file diff --git a/db/structure.sql b/db/structure.sql index d678c69fcd0..1daf7885ab5 100644 --- a/db/structure.sql +++ b/db/structure.sql @@ -23367,7 +23367,8 @@ CREATE TABLE spam_logs ( created_at timestamp without time zone NOT NULL, updated_at timestamp without time zone NOT NULL, submitted_as_ham boolean DEFAULT false NOT NULL, - recaptcha_verified boolean DEFAULT false NOT NULL + recaptcha_verified boolean DEFAULT false NOT NULL, + target_id bigint ); CREATE SEQUENCE spam_logs_id_seq diff --git a/doc/development/documentation/styleguide/availability_details.md b/doc/development/documentation/styleguide/availability_details.md index a0cb9784833..0b2bd7ea82d 100644 --- a/doc/development/documentation/styleguide/availability_details.md +++ b/doc/development/documentation/styleguide/availability_details.md @@ -190,8 +190,8 @@ For features introduced behind feature flags, add details about the feature flag Remove history items and inline text that refer to unsupported versions. GitLab supports the current major version and two previous major versions. -For example, if 17.0 is the current major version, all major and minor releases of -GitLab 17.0, 16.0, and 15.0 are supported. +For example, if 18.0 is the current major version, all major and minor releases of +GitLab 18.0, 17.0, and 16.0 are supported. For the list of current supported versions, see [Version support](https://about.gitlab.com/support/statement-of-support/#version-support). @@ -205,13 +205,13 @@ When a new major version is about to be released, create merge requests to remove mentions of the last unsupported version. Only merge them during the milestone of the new major release. -For example, if GitLab 17.0 is the next major upcoming release: +For example, if GitLab 19.0 is the next major upcoming release: -- The supported versions are 16, 15, and 14. -- When GitLab 17.0 is released, GitLab 14 is no longer supported. +- The supported versions are 18, 17, and 16. +- When GitLab 19.0 is released, GitLab 16 is no longer supported. -Create merge requests to remove mentions of GitLab 14, but only -merge them during the 17.0 milestone, after 16.11 is released. +Create merge requests to remove mentions of GitLab 16, but only +merge them during the 19.0 milestone, after 18.11 is released. ## When to add availability details diff --git a/locale/gitlab.pot b/locale/gitlab.pot index 9d6fb02941f..4cfc61ba2c0 100644 --- a/locale/gitlab.pot +++ b/locale/gitlab.pot @@ -15778,9 +15778,6 @@ msgstr "" msgid "ComplianceFrameworks|Selected projects" msgstr "" -msgid "ComplianceFrameworks|Send via:" -msgstr "" - msgid "ComplianceFrameworks|Set as default" msgstr "" @@ -16440,9 +16437,6 @@ msgstr "" msgid "ComplianceStandardsAdherence|Establish a process to periodically review and remove inactive users." msgstr "" -msgid "ComplianceStandardsAdherence|External control" -msgstr "" - msgid "ComplianceStandardsAdherence|Failed" msgstr "" diff --git a/spec/db/schema_spec.rb b/spec/db/schema_spec.rb index 10539a7ee59..50ab6ef75e3 100644 --- a/spec/db/schema_spec.rb +++ b/spec/db/schema_spec.rb @@ -179,7 +179,7 @@ RSpec.describe 'Database schema', sent_notifications: %w[project_id noteable_id recipient_id commit_id in_reply_to_discussion_id namespace_id], # namespace_id FK will be added after index creation slack_integrations: %w[team_id user_id bot_user_id], # these are external Slack IDs snippets: %w[author_id], - spam_logs: %w[user_id], + spam_logs: %w[user_id target_id], status_check_responses: %w[external_approval_rule_id], subscriptions: %w[user_id subscribable_id], suggestions: %w[commit_id], diff --git a/spec/services/spam/spam_action_service_spec.rb b/spec/services/spam/spam_action_service_spec.rb index 9487325d866..8e333ceffb5 100644 --- a/spec/services/spam/spam_action_service_spec.rb +++ b/spec/services/spam/spam_action_service_spec.rb @@ -80,6 +80,7 @@ RSpec.describe Spam::SpamActionService, feature_category: :instance_resiliency d expect(new_spam_log.description).to eq(target.spam_description) expect(new_spam_log.source_ip).to eq(fake_ip) expect(new_spam_log.user_agent).to eq(fake_user_agent) + expect(new_spam_log.target_id).to eq(target.id) expect(new_spam_log.noteable_type).to eq(target_type) expect(new_spam_log.via_api).to eq(true) end