aboutsummaryrefslogtreecommitdiff
path: root/cache_index_commits_display.go
diff options
context:
space:
mode:
authorRunxi Yu <me@runxiyu.org>2025-04-05 17:38:34 +0800
committerRunxi Yu <me@runxiyu.org>2025-04-05 17:38:34 +0800
commit04d9de0fae664502ea7d8b75be0d66e8ba9d2784 (patch)
tree8e320c6202e8bec623dc6c34c7b68556512d56cb /cache_index_commits_display.go
parentHTTP: Remove GC (diff)
downloadforge-04d9de0fae664502ea7d8b75be0d66e8ba9d2784.tar.gz
forge-04d9de0fae664502ea7d8b75be0d66e8ba9d2784.tar.zst
forge-04d9de0fae664502ea7d8b75be0d66e8ba9d2784.zip
Remove current caching mechanisms
Diffstat (limited to 'cache_index_commits_display.go')
-rw-r--r--cache_index_commits_display.go24
1 files changed, 0 insertions, 24 deletions
diff --git a/cache_index_commits_display.go b/cache_index_commits_display.go
deleted file mode 100644
index 54b3eab..0000000
--- a/cache_index_commits_display.go
+++ /dev/null
@@ -1,24 +0,0 @@
-// SPDX-License-Identifier: AGPL-3.0-only
-// SPDX-FileCopyrightText: Copyright (c) 2025 Runxi Yu <https://runxiyu.org>
-
-package main
-
-import (
- "github.com/dgraph-io/ristretto/v2"
- "go.lindenii.runxiyu.org/lindenii-common/clog"
-)
-
-// The key is the commit ID raw hash.
-var indexCommitsDisplayCache *ristretto.Cache[[]byte, []commitDisplayOld]
-
-func init() {
- var err error
- indexCommitsDisplayCache, err = ristretto.NewCache(&ristretto.Config[[]byte, []commitDisplayOld]{
- NumCounters: 1e4,
- MaxCost: 1 << 60,
- BufferItems: 8192,
- })
- if err != nil {
- clog.Fatal(1, "Error initializing indexCommitsCache: "+err.Error())
- }
-}