@@ -1378,6 +1378,7 @@ def __init__(self,
13781378 enable_auth : bool = False ,
13791379 state_update_notify : Optional [bool ] = True ,
13801380 state_update_interval_sec : Optional [int ] = 5 ,
1381+ break_update_interval_sec : Optional [int ] = 25 ,
13811382 enable_spdk_discovery_controller : Optional [bool ] = False ,
13821383 encryption_key : Optional [str ] = None ,
13831384 rebalance_period_sec : Optional [int ] = 7 ,
@@ -1432,6 +1433,7 @@ def __init__(self,
14321433 tgt_cmd_extra_args : Optional [str ] = None ,
14331434 iobuf_options : Optional [Dict [str , int ]] = None ,
14341435 qos_timeslice_in_usecs : Optional [int ] = 0 ,
1436+ notifications_interval : Optional [int ] = 60 ,
14351437 discovery_addr : Optional [str ] = None ,
14361438 discovery_addr_map : Optional [Dict [str , str ]] = None ,
14371439 discovery_port : Optional [int ] = None ,
@@ -1483,6 +1485,8 @@ def __init__(self,
14831485 self .state_update_notify = state_update_notify
14841486 #: ``state_update_interval_sec`` number of seconds to check for updates in OMAP
14851487 self .state_update_interval_sec = state_update_interval_sec
1488+ #: ``break_update_interval_sec`` break updates longet than this interval to yield CPU
1489+ self .break_update_interval_sec = break_update_interval_sec
14861490 #: ``enable_spdk_discovery_controller`` SPDK or ceph-nvmeof discovery service
14871491 self .enable_spdk_discovery_controller = enable_spdk_discovery_controller
14881492 #: ``encryption_key`` gateway encryption key
@@ -1597,6 +1601,8 @@ def __init__(self,
15971601 self .iobuf_options : Optional [Dict [str , int ]] = iobuf_options
15981602 #: ``qos_timeslice_in_usecs`` timeslice for QOS code, in micro seconds
15991603 self .qos_timeslice_in_usecs = qos_timeslice_in_usecs
1604+ #: ``notifications_interval`` read SPDK notifications interval, in seconds
1605+ self .notifications_interval = notifications_interval
16001606 #: ``discovery_addr`` address of the discovery service
16011607 self .discovery_addr = discovery_addr
16021608 #: ``discovery_addr_map`` per node address map of the discovery service
@@ -1691,6 +1697,7 @@ def validate(self) -> None:
16911697 ['DEBUG' , 'INFO' , 'WARNING' , 'ERROR' , 'NOTICE' ])
16921698 self .verify_spdk_ceph_connection_allocation ()
16931699 verify_non_negative_int (self .qos_timeslice_in_usecs , "QOS timeslice" )
1700+ verify_non_negative_int (self .notifications_interval , "SPDK notifications interval" )
16941701
16951702 verify_non_negative_number (self .spdk_ping_interval_in_seconds , "SPDK ping interval" )
16961703 if (
@@ -1708,6 +1715,7 @@ def validate(self) -> None:
17081715 raise SpecValidationError ("Allowed consecutive SPDK ping failures should be at least 1" )
17091716
17101717 verify_non_negative_int (self .state_update_interval_sec , "State update interval" )
1718+ verify_non_negative_int (self .break_update_interval_sec , "Break long updates interval" )
17111719 verify_non_negative_int (self .rebalance_period_sec , "Rebalance period" )
17121720 verify_non_negative_int (self .max_gws_in_grp , "Max gateways in group" )
17131721 verify_non_negative_int (self .max_ns_to_change_lb_grp ,
0 commit comments