Skip to content
Snippets Groups Projects
Commit 9753a7d2 authored by Shinya Maeda's avatar Shinya Maeda
Browse files

Set higher TTL to write lock for traces

Set higher TTL is safer option when it comes to long running archive
parent b52e3b2d
No related branches found
No related tags found
No related merge requests found
---
title: Set higher TTL for write lock of trace to prevent concurrent archiving
merge_request: 30064
author:
type: fixed
Loading
Loading
@@ -5,7 +5,7 @@ module Gitlab
class Trace
include ::Gitlab::ExclusiveLeaseHelpers
 
LOCK_TTL = 1.minute
LOCK_TTL = 10.minutes
LOCK_RETRIES = 2
LOCK_SLEEP = 0.001.seconds
 
Loading
Loading
Loading
Loading
@@ -270,7 +270,7 @@ shared_examples_for 'common trace features' do
include ExclusiveLeaseHelpers
 
before do
stub_exclusive_lease_taken("trace:write:lock:#{trace.job.id}", timeout: 1.minute)
stub_exclusive_lease_taken("trace:write:lock:#{trace.job.id}", timeout: 10.minutes)
end
 
it 'blocks concurrent archiving' do
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment