commit | cc271de2869edd0be4ad05cfc637bfbd0a06f272 | [log] [tgz] |
---|---|---|
author | Jay Doane <jaydoane@apache.org> | Tue Apr 05 16:58:03 2022 -0700 |
committer | Jay Doane <jaydoane@apache.org> | Tue Apr 05 16:58:03 2022 -0700 |
tree | cc388c45887a0b80d6aaa5997be3c905fbf5aa2c | |
parent | 7c6cd10040db2b11adde2232512adec1f6842404 [diff] |
Handle stats db conflicts Since a timestamp is used as the document id, it's possible for e.g. multiple nodes to attempt to insert the same document, resulting in logged errors like the following: [error] 2022-04-05T21:00:35.302496Z node1@127.0.0.1 emulator -------- Error in process <0.588.159> on node 'node1@127.0.0.1' with exit value: {{nocatch,conflict},[{fabric,update_doc,3,[{file,"src/fabric.erl"},{line,332}]},{ioq_server,save_to_db,0,[{file,"src/ioq_server.erl"},{line,529}]}]} This catches cases of `error:conflict` and logs them at info level instead.
The following are the list of IOQ classes:
One can configure an ioq bypass, which removes an IO class from prioritization, as below:
config:set("ioq.bypass", "view_update", "true")
Note that setting an IOQ bypass can effectively trump all other classes, especially in the case of an interactive bypass v. compaction. This can lead to high disk usage.
The priority for a class can also be set ala:
config:set("ioq", "compaction", "0.3")
Or globally, using snippet/rpc:
s:set_config("ioq", "compaction", "0.314", global) rpc:multicall(config, set, ["ioq", "compaction", "0.217"])
As the interactive class is ‘everything else’ its priority cannot be directly set.