Skip to content

Commit 6a5a309

Browse files
docs: Clarify that all settings are connection-scoped
- All settings can be passed to Connection.from_config() - Only thread_safe is read-only after initialization Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 477d365 commit 6a5a309

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

docs/design/thread-safe-mode.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,16 @@ export DJ_THREAD_SAFE=true
2525

2626
### Create Connections
2727

28+
All settings can be passed to `Connection.from_config()`:
29+
2830
```python
2931
conn = dj.Connection.from_config(
3032
host="localhost",
3133
user="user",
32-
password="password"
34+
password="password",
35+
safemode=False,
36+
display_limit=25,
37+
# ... any other settings
3338
)
3439
schema = dj.Schema("my_schema", connection=conn)
3540
```
@@ -44,6 +49,12 @@ schema = dj.Schema("my_schema", connection=conn)
4449
| `Connection.from_config()` | Works | Works |
4550
| `Schema(..., connection=conn)` | Works | Works |
4651

52+
## Read-Only Settings
53+
54+
Only `thread_safe` is read-only after initialization. It can only be set via:
55+
- Environment variable `DJ_THREAD_SAFE`
56+
- Config file `datajoint.json`
57+
4758
## Implementation
4859

4960
1. Add `thread_safe: bool = False` field to `Config` with `DJ_THREAD_SAFE` env alias

0 commit comments

Comments
 (0)