ITADN

cancelling queries

#304Closedrutchkiwi 创建于 2025-07-21
R
rutchkiwicommented
Hi. My webserver, has a timeout of 30 seconds, enforced by heroku. So if a query takes longer than that, the user won't see the response anyways. So I was thinking to build something with futures, where after 30sec the future is cancelled. See [this issue I made on my ring adapter](https://github.com/luminus-framework/ring-undertow-adapter/issues/36#issuecomment-3063411113). However, I think that this wouldn't really work for jdbc, as the driver would need to catch InterruptedException and then call .cancel on the query. Would there be any way to make this work? I might also be confused and it would actually work, but I'd like to get this confirmed. Thanks!
关闭于 2025-07-22 9 条评论