Project deployment

Project deployment

Postby JeffCertain » Mon 27 Jul 2015 23:31

We have dotConnect licenses for our dev team, and are upgrading to 7.3.457.

In the past, this has been a burdensome process, and I'm hoping to make it easier.

Towards this end, I was hoping to have the DLLs included in our project bin folders rather than having to install dotConnect on every build machine, web server, and UI dev box.

I've got the DLLs included in the build just fine. I've got the following lines in the test project app.config:
Code: Select all
         <provider invariantName="Devart.Data.PostgreSql" type="Devart.Data.PostgreSql.Entity.PgSqlEntityProviderServices, Devart.Data.PostgreSql.Entity, Version=7.3.457.6, Culture=neutral, PublicKeyToken=09af7300eec23701" />
      <defaultConnectionFactory type="System.Data.Entity.Infrastructure.SqlConnectionFactory, EntityFramework" />

However, when a developer who hasn't installed dotConnect tries to run our unit test suite, all he gets is an exception that reads:
Code: Select all
System.Reflection.TargetInvocationException... Unable to determine the provider name for provider factory of type 'Devart.Data.PostgreSql.PgSqlProviderFactory'.

This all works just fine on my box, but I've installed dotConnect and have it in the GAC. Any advice?

Posts: 4
Joined: Mon 27 Jul 2015 23:17

Re: Project deployment

Postby Shalex » Tue 28 Jul 2015 07:08

Have you added the DbProviderFactories entry in your app.config like it is described in the documentation?
Code: Select all
    <remove invariant="Devart.Data.PostgreSql" />
    <add name="dotConnect for PostgreSQL" invariant="Devart.Data.PostgreSql" description="Devart dotConnect for PostgreSQL" type="Devart.Data.PostgreSql.PgSqlProviderFactory, Devart.Data.PostgreSql, Version=7.3.457.0, Culture=neutral, PublicKeyToken=09af7300eec23701" />

Replace 7.3.457 here with your current version of dotConnect for PostgreSQL. Please note that the revision number of provider in the entityFramework section is *.6 but it should be *.0 in DbProviderFactories.

If this doesn't help, specify the full call stack of the error with all inner exceptions.
Devart Team
Posts: 7880
Joined: Thu 14 Aug 2008 12:44

Re: Project deployment

Postby JeffCertain » Tue 28 Jul 2015 21:21

Perfect! Thanks so much for your help; that was exactly what we needed.

Turns out that pretty much every *.config except the test project's app.config had this section.
Posts: 4
Joined: Mon 27 Jul 2015 23:17

Return to dotConnect for PostgreSQL