Hi Venkat,
Right now, there is only a possibility of setting the JDBC timeout on
org.jooq.Query, not on org.jooq.Routine. I have registered an issue to
implement such a feature:
https://github.com/jOOQ/jOOQ/issues/3892
Note though, that you can modify the CallableStatement that is about to be
executed via the ExecuteListener.prepareEnd() event. Something along these
lines:
@Override
public void prepareEnd(ExecuteContext ctx) {
super.prepareEnd(ctx);
try {
if (ctx.routine() != null)
ctx.statement().setQueryTimeout(10);
}
catch (SQLException e) {
throw new DataAccessException("Error while setting the query
timeout", e);
}
}
Hope this helps,
Lukas
2014-12-30 17:47 GMT+01:00 Venkat Sadasivam <[email protected]>:
> Are there a way to specify timeout when executing stored procedure through
> jOOQ API?
>
> --
> You received this message because you are subscribed to the Google Groups
> "jOOQ User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>
--
You received this message because you are subscribed to the Google Groups "jOOQ
User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.