Skip to content

Microsoft.Data.SqlClient is not compatible with AssemblyLoadContext unloading #31377

@AlbertoCe

Description

@AlbertoCe

Hello,

when I load a plugin that uses EntityFrameworkCore (using a custom collectible AssemblyLoadContext) and try to unload it, it does not get unloaded: the IsActive property of the context's weakreference remain true even after multiple GC.Collect() and GC.WaitForPendingFinalizers().

It works well if I comment out all the EntityFrameworkCore related code from the plugin.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    No status

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions