Commit e004d1d
committed
feat: add configurable Ecto query log level
Add centralized log level configuration for Ecto queries following
Oban's wrapper pattern. This eliminates excessive debug-level SQL
query logs by default.
- Add `log_level` config option (default: false, disables query logging)
- Create `Durable.Repo` wrapper module that applies log level to all queries
- Update all direct repo calls to use the wrapper
Usage:
# Default: query logging disabled
{Durable, repo: MyApp.Repo}
# Enable debug logging for troubleshooting
{Durable, repo: MyApp.Repo, log_level: :debug}1 parent 11c3d06 commit e004d1d
10 files changed
Lines changed: 432 additions & 319 deletions
File tree
- lib/durable
- executor
- queue/adapters
- scheduler
- wait
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
17 | 18 | | |
18 | 19 | | |
19 | 20 | | |
| |||
43 | 44 | | |
44 | 45 | | |
45 | 46 | | |
46 | | - | |
| 47 | + | |
| 48 | + | |
47 | 49 | | |
48 | 50 | | |
49 | 51 | | |
| |||
55 | 57 | | |
56 | 58 | | |
57 | 59 | | |
58 | | - | |
| 60 | + | |
| 61 | + | |
59 | 62 | | |
60 | 63 | | |
61 | 64 | | |
| |||
103 | 106 | | |
104 | 107 | | |
105 | 108 | | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
106 | 114 | | |
107 | 115 | | |
108 | 116 | | |
| |||
0 commit comments