0
0
Fork 0
mirror of https://github.com/matrix-org/dendrite synced 2024-11-17 07:10:51 +01:00

RoomServerEvents are mutable, given they can be redacted

This commit is contained in:
Till Faelligen 2023-03-06 17:58:08 +01:00
parent a684b850b9
commit 11a3fcc6cb
No known key found for this signature in database
GPG key ID: 3DF82D8AB9211D4E

View file

@ -22,11 +22,12 @@ import (
"github.com/dgraph-io/ristretto"
"github.com/dgraph-io/ristretto/z"
"github.com/matrix-org/dendrite/roomserver/types"
"github.com/matrix-org/dendrite/setup/config"
"github.com/matrix-org/gomatrixserverlib"
"github.com/prometheus/client_golang/prometheus"
"github.com/prometheus/client_golang/prometheus/promauto"
"github.com/matrix-org/dendrite/roomserver/types"
"github.com/matrix-org/dendrite/setup/config"
)
const (
@ -101,6 +102,7 @@ func NewRistrettoCache(maxCost config.DataUnit, maxAge time.Duration, enableProm
cache: cache,
Prefix: roomEventsCache,
MaxAge: maxAge,
Mutable: true,
},
},
RoomServerStateKeys: &RistrettoCachePartition[types.EventStateKeyNID, string]{ // event NID -> event state key