EntityFramework 4.2, used to connect to MySQL DB, is not being uploaded to Azure web instance
Posted by: Chris Judge
Date: December 04, 2014 03:52AM

I have a asp.net C# web application built in VS2010. I am using a MySQL database hosted on Amazon RDS, and Windows Azure to host the instance.

My application is targeting .NET Framework 4.0, and I have installed EntityFramework 4.2 via Nuget package manager. I am using the MySQL Connector .Net v6.9.4.

I run it fine on my local PC, the EntityFramework package seems to have been installed correctly. When I publish the project it to Azure, however, the EntityFramework DLL is not located in the 'bin' folder on the Azure VM.

In my web.config, I have:

<assemblyIdentity name="EntityFramework" publicKeyToken="b77a5c561934e089" culture="neutral" />
<bindingRedirect oldVersion="" newVersion="" />

And in the packages.config for the project I am referencing the EF, I have:

<package id="EntityFramework" version="" targetFramework="net40" />

but when I try to run my aplication from the cloud, I get the following error:

Could not load file or assembly 'EntityFramework, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089' or one of its dependencies. The system cannot find the file specified.

Which is quite obvious that it can't be found as it is not being uploaded, for some reason... Why? I have 'Copy Local' set to true for all references of the EF DLL, so am pretty confused why it's not being uploaded to the web instance. Can anyone think of a reason as to why this is not being uploaded to the Azure instance? Is there something I've missed (which is quite possible, I'm a novice when it comes to web app dev)?

NOTE: I am posting this here as this project previously used MSSQL as the database, was using the same version of EF and always worked. But I've had to migrate it to use MySQL (company decision) and now I am facing this issue, so I think some people here may have faced this problem before?

Options: ReplyQuote

Written By
EntityFramework 4.2, used to connect to MySQL DB, is not being uploaded to Azure web instance
December 04, 2014 03:52AM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.