Commit 2006724e authored by Thong Kuah's avatar Thong Kuah

Merge branch 'if-64985-redis_pipelined_in_active_session' into 'master'

ActiveSession.cleaned_up_lookup_entries to use Redis#pipelined

See merge request gitlab-org/gitlab-ce!31096
parents f5fcb9a1 9fd644f8
......@@ -136,9 +136,11 @@ class ActiveSession
# only the single key entries are automatically expired by redis, the
# lookup entries in the set need to be removed manually.
session_ids_and_entries = session_ids.zip(entries)
redis.pipelined do
session_ids_and_entries.reject { |_session_id, entry| entry }.each do |session_id, _entry|
redis.srem(lookup_key_name(user.id), session_id)
end
end
entries.compact
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