You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 8, 2022. It is now read-only.
There is issue with task watching from command line in Snap version 1.1.0 release and current master (85079bc). Snap CLI stops updating task watch data and snaptel process starts to consume 100% CPU after some time, until Ctrl-C.
Issue was mentioned here: intelsdi-x/snap-plugin-collector-cpu#50
I checked it for several different collector plugins and issue still exists, so it is not plugin-related issue.
It seems that for some reason, the timeout setting stops whole watching process and then snapctl goes into some infinite loop. For example, snaptel --timeout 15s stops responding exactly after 15 seconds.
Workaround
Hopefully, there is workaround that can be applied very quickly. Standard Go HTTP client Timeout value set to 0 means infinite timeout, checked it and
snaptel --timeout 0s <Task ID>
does not hang at all. To implement this workaround ti is needed to modify snap/cmd/snaptel/flags.go:
flTimeout= cli.DurationFlag{
Name: "timeout, t",
Usage: "Timeout to be set on HTTP request to the server",
Value: 10*time.Second,
}
and change default timeout value of 10 seconds to zero.
The text was updated successfully, but these errors were encountered:
Removes the timeout from the rest client when using task watch. Because
the timeout isn't reset on each transfer of data having a timeout
causes the watch to eventually hang when set.
Removes the timeout from the rest client when using task watch. Because
the timeout isn't reset on each transfer of data having a timeout
causes the watch to eventually hang when set.
There is issue with task watching from command line in Snap version 1.1.0 release and current master (85079bc). Snap CLI stops updating task watch data and snaptel process starts to consume 100% CPU after some time, until Ctrl-C.
Issue was mentioned here: intelsdi-x/snap-plugin-collector-cpu#50
I checked it for several different collector plugins and issue still exists, so it is not plugin-related issue.
It seems that for some reason, the timeout setting stops whole watching process and then snapctl goes into some infinite loop. For example, snaptel --timeout 15s stops responding exactly after 15 seconds.
Workaround
Hopefully, there is workaround that can be applied very quickly. Standard Go HTTP client Timeout value set to 0 means infinite timeout, checked it and
does not hang at all. To implement this workaround ti is needed to modify
snap/cmd/snaptel/flags.go
:and change default timeout value of 10 seconds to zero.
The text was updated successfully, but these errors were encountered: