You've already forked AstralRinth
forked from didirus/AstralRinth
Revert "Implement redis clustering (#5189)"
This reverts commit fb1050e409.
This commit is contained in:
@@ -120,12 +120,7 @@ impl AnalyticsQueue {
|
||||
.arg(
|
||||
views_keys
|
||||
.iter()
|
||||
.map(|x| {
|
||||
format!(
|
||||
"{}:{{ns:{VIEWS_NAMESPACE}}}:{}-{}",
|
||||
VIEWS_NAMESPACE, x.0, x.1
|
||||
)
|
||||
})
|
||||
.map(|x| format!("{}:{}-{}", VIEWS_NAMESPACE, x.0, x.1))
|
||||
.collect::<Vec<_>>(),
|
||||
)
|
||||
.query_async::<Vec<Option<u32>>>(&mut redis)
|
||||
@@ -157,10 +152,7 @@ impl AnalyticsQueue {
|
||||
};
|
||||
|
||||
pipe.atomic().set_ex(
|
||||
format!(
|
||||
"{}:{{ns:{VIEWS_NAMESPACE}}}:{}-{}",
|
||||
VIEWS_NAMESPACE, key.0, key.1
|
||||
),
|
||||
format!("{}:{}-{}", VIEWS_NAMESPACE, key.0, key.1),
|
||||
new_count,
|
||||
6 * 60 * 60,
|
||||
);
|
||||
@@ -203,10 +195,7 @@ impl AnalyticsQueue {
|
||||
downloads_keys
|
||||
.iter()
|
||||
.map(|x| {
|
||||
format!(
|
||||
"{}:{{ns:{VIEWS_NAMESPACE}}}:{}-{}",
|
||||
DOWNLOADS_NAMESPACE, x.0, x.1
|
||||
)
|
||||
format!("{}:{}-{}", DOWNLOADS_NAMESPACE, x.0, x.1)
|
||||
})
|
||||
.collect::<Vec<_>>(),
|
||||
)
|
||||
@@ -230,10 +219,7 @@ impl AnalyticsQueue {
|
||||
};
|
||||
|
||||
pipe.atomic().set_ex(
|
||||
format!(
|
||||
"{}:{{ns:{VIEWS_NAMESPACE}}}:{}-{}",
|
||||
DOWNLOADS_NAMESPACE, key.0, key.1
|
||||
),
|
||||
format!("{}:{}-{}", DOWNLOADS_NAMESPACE, key.0, key.1),
|
||||
new_count,
|
||||
6 * 60 * 60,
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user