-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ref: Remove default processing store, use redis backend everywhere (#…
- Loading branch information
Showing
13 changed files
with
56 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,18 @@ | ||
from sentry.cache.redis import RedisClusterCache | ||
from sentry.utils.kvstore.cache import CacheKVStorage | ||
from sentry.utils.codecs import JSONCodec | ||
from sentry.utils.kvstore.encoding import KVStorageCodecWrapper | ||
from sentry.utils.kvstore.redis import RedisKVStorage | ||
from sentry.utils.redis import redis_clusters | ||
|
||
from .base import EventProcessingStore | ||
|
||
|
||
def RedisClusterEventProcessingStore(**options) -> EventProcessingStore: | ||
""" | ||
Creates an instance of the processing store which uses the Redis Cluster | ||
cache as its backend. | ||
Keyword argument are forwarded to the ``RedisClusterCache`` constructor. | ||
Creates an instance of the processing store which uses a Redis Cluster | ||
client as its backend. | ||
""" | ||
return EventProcessingStore(CacheKVStorage(RedisClusterCache(**options))) | ||
return EventProcessingStore( | ||
KVStorageCodecWrapper( | ||
RedisKVStorage(redis_clusters.get(options.pop("cluster", "default"))), JSONCodec() | ||
) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters