Change project pipeline status cache key to follow project convention
Old cache key was: `projects/#{id}/pipeline_status/#{sha}` New one is: `project:#{id}:pipeline_status:#{sha}` This allows to delete any project related key just by scanning for: `project:#{id}`.
This commit is contained in:
parent
19440e6722
commit
cb541aef89
|
@ -42,7 +42,7 @@ module Gitlab
|
|||
end
|
||||
|
||||
def self.cache_key_for_project(project)
|
||||
"#{Gitlab::Redis::Cache::CACHE_NAMESPACE}:projects/#{project.id}/pipeline_status/#{project.commit&.sha}"
|
||||
"#{Gitlab::Redis::Cache::CACHE_NAMESPACE}:project:#{project.id}:pipeline_status:#{project.commit&.sha}"
|
||||
end
|
||||
|
||||
def self.update_for_pipeline(pipeline)
|
||||
|
|
Loading…
Reference in New Issue