Tuesday, May 4, 2010

Speed up your CRM SDK imports and updates

I ran across this problem several weeks ago that an import of many thousands of records using the CRM SDK was taking forever, or timing out.  Luckily, there is a setting on the connection object that you can use to speed things up quite a bit.

CrmService crm = new CrmService();
crm.Credentials = System.Net.CredentialCache.DefaultCredentials;

crm.UnsafeAuthenticatedConnectionSharing = true;

This other blog post describes these setting in more detail.


This was also discussed at a CRM Optimization session at Convergence 2010 and the Microsoft Support people said that for bulk inserts/updates this is OK to use, just keep in mind the caveats of only authenticating once.  Probably fine for internal use on your network, but not for external internet connections, etc.

No comments:

Post a Comment