Monday, November 28, 2016

Sitecore Data Exchange Framework - Sql Server provider

As you have probably heard Sitecore team has released a new module for integration Sitecore application with other systems. I have written an import tool of my own, and was very curious to see what Sitecore developers came up with. Out of the box, Data Exchange Framework module comes with Sitecore provider, which is great because it can be used with Sitecore to Sitecore migrations or for providers that need to write to Sitecore. However, I was more interested in using this module for importing content from non-Sitecore systems where the data often is stored in a SQL database.

I have to say that documentation for this module is written very well, and implementing a new provider was a very simple task just by following instructions from Developer Guide (http://integrationsdn.sitecore.net/DataExchangeFramework/v1.1/). I am not going to try to re-write the documentation, but will provide the code I arrived at after I had implemented everything that the developer guide had specified.

The code that you can find at https://github.com/jcore/Sitecore.DataExchange.Providers.SqlServer contains classes and a Sitecore package for provider. The package does not include the template for items that would be created by import process. It would be different for each solution, so I decided to omit it.

Here is screenshot of the project structure. As you can see it is pretty slim. It took me a couple of hours to implement this version of provider, which I thought was great. I really liked how easy it was to create new provider to fit what I needed to do. 

There are more to explore with this module. I am especially interested in processing of sql values before they are stored in Sitecore.