class NsLcm(LcmBase):
- timeout_vca_on_error = (
+ timeout_scale_on_error = (
5 * 60
) # Time for charm from first time at blocked,error status to mark as failed
+ timeout_scale_on_error_outer_factor = 1.05 # Factor in relation to timeout_scale_on_error related to the timeout to be applied within the asyncio.wait_for coroutine
timeout_ns_deploy = 2 * 3600 # default global timeout for deployment a ns
timeout_ns_terminate = 1800 # default global timeout for un deployment a ns
timeout_ns_heal = 1800 # default global timeout for un deployment a ns
timeout_charm_delete = 10 * 60
- timeout_primitive = 30 * 60 # timeout for primitive execution
+ timeout_primitive = 30 * 60 # Timeout for primitive execution
+ timeout_primitive_outer_factor = 1.05 # Factor in relation to timeout_primitive related to the timeout to be applied within the asyncio.wait_for coroutine
timeout_ns_update = 30 * 60 # timeout for ns update
timeout_progress_primitive = (
10 * 60
primitive_name=terminate_config_primitive["name"],
params=primitive_params_,
db_dict=db_dict,
+ total_timeout=self.timeout_primitive,
vca_id=vca_id,
),
- timeout=600,
+ timeout=self.timeout_primitive
+ * self.timeout_primitive_outer_factor,
)
await asyncio.wait_for(
self.k8scluster_map[k8s_cluster_type].scale(
- kdu_instance,
- scale,
- kdu_scaling_info["resource-name"],
+ kdu_instance=kdu_instance,
+ scale=scale,
+ resource_name=kdu_scaling_info["resource-name"],
+ total_timeout=self.timeout_scale_on_error,
vca_id=vca_id,
cluster_uuid=cluster_uuid,
kdu_model=kdu_model,
atomic=True,
db_dict=db_dict,
),
- timeout=self.timeout_vca_on_error,
+ timeout=self.timeout_scale_on_error
+ * self.timeout_scale_on_error_outer_factor,
)
if kdu_scaling_info["type"] == "create":