Commit fc71c37
fix: sync IAppConfig cache when CA ID is empty
When getCaId() finds an empty CA ID in cache, it now calls
clearCache(true) to reload from database before generating a new one.
This prevents race conditions in test environments where CLI commands
and HTTP requests may execute simultaneously with independent caches.
The solution is simpler than using file locks and works transparently
in both test and production environments with minimal overhead.
Signed-off-by: Vitor Mattos <[email protected]>1 parent bffd35d commit fc71c37
1 file changed
Lines changed: 2 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
141 | 141 | | |
142 | 142 | | |
143 | 143 | | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | | - | |
150 | | - | |
151 | | - | |
| 144 | + | |
| 145 | + | |
152 | 146 | | |
153 | 147 | | |
154 | 148 | | |
| |||
0 commit comments