Reputation: 566
What happens when the Azure Sql server dtu exceed the limit?
I am facing the below issue, not sure if this is due to high DTU usage?
I have a spring batch application that uses Azure SQL server, it runs without any issues and updates the Database for a most part however I am getting the following error occasionally
2021-10-04T14:29:17,685 [SimpleAsyncTaskExecutor-1] WARN SqlExceptionHelper: SQL Error: 0, SQLState: 08S01
2021-10-04T14:29:17,685 [SimpleAsyncTaskExecutor-1] ERROR SqlExceptionHelper: SQL Server did not return a response. The connection has been closed.
2021-10-04T14:29:17,686 [SimpleAsyncTaskExecutor-1] ERROR TaskletStep: Rolling back with transaction in unknown state
2021-10-04T14:29:17,687 [SimpleAsyncTaskExecutor-1] ERROR TransactionTemplate: Application exception overridden by rollback exception
org.hibernate.exception.JDBCConnectionException: could not extract ResultSet
at org.hibernate.exception.internal.SQLStateConversionDelegate.convert(SQLStateConversionDelegate.java:115
Upvotes: 2
Views: 1152
Reputation: 5034
This appears to be more of a spring and hibernate related implementation error than an issue with SQL. A rollback seems to be unsuccessful, there can be uncaught exceptions over which spring attempting to rollback, however, usually it doesn't rollback for unchecked exceptions. This is when that transaction might just timeout! Hibernate tries to rollback transaction but spring doesn't cause it cannot find an exception and continues with commit but commit fails cause Hibernate marked this transaction for only rollback.
Recheck for JDBC - jar version mismatch, else you need to have an exception handler to fix this. Use an attributes of @Transactional
annotation to prevent from rolling back. checkout Interactions Between Batching and Transaction Propagation
I am facing the below issue, not sure if this is due to high DTU usage?
if this was related to resource limitations, you would see the exceptions meassage clearly indicating the same Resource governance errors You can check for DTU quota from sql server settings.
Upvotes: 1