diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-03-30 12:07:58 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-03-30 12:07:58 +0300 |
commit | 45b4df3e57c949c88107840c44ccbfaf2eabdf26 (patch) | |
tree | f73c1533a75b03d2ceb1361644e0d8ab97568a8f /lib/gitlab/import_export | |
parent | 7421e6f9f2b5889b05738af7eba568af6ae3fcbc (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/gitlab/import_export')
-rw-r--r-- | lib/gitlab/import_export/fast_hash_serializer.rb | 7 | ||||
-rw-r--r-- | lib/gitlab/import_export/legacy_relation_tree_saver.rb | 10 |
2 files changed, 4 insertions, 13 deletions
diff --git a/lib/gitlab/import_export/fast_hash_serializer.rb b/lib/gitlab/import_export/fast_hash_serializer.rb index c6ecf13ded8..c5fb00ed741 100644 --- a/lib/gitlab/import_export/fast_hash_serializer.rb +++ b/lib/gitlab/import_export/fast_hash_serializer.rb @@ -142,12 +142,7 @@ module Gitlab # returned by database when no `ORDER` is specified batch = batch.reorder(batch.klass.primary_key) - if Feature.enabled?(:export_fast_serialize_with_raw_json, default_enabled: true) - data.append(JSONBatchRelation.new(batch, options, preloads[key]).tap(&:raw_json)) - else - batch = batch.preload(preloads[key]) if preloads&.key?(key) - data += batch.as_json(options) - end + data.append(JSONBatchRelation.new(batch, options, preloads[key]).tap(&:raw_json)) end data diff --git a/lib/gitlab/import_export/legacy_relation_tree_saver.rb b/lib/gitlab/import_export/legacy_relation_tree_saver.rb index fe3e64358e5..cf75a2c7fa8 100644 --- a/lib/gitlab/import_export/legacy_relation_tree_saver.rb +++ b/lib/gitlab/import_export/legacy_relation_tree_saver.rb @@ -6,13 +6,9 @@ module Gitlab include Gitlab::ImportExport::CommandLineUtil def serialize(exportable, relations_tree) - if Feature.enabled?(:export_fast_serialize, default_enabled: true) - Gitlab::ImportExport::FastHashSerializer - .new(exportable, relations_tree) - .execute - else - exportable.as_json(relations_tree) - end + Gitlab::ImportExport::FastHashSerializer + .new(exportable, relations_tree) + .execute end def save(tree, dir_path, filename) |