jaydoane commented on code in PR #4813:
URL: https://github.com/apache/couchdb/pull/4813#discussion_r1418342451
##########
src/config/src/config.erl:
##########
@@ -315,6 +315,19 @@ handle_call({delete, Sec, Key, Persist, Reason}, _From,
Config) ->
_ ->
ok
end,
+ % If persistent, there will always be a delete marker just written
+ % in the last .ini file, so only reload in the non-persistent case.
+ Persist orelse
+ begin
+ IniMap = ini_map(Config#config.ini_files),
+ case maps:find({Sec, Key}, IniMap) of
+ % ?DELETE markers not inserted
+ {ok, Val} when is_list(Val) ->
+ true = ets:insert(?MODULE, {{Sec, Key}, Val});
+ _ ->
+ ok
+ end
Review Comment:
With the change to eliminate delete markers, it seems that reloading any
remaining .ini values is probably the most consistent thing to do.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]