Five New Optimizely Certifications are Here! Validate your expertise and advance your career with our latest certification exams. Click here to find out more

Per Magne Skuseth
Apr 1, 2014
  7551
(0 votes)

SQL Blob Provider: Store your blobs in the database

A new package is available on the EPiServer nuget feed: EPiCode.SqlBlobProvider. This is a blob provider that enables storing of blobs in the database, rather than on disk.

Why is this useful?

  • Perfect for load balanced environments, as you will not need a file share or similar to handle distribution of files between servers
  • Great for development teams who share a database
  • Easier to deploy: No need to copy blob files when doing a deploy or migration to another environment. No need of putting them in source control either for that matter
  • When you bring back the database from production to your development environment for that next feature you're doing, you get all the files too
  • Should also work fine for EPiServer Commerce

 

Installation

Install the NuGet package, and your are good to go. EPiServerFramework.config should be automatically transformed with the correct blob provider settings. If you need to change it manually, simply add the following to EPiServerFramework.config:

<blob defaultProvider="sqlBlobProvider">
  <providers>
    <add name="sqlBlobProvider" type="EPiCode.SqlBlobProvider.SqlBlobProvider, EPiCode.SqlBlobProvider" />
  </providers>
</blob>

Migration

If you are installing the SqlBlobProvider in an existing project that already uses the standard file blob provider, you will need to convert existing FileBlobs into SqlBlobs. This can easily be done with EPiCode.BlobConverter, which is another new package in the feed. The package contains a scheduled job (aka. BlobJob), which will convert all file blobs into the currently configured blob type. The conversion tool is not restricted to the SqlBlobProvider, so you could use it for other blob types as well.

Tip: If you are upgrading to EPiServer 7.5, and migrating VPP-based files to the new media system and want to use the SQL blob provider, make sure that the provider is installed prior before running the EPiServer VPP migration tool. This way, the VPP-files will be directly migrated to SQL blobs.

 

This is an open source module and full source code is available on EPiCode: 

https://www.coderesort.com/p/epicode/browser/EPiCode.SqlBlobProvider

Apr 01, 2014

Comments

Please login to comment.
Latest blogs
Optimizely Configured Commerce and Spire CMS - Figuring out Handlers

I recently entered the world of Optimizely Configured Commerce and Spire CMS. Intriguing, interesting and challenging at the same time, especially...

Ritu Madan | Mar 12, 2025

Another console app for calling the Optimizely CMS REST API

Introducing a Spectre.Console.Cli app for exploring an Optimizely SaaS CMS instance and to source code control definitions.

Johan Kronberg | Mar 11, 2025 |

Extending UrlResolver to Generate Lowercase Links in Optimizely CMS 12

When working with Optimizely CMS 12, URL consistency is crucial for SEO and usability. By default, Optimizely does not enforce lowercase URLs, whic...

Santiago Morla | Mar 7, 2025 |

Optimizing Experiences with Optimizely: Custom Audience Criteria for Mobile Visitors

In today’s mobile-first world, delivering personalized experiences to visitors using mobile devices is crucial for maximizing engagement and...

Nenad Nicevski | Mar 5, 2025 |

Unable to view Optimizely Forms submissions when some values are too long

I discovered a form where the form submissions could not be viewed in the Optimizely UI, only downloaded. Learn how to fix the issue.

Tomas Hensrud Gulla | Mar 4, 2025 |

CMS 12 DXP Migrations - Time Zones

When it comes to migrating a project from CMS 11 and .NET Framework on the DXP to CMS 12 and .NET Core one thing you need to be aware of is the...

Scott Reed | Mar 4, 2025