readConfig traverses the current config to path and writes its JSON encoding to out.
(path string, out io.Writer)
| 278 | // readConfig traverses the current config to path |
| 279 | // and writes its JSON encoding to out. |
| 280 | func readConfig(path string, out io.Writer) error { |
| 281 | rawCfgMu.RLock() |
| 282 | defer rawCfgMu.RUnlock() |
| 283 | return unsyncedConfigAccess(http.MethodGet, path, nil, out) |
| 284 | } |
| 285 | |
| 286 | // indexConfigObjects recursively searches ptr for object fields named |
| 287 | // "@id" and maps that ID value to the full configPath in the index. |