Tags: apache/couchdb-erlfdb
Tags
Make the default wait timeout infinity (continued) This the continuation of #22. There, we updated only one `after` clause and forgot the other. The reasoning is the same as before -- make erlfdb behave consistent with other FDB clients which do not have top level client-side timeouts for futures.
Make the default wait timeout infinity This brings the default behavior in line with other FoundationDB client libraries which don't use client-side timeouts when waiting for futures to fire. A few other reasons are: * Currently we may generate spurious future `ready` messages when timeouts fire during overload scenarios. The caller would have to know to flush ready messages if they caught a `{timeout, _}` * The response may succeed under 5 seconds, but it would be queued in the networking layer and throw a `timeout` error on the Erlang side. * Timeouts can be set as a transaction or db handle options. It's easier to apply configuration defaults there than for individual wait functions. * Watch futures are not bound by the 5 second transaction time limit, and they'd have to know about the default `wait/1,2` call timeout to know to extend it or set it to `infinity`. Add ERLFDB_IS_RETRYABLE/2 guard This is a guard which may be used to catch and handle retryable errors. It's more ergonomic as a guard than a function, since the handler won't have to catch and re-throw unwanted (non-retryable) exceptions. Along with a guard, some common FDB error codes are also defined. It's not an exhaustive list and mostly consists of retryable and a few other common errors.
Fix erlfdb_database_set_option `else` case This was detected with more a recent compiler as an uninitialized variable: ``` c_src/main.c: In function 'erlfdb_database_set_option': c_src/main.c:818:9: error: 'option' may be used uninitialized in this function [-Werror=maybe-uninitialized] ```
Use client buggify options on the client Previously we used plain buggify options which are meant for the server. Switch them to the client versions. Can check if it works with: ``` ERL_ZFLAGS="-erlfdb network_options '[client_buggify_enable, {client_buggify_section_activated_probability, 60}, {client_buggify_section_fired_probability, 60}]'" make elixir tests=test/elixir/test/basics_test.exs ``` PreviousNext