Import and export backends
The user picks an execution backend on the import/export form.
| Backend | Enum | Behaviour |
|---|---|---|
| Inline | INLINE | Runs in the request process |
| Python queue | PYTHON_QUEUE | Process-local worker queue |
| Celery | CELERY | Optional extra; requires a working broker |
CeleryAvailabilityService hides Celery when the extra is not installed or
the broker is not usable.
Inline
Simplest. Fine for small files. The HTTP request stays open until the job finishes.
Python queue
ImportExportPythonQueueService is process-local. A job queued on one
gunicorn worker is not visible to another. Use it for development or a
single-process deploy, not a multi-worker production fleet.
Celery
pip install 'django-chassis[celery]'
The task lives at django_chassis.tasks.process_import_export. Configure
Celery in the project as usual. Chassis only dispatches and records history.
Dispatch
ImportExportDispatchService creates the history row and hands the job to
the selected backend. ImportExportProcessService locks the row and runs
it. Do not call these services from domain code unless you are extending the
flow.