Skip to content
New issue

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

Goroutine leak or never stop #81

Closed
Petelin opened this issue Jan 17, 2018 · 1 comment
Closed

Goroutine leak or never stop #81

Petelin opened this issue Jan 17, 2018 · 1 comment

Comments

@Petelin
Copy link

Petelin commented Jan 17, 2018

i am new with hystrix, but shouldn't have a hard timeout limit? i read the code, when time is up it just return timeout err, but the real job is running in another goroutine and may be never be stoped. am i right with this?should it be solve?

	hystrix.Go("test_name", func() error {
		for{
			log.Println("hello hystrix")
			time.Sleep(time.Microsecond * 100)
		}
		return errors.New("test return err")
	}, func(e error) error {
		log.Println("ops~ got err!", e)
		return errors.New("second error")
	})
@Petelin
Copy link
Author

Petelin commented Jan 22, 2018

i seems we should do this by ourself. there is no safe way to close a goroutine.

@Petelin Petelin closed this as completed Dec 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant