diff --git a/projects/jupyter-server-ydoc/jupyter_server_ydoc/stores.py b/projects/jupyter-server-ydoc/jupyter_server_ydoc/stores.py index 4f31a9de..25727b62 100644 --- a/projects/jupyter-server-ydoc/jupyter_server_ydoc/stores.py +++ b/projects/jupyter-server-ydoc/jupyter_server_ydoc/stores.py @@ -30,3 +30,18 @@ class SQLiteYStore(LoggingConfigurable, _SQLiteYStore, metaclass=SQLiteYStoreMet help="""The document time-to-live in seconds. Defaults to None (document history is never cleared).""", ) + + history_length = Int( + None, + allow_none=True, + config=True, + help="""The maximum age (in seconds) of document history to retain. + Entries older than this window are automatically pruned. + Defaults to None (history is never cleared).""", + ) + + min_cleanup_interval = Int( + 60, + config=True, + help="""Minimum interval in seconds between automatic cleanup operations. Defaults to 60 seconds.""", + )