Commit 18c0507f authored by Luke Duncalfe's avatar Luke Duncalfe

Ignore more Database.bulk_insert usages

Ignoring more uses of the deprecated `Database.bulk_insert` method
after adjusting the cop to detect them dcbf37f9.

https://gitlab.com/gitlab-org/gitlab/-/issues/221032
parent dcbf37f9
...@@ -41,7 +41,7 @@ module Packages ...@@ -41,7 +41,7 @@ module Packages
} }
end end
::Gitlab::Database.bulk_insert(::Packages::Nuget::DependencyLinkMetadatum.table_name, rows.compact) ::Gitlab::Database.bulk_insert(::Packages::Nuget::DependencyLinkMetadatum.table_name, rows.compact) # rubocop:disable Gitlab/BulkInsert
end end
def raw_dependency_for(dependency) def raw_dependency_for(dependency)
......
...@@ -15,7 +15,7 @@ module Packages ...@@ -15,7 +15,7 @@ module Packages
tags_to_create = @tags - existing_tags tags_to_create = @tags - existing_tags
@package.tags.with_name(tags_to_destroy).delete_all if tags_to_destroy.any? @package.tags.with_name(tags_to_destroy).delete_all if tags_to_destroy.any?
::Gitlab::Database.bulk_insert(Packages::Tag.table_name, rows(tags_to_create)) if tags_to_create.any? ::Gitlab::Database.bulk_insert(Packages::Tag.table_name, rows(tags_to_create)) if tags_to_create.any? # rubocop:disable Gitlab/BulkInsert
end end
private private
......
...@@ -19,7 +19,7 @@ module EE ...@@ -19,7 +19,7 @@ module EE
return if collection.empty? return if collection.empty?
collection.in_groups_of(BATCH_SIZE, false) do |services| collection.in_groups_of(BATCH_SIZE, false) do |services|
::Gitlab::Database.bulk_insert(::AuditEvent.table_name, services.map(&:attributes)) ::Gitlab::Database.bulk_insert(::AuditEvent.table_name, services.map(&:attributes)) # rubocop:disable Gitlab/BulkInsert
services.each(&:log_security_event_to_file) services.each(&:log_security_event_to_file)
end end
......
...@@ -13,7 +13,7 @@ module EE ...@@ -13,7 +13,7 @@ module EE
def execute def execute
unless resource_weight_changes.empty? unless resource_weight_changes.empty?
::Gitlab::Database.bulk_insert(ResourceWeightEvent.table_name, resource_weight_changes) ::Gitlab::Database.bulk_insert(ResourceWeightEvent.table_name, resource_weight_changes) # rubocop:disable Gitlab/BulkInsert
resources.each(&:expire_note_etag_cache) resources.each(&:expire_note_etag_cache)
end end
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment