Metadata-Version: 2.4
Name: addok-sqlite-store
Version: 1.1.0
Summary: Store documents in SQLite for Addok.
Author-email: Yohan Boniface <yohan.boniface@data.gouv.fr>
License-Expression: MIT
Project-URL: Homepage, https://github.com/addok/addok-sqlite-store
Keywords: addok,geocoding,sqlite,plugin
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: Topic :: Scientific/Engineering :: GIS
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: addok
Provides-Extra: dev
Requires-Dist: pytest~=8.3; extra == "dev"
Requires-Dist: pytest-cov~=6.1; extra == "dev"
Requires-Dist: build~=1.2; extra == "dev"
Requires-Dist: twine==6.1.0; extra == "dev"
Dynamic: license-file

# addok-sqlite-store

Addok plugin to store documents in SQLite instead of Redis to reduce memory usage.

## Features

- **SQLite storage**: Store documents in a SQLite database instead of Redis
- **Memory optimization**: Reduce Redis RAM usage for large datasets

## Installation

```bash
pip install addok-sqlite-store
```

## Configuration

Add the following to your Addok configuration file to activate the plugin:

```python
# Use SQLite as document store
DOCUMENT_STORE_PYPATH = 'addok_sqlite_store.SQLiteStore'
```

The SQLite database will be created at `addok.db` by default. You can customize the path:

```python
# Optional: customize the database path
SQLITE_DB_PATH = '/path/to/your/database.db'
```

Or use environment variables:

```bash
export ADDOK_DOCUMENT_STORE_PYPATH='addok_sqlite_store.SQLiteStore'
export ADDOK_SQLITE_DB_PATH='/path/to/your/database.db'  # optional
```
