Commit 0085f5e0 authored by James Lopez's avatar James Lopez

start improving memory use on I/E

parent d0f5b3c2
...@@ -59,8 +59,11 @@ module Gitlab ...@@ -59,8 +59,11 @@ module Gitlab
next unless relation_hash_list next unless relation_hash_list
relation_hash = create_relation(relation_key, relation_hash_list) [relation_hash_list].flatten.each_slice(10) do |relation_hash_batch|
saved << restored_project.append_or_update_attribute(relation_key, relation_hash)
relation_hash = create_relation(relation_key, relation_hash_batch)
saved << restored_project.append_or_update_attribute(relation_key, relation_hash)
end
end end
saved.all? saved.all?
end end
...@@ -77,7 +80,7 @@ module Gitlab ...@@ -77,7 +80,7 @@ module Gitlab
@project.update_columns(project_params) @project.update_columns(project_params)
@project @project
end end
git che
def project_params def project_params
@tree_hash.reject do |key, value| @tree_hash.reject do |key, value|
# return params that are not 1 to many or 1 to 1 relations # return params that are not 1 to many or 1 to 1 relations
......
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