MySqlConnector
MySqlConnector copied to clipboard
Add UseProcedureCache option and documentation. Fixes #1175
@bgrainger What do you think about this changes. This is implementation for second idea in #1175 issue.
Currently without tests.
The connection string changes look fine.
I think the change to FillAsync isn't appropriate, as we do actually want CachedProcedure information for AlignParamsWithDb later on. Instead, we might want to make ConnectionPool.GetProcedureCache return null if procedure caching is disabled. But even then we wouldn't want to cache the procedure (even on the MySqlConnection) beyond the lifetime of the ExecuteXyz call. (And we would also need to update logging so it doesn't log incorrect messages about what is happening.)
Sorry I don't have more specific guidance yet; I haven't looked into the details of how to solve this problem.
@bgrainger I took a closer look at the places where parameter caching is used for procedures and made some changes. If you have time, please look at additional edits to support this feature.