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

Support context #22

Closed
kardianos opened this issue Apr 4, 2017 · 1 comment
Closed

Support context #22

kardianos opened this issue Apr 4, 2017 · 1 comment

Comments

@kardianos
Copy link

If you use the context.Context methods that database/sql provides, you can allow the user to cancel in-flight queries or transactions in your user-interface.

@kenshaw
Copy link
Member

kenshaw commented Apr 5, 2017

Yup, aware of what could be done, and yeah it would be a relatively small change. I just haven't had a chance to do the work. The other issue is at the moment I'm not using separate Goroutines. In order to do this, at minimum the query/execution stuff would have to be put into a separate routine, and then something would have to be done to "intercept" the SIG from the OS or the readline package that is being used. Also, note, this would only work when built with Go1.8 (which is perfectly fine requirement -- just pointing it out).

@kenshaw kenshaw closed this as completed Jan 6, 2021
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

2 participants