Good evening, to be noted that I have already addressed this issue, researching, testing, msdn forum, but have not managed to solve. (View pre-generated, ngen)
I state that I am doing tests in a fairly fast machine (ssd, 16gb ram i7overclock) then on a customer's machine time can only increase.
the problem is the classic startup ef, loses in my opinion too much time (in my pc about 30 seconds). So when the customer opens my application has to wait 30+ seconds, obviously there is a splashcreen with barprogress endless, before accessing the menu and the dashboard, sql server utilization, ef 6.1.3 first code, manual migration, wpf mvvm.
The db is composed of about 330 tables including 60/70 entity with one to many relationship.
Add the SednaContex link (to understand the structure of my db):
SednaCOntext
When I start my application I do I make a model check to see if there have been changes, in which case you migrate.Most of the time I just lose them ... after I make a dummy query (query cold) to make sure, that when User (finally) comes in, which ones will not have to freeze when feelings will make the first query.
Now I wanted to see if there is something wrong in my implementation, if there are other methods, or implementations to solve the problem, because I think there are around made software with ef and above all much larger than this ... I hope someone can help me because this problem is lho a long time but I ignored it, but now has become of primary importance
I created a console program to get a better idea where to video releases me of the time it takes to compare the model and the cold query
Example
I tried also with ngen I post a screenshot where you see the result, the creations of all the .dll with ngen, and through windows process verification using native images, but the result has not changed:
ScreenShot ngen
As for the pre-generated view with vs 2015 I did not do them because I f are from a compilation error of a path too long, I read that with the new compiler is rosylin this limitation but do not know ....
I state that I am doing tests in a fairly fast machine (ssd, 16gb ram i7overclock) then on a customer's machine time can only increase.
the problem is the classic startup ef, loses in my opinion too much time (in my pc about 30 seconds). So when the customer opens my application has to wait 30+ seconds, obviously there is a splashcreen with barprogress endless, before accessing the menu and the dashboard, sql server utilization, ef 6.1.3 first code, manual migration, wpf mvvm.
The db is composed of about 330 tables including 60/70 entity with one to many relationship.
Add the SednaContex link (to understand the structure of my db):
SednaCOntext
When I start my application I do I make a model check to see if there have been changes, in which case you migrate.Most of the time I just lose them ... after I make a dummy query (query cold) to make sure, that when User (finally) comes in, which ones will not have to freeze when feelings will make the first query.
**************Compatible******************
var sednaContext = new SednaContext(dbHelper.CreateConnectionString(Ditta, ditte?.DirectoryDitta));
var compatibleWithModel = sednaContext.Database.CompatibleWithModel(true);
if (!compatibleWithModel)
{
var result = RunMigrations();
}
*******Fine Compatible: 14987ms***
**************ColdQuery******************
var datiDitta = datiDittaRepository.Prendi(string.Empty);//coldquery
********Fine Cold Query: 13748ms******
As you can see in this example, I added the time it is going to run, only these two operations about 28 seconds + more seconds to load the menu and the MAINVIEW, but few seconds so it's not important.Now I wanted to see if there is something wrong in my implementation, if there are other methods, or implementations to solve the problem, because I think there are around made software with ef and above all much larger than this ... I hope someone can help me because this problem is lho a long time but I ignored it, but now has become of primary importance
I created a console program to get a better idea where to video releases me of the time it takes to compare the model and the cold query
Example
I tried also with ngen I post a screenshot where you see the result, the creations of all the .dll with ngen, and through windows process verification using native images, but the result has not changed:
ScreenShot ngen
As for the pre-generated view with vs 2015 I did not do them because I f are from a compilation error of a path too long, I read that with the new compiler is rosylin this limitation but do not know ....