Issue Details (XML | Word | Printable)

Key: DNET-854
Type: Task Task
Status: Resolved Resolved
Resolution: Fixed
Priority: Minor Minor
Assignee: Jiri Cincura
Reporter: Jiri Cincura
Votes: 0
Watchers: 0

If you were logged in you would be able to see more operations.
.NET Data provider

Investigate option to remove weak references for FbCommands in connection to be able to properly track everything

Created: 04/Oct/18 08:41 AM   Updated: 08/Oct/18 09:12 AM
Component/s: ADO.NET Provider
Affects Version/s:
Fix Version/s:

 Description  « Hide
Importantly how one FbCommand would play in prepared statements when used in multiple FbConnections.

 All   Comments   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Jiri Cincura added a comment - 08/Oct/18 09:11 AM
I think with the recent finalizers cleanup (DNET-698) the weak reference doesn't make sense. There's no code that would release the statement in finalizer on server side, so it was just a collection. I'm changing it to regular reference and hence even if the command is no disposed (fail #1) it's going to be disposed when the connection is closed (or returned to pool). This does not prevent shooting yourself into foot, but except for edge cases it's good enough.