quarkiverse / quarkus-mybatis

Quarkus MyBatis Extension
Apache License 2.0
88 stars 33 forks source link

add configuration of the maximum sql execution time #348

Open zuochangqin opened 11 months ago

zuochangqin commented 11 months ago

Since this extension does not support reaction, I can only use multiple threads to operate the data. However, in the process of use, sometimes due to database problems, the operation is stuck and will not return for a long time, which will cause the thread execution time to exceed the maximum allowed time of quarkus thread, resulting in some unexpected errors. May I ask if there is any configuration that can control this sql execution return time? For example, after a certain period of time, directly throw an exception, you can know that there is a problem with the execution, so that you can retry.

zhfeng commented 11 months ago

Well, I think it could take some configurations on the jdbc level, such as a timeout?