Bug #119774 MySQL.EntityFrameworkCore ignores command timeout settings and causes permanent blocking after long lock periods.
Submitted: 26 Jan 2:28
Reporter: zw zhang Email Updates:
Status: Open Impact on me:
None 
Category:Connector / NET Severity:S2 (Serious)
Version:9.0.11 OS:Windows (10)
Assigned to: CPU Architecture:x86 (64)
Tags: EntityFrameworkCore

[26 Jan 2:28] zw zhang
Description:
Two critical issues exist in MySQL.EntityFrameworkCore:

The driver does not honor configured SQL command timeouts (e.g., 30 seconds). Operations hang indefinitely instead of throwing a timeout exception.

When a transaction holds a lock for about 70+ seconds, any concurrent transaction waiting for that lock becomes permanently stuck. The waiting transaction never proceeds, times out, or releases its connection—leaving it in an unrecoverable state.

How to repeat:
Configure an EF Core application with MySQL.EntityFrameworkCore and set command timeout to 30 seconds.

Create two concurrent transactions: Transaction A updates a record and holds the lock for 75+ seconds; Transaction B attempts to update the same record.

Observe that Transaction B neither times out after 30 seconds nor proceeds after Transaction A releases the lock, instead becoming permanently stuck.

Verify the connection remains stuck using SHOW PROCESSLIST; and note that timeout configurations are ignored.

A complete reproduction demo is available at: https://github.com/zhangzw218/MySql.EntityFrameworkCore.Deadlock.Timeout.Demo