You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In some places, we use queryMapper not only for IQueryable mappings, but also for in-memory data mappings from one model to another.
The library provides one method to do this. public virtual List<TTo> Map<TFrom, TTo>(List<TFrom> models, string? name = null)
However, when we start using this method for large collections, this method takes a very long time to execute.
I analyzed this code a little and the problem is that the mapping is performed for each element of the collection separately and not for the entire collection at once.
Need to change this logic to improve performance.
The text was updated successfully, but these errors were encountered:
1Nixx
changed the title
Performance issue for List mappings
Performance issue with List mapping
Aug 18, 2024
In some places, we use queryMapper not only for IQueryable mappings, but also for in-memory data mappings from one model to another.
The library provides one method to do this.
public virtual List<TTo> Map<TFrom, TTo>(List<TFrom> models, string? name = null)
However, when we start using this method for large collections, this method takes a very long time to execute.
I analyzed this code a little and the problem is that the mapping is performed for each element of the collection separately and not for the entire collection at once.
Need to change this logic to improve performance.
The text was updated successfully, but these errors were encountered: