2
0

Add FASP follow recommendation support (#34964)

This commit is contained in:
David Roetzel
2025-06-16 12:43:27 +02:00
committed by GitHub
parent ad32834ccd
commit b2506478ba
7 changed files with 136 additions and 0 deletions

View File

@@ -22,6 +22,10 @@ class AsyncRefresh
new(redis_key)
end
def self.exists?(redis_key)
redis.exists?(redis_key)
end
attr_reader :status, :result_count
def initialize(redis_key)
@@ -49,6 +53,11 @@ class AsyncRefresh
@status = 'finished'
end
def increment_result_count(by: 1)
redis.hincrby(@redis_key, 'result_count', by)
fetch_data_from_redis
end
def reload
fetch_data_from_redis
self