mirror of https://github.com/pixelfed/pixelfed.git
Merge pull request #4776 from pixelfed/staging
Update HashtagService, reduce cached_count cache ttl
This commit is contained in:
commit
47b0354e16
|
@ -57,6 +57,7 @@
|
||||||
- Update HashtagService, improve count perf ([3327a008](https://github.com/pixelfed/pixelfed/commit/3327a008))
|
- Update HashtagService, improve count perf ([3327a008](https://github.com/pixelfed/pixelfed/commit/3327a008))
|
||||||
- Update StatusHashtagService, remove problematic cache layer ([e5401f85](https://github.com/pixelfed/pixelfed/commit/e5401f85))
|
- Update StatusHashtagService, remove problematic cache layer ([e5401f85](https://github.com/pixelfed/pixelfed/commit/e5401f85))
|
||||||
- Update HomeFeedPipeline, fix tag filtering ([f105f4e8](https://github.com/pixelfed/pixelfed/commit/f105f4e8))
|
- Update HomeFeedPipeline, fix tag filtering ([f105f4e8](https://github.com/pixelfed/pixelfed/commit/f105f4e8))
|
||||||
|
- Update HashtagService, reduce cached_count cache ttl ([15f29f7d](https://github.com/pixelfed/pixelfed/commit/15f29f7d))
|
||||||
- ([](https://github.com/pixelfed/pixelfed/commit/))
|
- ([](https://github.com/pixelfed/pixelfed/commit/))
|
||||||
|
|
||||||
## [v0.11.9 (2023-08-21)](https://github.com/pixelfed/pixelfed/compare/v0.11.8...v0.11.9)
|
## [v0.11.9 (2023-08-21)](https://github.com/pixelfed/pixelfed/compare/v0.11.8...v0.11.9)
|
||||||
|
|
|
@ -29,7 +29,7 @@ class HashtagService
|
||||||
|
|
||||||
public static function count($id)
|
public static function count($id)
|
||||||
{
|
{
|
||||||
return Cache::remember('services:hashtag:public-count:by_id:' . $id, 3600, function() use($id) {
|
return Cache::remember('services:hashtag:total-count:by_id:' . $id, 300, function() use($id) {
|
||||||
$tag = Hashtag::find($id);
|
$tag = Hashtag::find($id);
|
||||||
return $tag ? $tag->cached_count ?? 0 : 0;
|
return $tag ? $tag->cached_count ?? 0 : 0;
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue