mirror of
https://github.com/goauthentik/authentik
synced 2026-04-26 01:25:02 +02:00
17 lines
437 B
Python
17 lines
437 B
Python
from django.db import models
|
|
from psqlextra.manager import PostgresManager
|
|
|
|
|
|
class CacheEntry(models.Model):
|
|
cache_key = models.TextField(primary_key=True)
|
|
value = models.TextField()
|
|
expires = models.DateTimeField(db_index=True)
|
|
|
|
objects = PostgresManager() # type: ignore[no-untyped-call]
|
|
|
|
class Meta:
|
|
default_permissions = []
|
|
|
|
def __str__(self) -> str:
|
|
return f"Cache entry '{self.cache_key}'"
|