We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 489 chaosii 20 0 1110252 17164 12524 S 54.2 0.1 1:38.45 background_work
The text was updated successfully, but these errors were encountered:
I had try change the parameters, but wasn't work.
package main import ( "fmt" "github.com/benmanns/goworker" "log" "sso-api/config" "strconv" ) //func myFunc(queue string, args ...interface{}) error { // log.Printf("From %s, %v\n", queue, args) // return nil //} func callbackUrl(queue string, args ...interface{}) error { log.Printf("From %s, %v\n", queue, args) return nil } func init() { _ = goworker.Init() settings := goworker.WorkerSettings{ URI: config.Goworker.GoworkerRedisUri, Connections: 50, Queues: []string{config.Goworker.GoworkerQueueName}, UseNumber: true, ExitOnComplete: false, Concurrency: 2, Namespace: config.Goworker.GoworkerNamespace, Interval: 1000000000, } goworker.SetSettings(settings) //goworker.Register("MyClass", myFunc) goworker.Register("Callback", callbackUrl) } func main() { if err := goworker.Work(); err != nil { fmt.Println("Error:", err) } }
Sorry, something went wrong.
@chaos0108 Please use IntervalFloat instead of Interval, because it set Interval by IntervalFloat in Init(). And the unit of IntervalFloat is Second.
IntervalFloat
Interval
Second
No branches or pull requests
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
489 chaosii 20 0 1110252 17164 12524 S 54.2 0.1 1:38.45 background_work
The text was updated successfully, but these errors were encountered: