Bug #113561 MySql .NET connector is no longer recognized by DbProviderFactories
Submitted: 4 Jan 2024 19:10 Modified: 24 Jan 19:53
Reporter: Matthew Binsfeld Email Updates:
Status: Not a Bug Impact on me:
None 
Category:Connector / NET Severity:S3 (Non-critical)
Version:8.0.32+ OS:Windows (.NET Framework 4.8)
Assigned to: CPU Architecture:Any

[4 Jan 2024 19:10] Matthew Binsfeld
Description:
In our application we load in Db connectors via .NET's DbProviderFactories.  We haven't had any issues with MySql .NET connectors previous to version 8.0.32.  With 8.0.32 and beyond, the installer no longer asks if you want Typical, Custom, etc for the install and just proceeds to install it (I'm sure this is intended but since this came to be it has caused issues for us).  With versions 8.0.32+, DbProviderFactories no longer recognizes the MySql connector.  I've included definitions in the app config and such but to no avail.  I've tried everything I've found online but nothing has worked.  Here is a StackOverflow question that highlights the issue more specifically:

https://stackoverflow.com/questions/76807243/dbproviderfactories-getfactoryclasses-does-no...

A fix or any help would be greatly appreciated as we are stuck using old versions of the connector as they are the only ones that work and our customers are wanting to use new connector versions.

How to repeat:
Please note this applies to .NET Framework (ie .NET Framework 4.8) not .NET (ie .NET 5+) or .NET Core

1) Install version 8.0.32 or any version newer of the MySql .net connector.
2) Attempt to get the connector via DbProviderFactories in C#/.net
3) Notice MySql doesn't appear as an installed connector.

Suggested fix:
Ensure compatibility with .NET Framework. It is a completely separate product from .NET.
[4 Jan 2024 21:53] Matthew Binsfeld
A small example showing the problem

Attachment: DbProviderTestFiles.zip (application/x-zip-compressed, text), 24.65 KiB.

[5 Jan 2024 8:59] MySQL Verification Team
Hello Matthew Binsfeld,

Thank you for the report and feedback.

regards,
Umesh
[6 Jan 2024 3:05] Bradley Grainger
Duplicate of bug #112091.
[9 Jan 2024 17:25] Matthew Binsfeld
Hi Bradley,
I'd like to point out even #112091 is the same thing it was closed as can't reproduce (I believe because it was being tested against .NET or .NET Core rather than .NET Framework), but this bug has already been verified.
Thanks,
Matt
[24 Jan 17:05] Omar Chavez
Posted by developer:
 
Rejected,
Tested with Connector/NET 9.2.0 using .NET Framework 4.8 and can't reproduce
[24 Jan 19:53] Matthew Binsfeld
Thanks Omar, looks like it was fixed sometime between 9.2.0 and 8.0.32 where I reported. I am also unable to reproduce this with 9.2.0.