@@ -119,6 +119,13 @@ pub async fn loop_stages(
119119 Ok ( info) => break info,
120120 Err ( e) => {
121121 error ! ( "Error getting epoch info from RPC. Retrying..." ) ;
122+ datapoint_error ! (
123+ "tip_router_cli.get_epoch_info" ,
124+ ( "operator_address" , cli. operator_address. clone( ) , String ) ,
125+ ( "status" , "error" , String ) ,
126+ ( "error" , e. to_string( ) , String ) ,
127+ "cluster" => & cli. cluster,
128+ ) ;
122129 tokio:: time:: sleep ( Duration :: from_secs ( 5 ) ) . await ;
123130 }
124131 }
@@ -131,6 +138,13 @@ pub async fn loop_stages(
131138 Ok ( schedule) => break schedule,
132139 Err ( e) => {
133140 error ! ( "Error getting epoch schedule from RPC. Retrying..." ) ;
141+ datapoint_error ! (
142+ "tip_router_cli.get_epoch_schedule" ,
143+ ( "operator_address" , cli. operator_address. clone( ) , String ) ,
144+ ( "status" , "error" , String ) ,
145+ ( "error" , e. to_string( ) , String ) ,
146+ "cluster" => & cli. cluster,
147+ ) ;
134148 tokio:: time:: sleep ( Duration :: from_secs ( 5 ) ) . await ;
135149 }
136150 }
@@ -333,6 +347,15 @@ pub async fn loop_stages(
333347 "Failed to submit epoch {} to NCN: {:?}" ,
334348 epoch_to_process, e
335349 ) ;
350+ datapoint_error ! (
351+ "tip_router_cli.cast_vote" ,
352+ ( "operator_address" , operator_address. to_string( ) , String ) ,
353+ ( "epoch" , epoch_to_process, i64 ) ,
354+ ( "status" , "error" , String ) ,
355+ ( "error" , e. to_string( ) , String ) ,
356+ ( "state" , "cast_vote" , String ) ,
357+ "cluster" => & cli. cluster,
358+ ) ;
336359 }
337360 stage = OperatorState :: WaitForNextEpoch ;
338361 }
0 commit comments