Skip to Main Content

ODP.NET

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ToListAsync became blocking and synchronous from Version 23.4.0

Marius BergerAug 7 2025

Using .NET 4.8.1., an oracle database, Oracle.ManagedDataAccess [21.19.0 or lower down to 21.4.0] and Oracle.ManagedDataAccess.EntityFramework [21.19.0 or lower down to 21.4.0] the following function works [probably] “async” and just great:

private async Task<List<NumberVersionsIdsTuple>> GetAllOPSChaptersAsync()

{

List<NumberVersionsIdsTuple> result = new List<NumberVersionsIdsTuple>(); try { using (var repository = new Repository<ChapterDataRecord, OracleDbContext>()) { result = await repository.GetQueryable() .GroupBy(x => new { Number = x.Number }) .OrderBy(x => x.Key.Number) .Select(x => new NumberVersionsIdsTuple() { Number = x.Key.Number, Versions = x.Select(j => j.Version), Identifiers = x.Select(y => y.Id) }) .ToListAsync(); } } catch (Exception ex) { Logger.Error($"Error on loading chapters.", ex); } return result; }

NumberVersionTuple ist just some POCO

    `public class NumberVersionsIdsTuple : IVersionable     {         public int Number { get; set; } = default;         public string DisplayMember { get { return $"{Number}"; } }         public IEnumerable<int> Versions { get; set; }         public IEnumerable<long> Identifiers { get; set; }        }`

ChapterDataRecord is a DataRecord [DbSet] and OracleDbContext the DBContext for Registering to database, table and so on (Entity Framework code first stuff)

Everything works just fine, as long we use the above mentioned version numbers.

As soon I update through nuget store to the latest Oracle.ManagedDataAccess (23.9.1) or even only Oracle.ManagedDataAccess.EntityFramework (23.9.1) the async await or ToListAsyncblocks my UI and the whole application becomes freezing. Had to downgrade.

This function (as other async functions) is used during the init process and it is blocking now the whole application.

When I change all functions to synchrnous ToList and without await, async, everything works.

But this is not the purpose for using asynchronous functions.

Comments
Post Details
Added on Aug 7 2025
11 comments
87 views