Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-04-13 15:15:20 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-04-13 15:15:20 +0300
commit944a3a7b7e19354abdfcaa79129d0736c4b8565f (patch)
tree627802e84525946f11fdd6976ab5f04fb69e702c /db
parent62798ed33c878f936009da05fdddb707e1c7d58d (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'db')
-rw-r--r--db/docs/agent_group_authorizations.yml2
-rw-r--r--db/docs/agent_project_authorizations.yml2
-rw-r--r--db/docs/pm_checkpoints.yml2
-rw-r--r--db/docs/pm_licenses.yml2
-rw-r--r--db/docs/pm_package_version_licenses.yml2
-rw-r--r--db/docs/pm_package_versions.yml2
-rw-r--r--db/docs/pm_packages.yml2
-rw-r--r--db/docs/project_security_settings.yml2
-rw-r--r--db/docs/vulnerability_advisories.yml3
-rw-r--r--db/post_migrate/20230405072302_remove_p_ci_builds_metadata_partition_id_default.rb13
-rw-r--r--db/post_migrate/20230411153310_cleanup_bigint_conversion_for_sent_notifications.rb16
-rw-r--r--db/schema_migrations/202304050723021
-rw-r--r--db/schema_migrations/202304111533101
-rw-r--r--db/structure.sql16
14 files changed, 42 insertions, 24 deletions
diff --git a/db/docs/agent_group_authorizations.yml b/db/docs/agent_group_authorizations.yml
index 61c8733383a..c300ed3ba08 100644
--- a/db/docs/agent_group_authorizations.yml
+++ b/db/docs/agent_group_authorizations.yml
@@ -1,7 +1,7 @@
---
table_name: agent_group_authorizations
classes:
-- Clusters::Agents::GroupAuthorization
+- Clusters::Agents::Authorizations::CiAccess::GroupAuthorization
feature_categories:
- kubernetes_management
description: Configuration for a group that is authorized to use a particular cluster agent
diff --git a/db/docs/agent_project_authorizations.yml b/db/docs/agent_project_authorizations.yml
index e595c84b5d5..98a74b9f9b7 100644
--- a/db/docs/agent_project_authorizations.yml
+++ b/db/docs/agent_project_authorizations.yml
@@ -1,7 +1,7 @@
---
table_name: agent_project_authorizations
classes:
-- Clusters::Agents::ProjectAuthorization
+- Clusters::Agents::Authorizations::CiAccess::ProjectAuthorization
feature_categories:
- kubernetes_management
description: Configuration for a project that is authorized to use a particular cluster agent
diff --git a/db/docs/pm_checkpoints.yml b/db/docs/pm_checkpoints.yml
index e360e8ad356..2e42077943d 100644
--- a/db/docs/pm_checkpoints.yml
+++ b/db/docs/pm_checkpoints.yml
@@ -3,7 +3,7 @@ table_name: pm_checkpoints
classes:
- PackageMetadata::Checkpoint
feature_categories:
-- license_compliance
+- software_composition_analysis
description: Tracks position of last synced file.
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/109713
milestone: '15.9'
diff --git a/db/docs/pm_licenses.yml b/db/docs/pm_licenses.yml
index 55ef2719cbc..31d9ae7a179 100644
--- a/db/docs/pm_licenses.yml
+++ b/db/docs/pm_licenses.yml
@@ -3,7 +3,7 @@ table_name: pm_licenses
classes:
- PackageMetadata::License
feature_categories:
- - license_compliance
+ - software_composition_analysis
description: Tracks licenses referenced by public package registries.
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/102794
milestone: '15.6'
diff --git a/db/docs/pm_package_version_licenses.yml b/db/docs/pm_package_version_licenses.yml
index 439162ecf9d..1e3f21c4383 100644
--- a/db/docs/pm_package_version_licenses.yml
+++ b/db/docs/pm_package_version_licenses.yml
@@ -3,7 +3,7 @@ table_name: pm_package_version_licenses
classes:
- PackageMetadata::PackageVersionLicense
feature_categories:
- - license_compliance
+ - software_composition_analysis
description: Tracks licenses under which a given package version has been published.
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/102794
milestone: '15.6'
diff --git a/db/docs/pm_package_versions.yml b/db/docs/pm_package_versions.yml
index 7b015ddc174..b216d58ce99 100644
--- a/db/docs/pm_package_versions.yml
+++ b/db/docs/pm_package_versions.yml
@@ -3,7 +3,7 @@ table_name: pm_package_versions
classes:
- PackageMetadata::PackageVersion
feature_categories:
-- license_compliance
+- software_composition_analysis
description: Tracks package versions served by public package registries.
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/102794
milestone: '15.6'
diff --git a/db/docs/pm_packages.yml b/db/docs/pm_packages.yml
index 35932b37990..b114e75791f 100644
--- a/db/docs/pm_packages.yml
+++ b/db/docs/pm_packages.yml
@@ -3,7 +3,7 @@ table_name: pm_packages
classes:
- PackageMetadata::Package
feature_categories:
-- license_compliance
+- software_composition_analysis
description: Tracks packages served by public package registries.
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/102794
milestone: '15.6'
diff --git a/db/docs/project_security_settings.yml b/db/docs/project_security_settings.yml
index 99a767978fb..af559d11164 100644
--- a/db/docs/project_security_settings.yml
+++ b/db/docs/project_security_settings.yml
@@ -3,7 +3,7 @@ table_name: project_security_settings
classes:
- ProjectSecuritySetting
feature_categories:
-- dependency_scanning
+- software_composition_analysis
- container_scanning
description: Project settings related to security features.
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/32577
diff --git a/db/docs/vulnerability_advisories.yml b/db/docs/vulnerability_advisories.yml
index 18029e784b5..6ce7f30aa7c 100644
--- a/db/docs/vulnerability_advisories.yml
+++ b/db/docs/vulnerability_advisories.yml
@@ -4,8 +4,7 @@ classes:
- Vulnerabilities::Advisory
feature_categories:
- container_scanning
-- dependency_scanning
-- license_compliance
+- software_composition_analysis
description: Stores vulnerability advisories
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/95622
milestone: '15.4'
diff --git a/db/post_migrate/20230405072302_remove_p_ci_builds_metadata_partition_id_default.rb b/db/post_migrate/20230405072302_remove_p_ci_builds_metadata_partition_id_default.rb
new file mode 100644
index 00000000000..303210d85c7
--- /dev/null
+++ b/db/post_migrate/20230405072302_remove_p_ci_builds_metadata_partition_id_default.rb
@@ -0,0 +1,13 @@
+# frozen_string_literal: true
+
+class RemovePCiBuildsMetadataPartitionIdDefault < Gitlab::Database::Migration[2.1]
+ enable_lock_retries!
+
+ def up
+ change_column_default :p_ci_builds_metadata, :partition_id, from: 100, to: nil
+ end
+
+ def down
+ change_column_default :p_ci_builds_metadata, :partition_id, from: nil, to: 100
+ end
+end
diff --git a/db/post_migrate/20230411153310_cleanup_bigint_conversion_for_sent_notifications.rb b/db/post_migrate/20230411153310_cleanup_bigint_conversion_for_sent_notifications.rb
new file mode 100644
index 00000000000..e5f690a0a5a
--- /dev/null
+++ b/db/post_migrate/20230411153310_cleanup_bigint_conversion_for_sent_notifications.rb
@@ -0,0 +1,16 @@
+# frozen_string_literal: true
+
+class CleanupBigintConversionForSentNotifications < Gitlab::Database::Migration[2.1]
+ enable_lock_retries!
+
+ TABLE = :sent_notifications
+ COLUMNS = [:id]
+
+ def up
+ cleanup_conversion_of_integer_to_bigint(TABLE, COLUMNS)
+ end
+
+ def down
+ restore_conversion_of_integer_to_bigint(TABLE, COLUMNS)
+ end
+end
diff --git a/db/schema_migrations/20230405072302 b/db/schema_migrations/20230405072302
new file mode 100644
index 00000000000..cfa7bf7f175
--- /dev/null
+++ b/db/schema_migrations/20230405072302
@@ -0,0 +1 @@
+d93a103c002a536d11f75256f20e2b8708ec760286f65d89ab5abe446fe629d4 \ No newline at end of file
diff --git a/db/schema_migrations/20230411153310 b/db/schema_migrations/20230411153310
new file mode 100644
index 00000000000..14f317ccf08
--- /dev/null
+++ b/db/schema_migrations/20230411153310
@@ -0,0 +1 @@
+f4472433ac5b74296409a04790d64ed56551358c98428ebb2e5f15d2f3e2db31 \ No newline at end of file
diff --git a/db/structure.sql b/db/structure.sql
index 4a656b18fec..b6e93ad1f95 100644
--- a/db/structure.sql
+++ b/db/structure.sql
@@ -309,15 +309,6 @@ BEGIN
END;
$$;
-CREATE FUNCTION trigger_7f4fcd5aa322() RETURNS trigger
- LANGUAGE plpgsql
- AS $$
-BEGIN
- NEW."id_convert_to_bigint" := NEW."id";
- RETURN NEW;
-END;
-$$;
-
CREATE FUNCTION trigger_909cf0a06094() RETURNS trigger
LANGUAGE plpgsql
AS $$
@@ -13054,7 +13045,7 @@ CREATE TABLE p_ci_builds_metadata (
id bigint NOT NULL,
runtime_runner_features jsonb DEFAULT '{}'::jsonb NOT NULL,
id_tokens jsonb DEFAULT '{}'::jsonb NOT NULL,
- partition_id bigint DEFAULT 100 NOT NULL,
+ partition_id bigint NOT NULL,
debug_trace_enabled boolean DEFAULT false NOT NULL
)
PARTITION BY LIST (partition_id);
@@ -13083,7 +13074,7 @@ CREATE TABLE ci_builds_metadata (
id bigint DEFAULT nextval('ci_builds_metadata_id_seq'::regclass) NOT NULL,
runtime_runner_features jsonb DEFAULT '{}'::jsonb NOT NULL,
id_tokens jsonb DEFAULT '{}'::jsonb NOT NULL,
- partition_id bigint DEFAULT 100 NOT NULL,
+ partition_id bigint NOT NULL,
debug_trace_enabled boolean DEFAULT false NOT NULL
);
ALTER TABLE ONLY p_ci_builds_metadata ATTACH PARTITION ci_builds_metadata FOR VALUES IN ('100');
@@ -22292,7 +22283,6 @@ CREATE SEQUENCE self_managed_prometheus_alert_events_id_seq
ALTER SEQUENCE self_managed_prometheus_alert_events_id_seq OWNED BY self_managed_prometheus_alert_events.id;
CREATE TABLE sent_notifications (
- id_convert_to_bigint integer DEFAULT 0 NOT NULL,
project_id integer,
noteable_id integer,
noteable_type character varying,
@@ -34227,8 +34217,6 @@ CREATE TRIGGER trigger_482bac5ec48a BEFORE INSERT OR UPDATE ON system_note_metad
CREATE TRIGGER trigger_775287b6d67a BEFORE INSERT OR UPDATE ON note_diff_files FOR EACH ROW EXECUTE FUNCTION trigger_775287b6d67a();
-CREATE TRIGGER trigger_7f4fcd5aa322 BEFORE INSERT OR UPDATE ON sent_notifications FOR EACH ROW EXECUTE FUNCTION trigger_7f4fcd5aa322();
-
CREATE TRIGGER trigger_909cf0a06094 BEFORE INSERT OR UPDATE ON award_emoji FOR EACH ROW EXECUTE FUNCTION trigger_909cf0a06094();
CREATE TRIGGER trigger_bfc6e47be8cc BEFORE INSERT OR UPDATE ON snippet_user_mentions FOR EACH ROW EXECUTE FUNCTION trigger_bfc6e47be8cc();