Skip to content

Commit d3228a9

Browse files
authored
feat(node_failure): increase flush interval (#738)
1 parent 98ed872 commit d3228a9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

injector/node_failure.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ func NewNodeFailureInjector(spec v1beta1.NodeFailureSpec, config NodeFailureInje
5252
}
5353

5454
if config.WaitBeforeShutdown == 0 {
55-
config.WaitBeforeShutdown = 10 * time.Second
55+
config.WaitBeforeShutdown = 31 * time.Second
5656
}
5757

5858
return &nodeFailureInjector{
@@ -82,7 +82,7 @@ func (i *nodeFailureInjector) Inject() error {
8282
}
8383

8484
// Trigger kernel panic
85-
i.config.Log.Infow("the injector will write to the sysrq trigger file in 10s")
85+
i.config.Log.Infof("the injector will write to the sysrq trigger file in %v", i.config.WaitBeforeShutdown)
8686
i.config.Log.Infow("from this point, if no fatal log occurs, the injection succeeded and the system will crash")
8787
_ = i.config.Log.Sync() // If we can't flush the logger, why would logging the error help? so we just ignore
8888

0 commit comments

Comments
 (0)