Global Data Management Forum

 View Only
Expand all | Collapse all

.net8 / EFcore8 support?

  • 1.  .net8 / EFcore8 support?

    Posted Wed October 11, 2023 08:13 AM
    Edited by Torben Hørup Wed October 11, 2023 08:13 AM

    net8 -rc2 was released yesterday -and theres roughly a month until net8 is GA, but still we havent heard or seen anything in regards to DB2 support for .net/efcore 8

    Will we repeat the pattern from net7 where 5 months went by until you were ready to support it ?



    ------------------------------
    Torben Hørup
    ------------------------------



  • 2.  RE: .net8 / EFcore8 support?

    Posted Thu October 12, 2023 01:43 AM

    Hi Torben,

       we are working on it and we plan to release the support for .NET 8 first and then support for EF Core 8. Since there will be many changes in MS EF layer, it is some effort for us to make it work for multiple database servers. The usual timeline is within 3 months from release of MS EF support. 

    Thanks

    Vishwa



    ------------------------------
    Hosathota Vishwanatha
    ------------------------------



  • 3.  RE: .net8 / EFcore8 support?

    Posted Tue December 12, 2023 06:19 PM

    Eagerly awaiting .net 8.0 support. Is there a thread or blog or something I should monitor to get a release notification?



    ------------------------------
    Mr O.
    ------------------------------



  • 4.  RE: .net8 / EFcore8 support?

    Posted Thu January 04, 2024 10:18 AM

    Hi,

    I'm also waiting for a .NET Core 8 working DB2Connection et.al.   Currently getting a 58017 error with the .Core NuGet Package.  

    btw. I'm upgrading and old app from .net 4 to Core 8.   I need both versions of the drivers to run on the same machine.  I'm keeping my fingers crossed that this will be possible.

    Thanks you



    ------------------------------
    Douglas Lawrence
    ------------------------------



  • 5.  RE: .net8 / EFcore8 support?

    Posted Wed February 07, 2024 07:36 AM

    The new version 8.0.0.100 of IBM.EntityFrameworkCore is available. Unfortunately, it results in an error on a simple select statement.

    System.ArgumentNullException
      HResult=0x80004003
      Message=Value cannot be null. Arg_ParamName_Name
      Source=Microsoft.Extensions.Logging.Abstractions
      StackTrace:
       at System.ThrowHelper.Throw(String paramName)
       at Microsoft.Extensions.Logging.LogValuesFormatter..ctor(String format)
       at Microsoft.Extensions.Logging.LoggerMessage.CreateLogValuesFormatter(String formatString, Int32 expectedNamedParameterCount)
       at Microsoft.Extensions.Logging.LoggerMessage.Define[T1,T2](LogLevel logLevel, EventId eventId, String formatString, LogDefineOptions options)
       at Microsoft.Extensions.Logging.LoggerMessage.Define[T1,T2](LogLevel logLevel, EventId eventId, String formatString)
       at IBM.EntityFrameworkCore.Internal.Db2Strings.<>c.<LogDecimalTypeKey>b__21_1(LogLevel level)
       at Microsoft.EntityFrameworkCore.Diagnostics.EventDefinition`2..ctor(ILoggingOptions loggingOptions, EventId eventId, LogLevel level, String eventIdCode, Func`2 logActionFunc)
       at IBM.EntityFrameworkCore.Internal.Db2Strings.<>c__DisplayClass21_0.<LogDecimalTypeKey>b__0()
       at System.Threading.LazyInitializer.EnsureInitializedCore[T](T& target, Func`1 valueFactory)
       at IBM.EntityFrameworkCore.Internal.Db2Strings.LogDecimalTypeKey(IDiagnosticsLogger logger)
       at IBM.EntityFrameworkCore.Internal.Db2LoggerExtensions.DecimalTypeKeyWarning(IDiagnosticsLogger`1 diagnostics, IProperty property)
       at IBM.EntityFrameworkCore.Infrastructure.Internal.Db2ModelValidator.ValidateDecimalColumns(IModel model, IDiagnosticsLogger`1 logger)
       at IBM.EntityFrameworkCore.Infrastructure.Internal.Db2ModelValidator.Validate(IModel model, IDiagnosticsLogger`1 logger)
       at Microsoft.EntityFrameworkCore.Infrastructure.ModelRuntimeInitializer.Initialize(IModel model, Boolean designTime, IDiagnosticsLogger`1 validationLogger)
       at Microsoft.EntityFrameworkCore.Infrastructure.ModelSource.GetModel(DbContext context, ModelCreationDependencies modelCreationDependencies, Boolean designTime)
       at Microsoft.EntityFrameworkCore.Internal.DbContextServices.CreateModel(Boolean designTime)
       at Microsoft.EntityFrameworkCore.Internal.DbContextServices.get_Model()
       at Microsoft.EntityFrameworkCore.DbContext.get_Model()
       at Microsoft.EntityFrameworkCore.Internal.InternalDbSet`1.get_EntityType()
       at Microsoft.EntityFrameworkCore.Internal.InternalDbSet`1.CheckState()
       at Microsoft.EntityFrameworkCore.Internal.InternalDbSet`1.get_EntityQueryable()
       at Microsoft.EntityFrameworkCore.Internal.InternalDbSet`1.System.Linq.IQueryable.get_Provider()
       at System.Linq.Queryable.Where[TSource](IQueryable`1 source, Expression`1 predicate)



    ------------------------------
    Robert van der Doelen
    ------------------------------



  • 6.  RE: .net8 / EFcore8 support?

    Posted Fri March 01, 2024 09:24 AM

    I, too, would love some sort of notification about EF Core library releases, and more transparency about roadmaps, rather than needing to search for forum posts like this. 😊 Our credit union eagerly awaits the release.

    Also: preview versions would be 



    ------------------------------
    Samantha Hobbs
    ------------------------------



  • 7.  RE: .net8 / EFcore8 support?

    Posted Fri March 01, 2024 09:24 AM

    Bug report: the `dotnet ef dbcontext optimize` command (i.e., creating compiled models for performance) does not work with v8. (It did work for v7.)

    Looks like a missing default property that EF Core expects the driver to have implemented.

    Please see if you can fix soon. We rely on that object pre-compilation for a meaningful startup performance boost. Thank you.

    Here's a dump of the command-line error:

    PS > dotnet ef dbcontext optimize -c MyDb2Context
    Build started...
    Build succeeded.
    System.InvalidOperationException: The type mapping used is incompatible with a compiled model. The mapping type must have a 'public static readonly Db2StringTypeMapping Db2StringTypeMapping.Default' property.
       at Microsoft.EntityFrameworkCore.Design.Internal.CSharpRuntimeAnnotationCodeGenerator.CreateDefaultTypeMapping(CoreTypeMapping typeMapping, CSharpRuntimeAnnotationCodeGeneratorParameters parameters)
       at Microsoft.EntityFrameworkCore.Design.Internal.RelationalCSharpRuntimeAnnotationCodeGenerator.Create(CoreTypeMapping typeMapping, CSharpRuntimeAnnotationCodeGeneratorParameters parameters, ValueComparer valueComparer, ValueComparer keyValueComparer, ValueComparer providerValueComparer)
       at Microsoft.EntityFrameworkCore.Design.Internal.ICSharpRuntimeAnnotationCodeGenerator.Create(CoreTypeMapping typeMapping, IProperty property, CSharpRuntimeAnnotationCodeGeneratorParameters parameters)
       at Microsoft.EntityFrameworkCore.Scaffolding.Internal.CSharpRuntimeModelCodeGenerator.Create(IProperty property, String variableName, Dictionary`2 propertyVariables, CSharpRuntimeAnnotationCodeGeneratorParameters parameters)
       at Microsoft.EntityFrameworkCore.Scaffolding.Internal.CSharpRuntimeModelCodeGenerator.Create(IProperty property, Dictionary`2 propertyVariables, CSharpRuntimeAnnotationCodeGeneratorParameters parameters)
       at Microsoft.EntityFrameworkCore.Scaffolding.Internal.CSharpRuntimeModelCodeGenerator.CreateEntityType(IEntityType entityType, IndentedStringBuilder mainBuilder, IndentedStringBuilder methodBuilder, SortedSet`1 namespaces, String className, Boolean nullable)
       at Microsoft.EntityFrameworkCore.Scaffolding.Internal.CSharpRuntimeModelCodeGenerator.GenerateEntityType(IEntityType entityType, String namespace, String className, Boolean nullable)
       at Microsoft.EntityFrameworkCore.Scaffolding.Internal.CSharpRuntimeModelCodeGenerator.GenerateModel(IModel model, CompiledModelCodeGenerationdelCodeGenerator.GdelCodeGenerator.GenerateModel(IModel model,delCodeGenerator.GenerateModel(IModel model, CompiledMdelCodeGenerator.GenerateModel(IModedelCodeGenerator.GenerateModel(IModel model, CompiledModelCodeGenerationOptions options)delCodeGdededededededelCodeGenerator.GenerateModel(IModel model, CompiledModelCodeGenerationOptions options)
       at Microsoft.EntityFrameworkCore.Scaffolding.Internal.CompiledModelScaffolder.ScaffoldModel(IModel model, String outputDir, CompiledModelCodeGenerationOptions options)
       at Microsoft.EntityFrameworkCore.Design.Internal.DbContextOperations.Optimize(String outputDir, String modelNamespace, String contextTypeName)
       at Microsoft.EntityFrameworkCore.Design.OperationExecutor.OptimizeContextImpl(String outputDir, String modelNamespace, String contextType)
       at Microsoft.EntityFrameworkCore.Design.OperationExecutor.OptimizeContext.<>c__DisplayClass0_0.<.ctor>b__0()
       at Microsoft.EntityFrameworkCore.Design.OperationExecutor.OperationBase.Execute(Action action)
    The type mapping used is incompatible with a compiled model. The mapping type must have a 'public static readonly Db2StringTypeMapping Db2StringTypeMapping.Default' property.



    ------------------------------
    Samantha Hobbs
    ------------------------------



  • 8.  RE: .net8 / EFcore8 support?

    Posted Fri March 29, 2024 07:14 AM

    Hi Samantha,

    Sorry for delay in response, We have reproduced the issue and it will be fixed in our future release.
    If you want to expedite the process, please reach out to IBM Support team to open a case...

    Warm Regards,

    Archana



    ------------------------------
    Archana Soni
    ------------------------------



  • 9.  RE: .net8 / EFcore8 support?

    Posted Fri January 05, 2024 09:01 AM

    Unfortunately IBM is always months behind almost every other database provider on releasing .NET tools. 



    ------------------------------
    Jeremy Bowling
    ------------------------------



  • 10.  RE: .net8 / EFcore8 support?

    Posted Mon February 05, 2024 09:30 PM

    Version 8.0.0.100 of IBM.EntityFrameworkCore is here. Unfortunately, it does not work. It crashes on simple select statement.

    Verion 7.0.0.300 works just fine on following statement.

    decimal itm = await (from data in db.F4101 where data.Imsrtx.Equals(sku) select data.Imitm).FirstOrDefaultAsync();

    this statement produces this error:

    System.ArgumentNullException: Value cannot be null. (Parameter 'format')

       at System.ThrowHelper.Throw(String paramName)

       at Microsoft.Extensions.Logging.LogValuesFormatter..ctor(String format)

       at Microsoft.Extensions.Logging.LoggerMessage.CreateLogValuesFormatter(String formatString, Int32 expectedNamedParameterCount)

       at Microsoft.Extensions.Logging.LoggerMessage.Define[T1,T2](LogLevel logLevel, EventId eventId, String formatString, LogDefineOptions options)

       at Microsoft.Extensions.Logging.LoggerMessage.Define[T1,T2](LogLevel logLevel, EventId eventId, String formatString)

       at IBM.EntityFrameworkCore.Internal.Db2Strings.<>c.<LogDecimalTypeKey>b__21_1(LogLevel level)

       at Microsoft.EntityFrameworkCore.Diagnostics.EventDefinition`2..ctor(ILoggingOptions loggingOptions, EventId eventId, LogLevel level, String eventIdCode, Func`2 logActionFunc)

       at IBM.EntityFrameworkCore.Internal.Db2Strings.<>c__DisplayClass21_0.<LogDecimalTypeKey>b__0()

       at System.Threading.LazyInitializer.EnsureInitializedCore[T](T& target, Func`1 valueFactory)

       at IBM.EntityFrameworkCore.Internal.Db2Strings.LogDecimalTypeKey(IDiagnosticsLogger logger)

       at IBM.EntityFrameworkCore.Internal.Db2LoggerExtensions.DecimalTypeKeyWarning(IDiagnosticsLogger`1 diagnostics, IProperty property)

       at IBM.EntityFrameworkCore.Infrastructure.Internal.Db2ModelValidator.ValidateDecimalColumns(IModel model, IDiagnosticsLogger`1 logger)

       at IBM.EntityFrameworkCore.Infrastructure.Internal.Db2ModelValidator.Validate(IModel model, IDiagnosticsLogger`1 logger)

       at Microsoft.EntityFrameworkCore.Infrastructure.ModelRuntimeInitializer.Initialize(IModel model, Boolean designTime, IDiagnosticsLogger`1 validationLogger)

       at Microsoft.EntityFrameworkCore.Infrastructure.ModelSource.GetModel(DbContext context, ModelCreationDependencies modelCreationDependencies, Boolean designTime)

       at Microsoft.EntityFrameworkCore.Internal.DbContextServices.CreateModel(Boolean designTime)

       at Microsoft.EntityFrameworkCore.Internal.DbContextServices.get_Model()

       at Microsoft.EntityFrameworkCore.Infrastructure.EntityFrameworkServicesBuilder.<>c.<TryAddCoreServices>b__8_4(IServiceProvider p)

       at ResolveService(ILEmitResolverBuilderRuntimeContext, ServiceProviderEngineScope)

       at ResolveService(ILEmitResolverBuilderRuntimeContext, ServiceProviderEngineScope)

       at ResolveService(ILEmitResolverBuilderRuntimeContext, ServiceProviderEngineScope)

       at ResolveService(ILEmitResolverBuilderRuntimeContext, ServiceProviderEngineScope)

       at ResolveService(ILEmitResolverBuilderRuntimeContext, ServiceProviderEngineScope)

       at ResolveService(ILEmitResolverBuilderRuntimeContext, ServiceProviderEngineScope)

       at Microsoft.Extensions.DependencyInjection.ServiceProvider.GetService(ServiceIdentifier serviceIdentifier, ServiceProviderEngineScope serviceProviderEngineScope)

       at Microsoft.Extensions.DependencyInjection.ServiceLookup.ServiceProviderEngineScope.GetService(Type serviceType)

       at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService(IServiceProvider provider, Type serviceType)

       at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService[T](IServiceProvider provider)

       at Microsoft.EntityFrameworkCore.DbContext.get_DbContextDependencies()

       at Microsoft.EntityFrameworkCore.DbContext.get_ContextServices()

       at Microsoft.EntityFrameworkCore.DbContext.get_Model()

       at Microsoft.EntityFrameworkCore.Internal.InternalDbSet`1.get_EntityType()

       at Microsoft.EntityFrameworkCore.Internal.InternalDbSet`1.CheckState()

       at Microsoft.EntityFrameworkCore.Internal.InternalDbSet`1.get_EntityQueryable()

       at Microsoft.EntityFrameworkCore.Internal.InternalDbSet`1.System.Linq.IQueryable.get_Provider()

       at System.Linq.Queryable.Where[TSource](IQueryable`1 source, Expression`1 predicate)



    ------------------------------
    Peter Czurak
    ------------------------------



  • 11.  RE: .net8 / EFcore8 support?

    Posted Tue February 06, 2024 03:46 AM

    Every statement we make produces the same error.

    System.ArgumentNullException: Value cannot be null. (Parameter 'format')

    Version 8.0.0.100 of IBM.EntityFrameworkCore does not work.



    ------------------------------
    Wim Baens
    ------------------------------



  • 12.  RE: .net8 / EFcore8 support?

    Posted Wed February 07, 2024 10:41 AM
    Edited by Mr O. Wed February 07, 2024 10:41 AM

    Did you open a support case so they can get it fixed?

    It is odd, just last week I opened support case to see when .NET Core 8 would be released and they said to check back in a couple months, and then all of a sudden it appeared. It seems the different departments at IBM are not talking to each other.




  • 13.  RE: .net8 / EFcore8 support?

    Posted Fri February 09, 2024 05:13 AM

    Unfortunately I don't have the rights to open support cases.

    IBM just doesn't care about the customers, after this year we are completely switched over to SQL or Oracle.



    ------------------------------
    Wim Baens
    ------------------------------



  • 14.  RE: .net8 / EFcore8 support?

    Posted Mon February 12, 2024 03:59 AM

    Hi Wim,

      you may want to try the latest versions 8.0.0.200 and let us know if you still face any issues and we are happy to help you. I am not sure why you do not have rights to open a case with IBM.

    Thanks

    Vishwa



    ------------------------------
    Vishwanatha Hosathota
    ------------------------------



  • 15.  RE: .net8 / EFcore8 support?

    Posted Tue February 13, 2024 03:04 AM

    The 8.0.0.200 version seems to work, thank you for the swift solution.

    I use my own account for interactions, the licenses are on an old account that I cannot access myself.

    Thanks for the help though.



    ------------------------------
    Wim Baens
    ------------------------------