@@ -80,11 +80,14 @@ run(NumOperations) ->
8080 run (NumOperations , #{}).
8181
8282read_all_keys () ->
83- [_ = ra_kv :get ({? CLUSTER_NAME ,
83+ [begin
84+ _ = ra_kv :get ({? CLUSTER_NAME ,
8485 node ()},
85- <<" key_" ,(integer_to_binary (N ))/binary >>, 1000 )
86- || N <- lists :seq (1 , ? MAX_KEY )],
87- ok .
86+ <<" key_" ,(integer_to_binary (N ))/binary >>, 1000 ),
87+ ok
88+ end
89+ || N <- lists :seq (1 , ? MAX_KEY )],
90+ ok .
8891
8992read_all_keys_loop (Members0 ) when is_list (Members0 ) ->
9093 receive
@@ -114,9 +117,9 @@ read_all_keys_loop(Members0) when is_list(Members0) ->
114117run (NumOperations , Options ) when NumOperations > 0 ->
115118 % Start with a random number of nodes between 1 and 7
116119 NumNodes = rand :uniform (7 ),
117- logger :set_primary_config (level , warning ),
118- application :set_env (sasl , sasl_error_logger , false ),
119- application :stop (sasl ),
120+ ok = logger :set_primary_config (level , warning ),
121+ ok = application :set_env (sasl , sasl_error_logger , false ),
122+ ok = application :stop (sasl ),
120123 log (" ~s Starting cluster with ~p nodes~n " , [timestamp (), NumNodes ]),
121124 case setup_cluster (NumNodes , Options ) of
122125 {ok , Members , PeerNodes } ->
@@ -705,8 +708,9 @@ execute_operation(State, {network_partition}) ->
705708 % Block communication between partitioned node and other nodes
706709 % The harness node (current node) maintains access to all nodes
707710 [begin
708- erpc :call (NodeToPartitionName , inet_tcp_proxy_dist , block , [OtherNode ]),
709- erpc :call (OtherNode , inet_tcp_proxy_dist , block , [NodeToPartitionName ])
711+ _ = erpc :call (NodeToPartitionName , inet_tcp_proxy_dist , block , [OtherNode ]),
712+ _ = erpc :call (OtherNode , inet_tcp_proxy_dist , block , [NodeToPartitionName ]),
713+ ok
710714 end || OtherNode <- OtherNodes ],
711715
712716 State #{operations_count => OpCount + 1 ,
@@ -799,7 +803,7 @@ perform_consistency_check(State, MembersToValidate) ->
799803
800804 % Write full details to log file with difference analysis
801805 LogEntry = format_consistency_failure (MembersToValidate , ValidationResults ),
802- file :write_file (" ra_kv_harness.log" , LogEntry , [append ]),
806+ ok = file :write_file (" ra_kv_harness.log" , LogEntry , [append ]),
803807
804808 FailedOps = maps :get (failed_ops , State ),
805809 State #{failed_ops => FailedOps + 1 , remaining_ops => 0 , consistency_failed => true }
0 commit comments