Re: Cancel threads after timeout

Discussion in 'Python' started by Jason Friedman, Jan 26, 2013.

  1. > Sometimes it happens that a query on one of the database servers
    > takes longer than expected and impedes the generation of this report
    > (that's right, the queries are ran sequential). What I am trying to
    > achieve is to parallelize the queries on each database server and to be
    > able to cancel one of them if it takes longer than X minutes.


    Only answering a small portion of your question ....
    Assuming you are able to figure out how to "cancel" a thread or
    process on your side, it is possible the database itself will not
    respect that. In other words, if you execute "SELECT ..." singly,
    outside of Python, and type CNTL-C, does your database quickly
    recognize you are no longer interested in the result set and stop its
    work?
    Jason Friedman, Jan 26, 2013
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. hyperboreean

    Cancel threads after timeout

    hyperboreean, Jan 26, 2013, in forum: Python
    Replies:
    0
    Views:
    118
    hyperboreean
    Jan 26, 2013
  2. Matt Jones

    Re: Cancel threads after timeout

    Matt Jones, Jan 26, 2013, in forum: Python
    Replies:
    0
    Views:
    117
    Matt Jones
    Jan 26, 2013
  3. Cameron Simpson

    Re: Cancel threads after timeout

    Cameron Simpson, Jan 27, 2013, in forum: Python
    Replies:
    0
    Views:
    120
    Cameron Simpson
    Jan 27, 2013
  4. dieter
    Replies:
    0
    Views:
    133
    dieter
    Jan 27, 2013
  5. Jason Ma

    Re: Cancel threads after timeout

    Jason Ma, Jan 27, 2013, in forum: Python
    Replies:
    0
    Views:
    129
    Jason Ma
    Jan 27, 2013
Loading...

Share This Page