gavinchou commented on code in PR #47336:
URL: https://github.com/apache/doris/pull/47336#discussion_r1926366281
##########
cloud/src/meta-service/txn_kv.cpp:
##########
@@ -527,6 +528,17 @@ void Transaction::remove(std::string_view begin,
std::string_view end) {
}
TxnErrorCode Transaction::commit() {
+ if (config::txn_commit_fault_probability > 0.0) [[unlikely]] {
Review Comment:
use injection point instead
see common/cpp/sync_point.h TEST_INJECTION_POINT_RETURN_WITH_VALUE
and cloud/src/meta-service/injection_point_http.cpp
##########
cloud/src/common/config.h:
##########
@@ -252,4 +252,10 @@ CONF_Bool(enable_check_instance_id, "true");
// Check if ip eq 127.0.0.1, ms/recycler exit
CONF_Bool(enable_loopback_address_for_ms, "false");
+
+// injection random failure in txn->commit()
+// this config is for test usage, be careful when changing it.
+CONF_mDouble(txn_commit_fault_probability, "0.0");
Review Comment:
remove
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]