Sun, Feb 18 2007 10:57 PM Olaf Conijn

Environmental overrides made it into EntLib v3!

 Let’s start out with a little history here.

About 1.5 year ago I worked as a development coach to a team of programmers at a large dutch insurance broker. To satisfy some of the infrastructural requirements we spec-ed in enterprise library v1. The team I worked at had a pretty sophisticated build environment set up and all sorts of procedures and protocols to propagate changes to different environments (test, production and so on). Since the project just started we were still trying to make sense of all of these processes and figuring out how we could comply with these, at best. As with most problems, the fundamentally better you would like to solve them, the more complicated they become. This at least was the case for managing and propagating changes to the configuration files within these environments. I had a fair understanding of how Enterprise Libraries configuration tool worked and how to extend it and during a month-or-so holiday at my family’s vacation house in Finland I hacked something together that would solve this particular problem. For kicks and because I felt this particular problem had bugged me for long enough.

Quickly after posting this solution on my weblog, the patterns & practices team contacted me and engaged me on a contract to work on Enterprise Library v2. Unfortunately the feature got cut and most of my time was spend on more sensible Enterprise Library v2 features. This time around (with Enterprise Library v3 on its way) the extension finally made it “above the line”.

So, what is this “environmental overrides”-thing and what value does it add to Enterprise Library?

Environmental Overrides is an extension to Enterprise Libraries configuration tooling that can help you keep track of differences in configuration throughout your infrastructure. The extension is part of the designtime and not of the runtime parts of Enterprise Library, which means that it will be compatible with any application written on top of Enterprise Library.

Managing differences between configuration files can be done in the same view you would edit configuration settings for a particular “Configuration Node”. For each environment configured in the editor you will have the possibility to either “override” the settings for a particular environment, or keep the settings for this environment in sync with the original. Configuring the environment can be done from within the configuration-treeview, adding new environment nodes underneath the “Environments” node.

Environmental Overrides in Configuration Tool
A configuration hierarchy that contains 2 environments ‘Test’ and ‘Production’ of which one has different values the LogEnabled filter.

Every environment that is configured in the tool, will maintain its own “Environment Delta File” (or .dconfig file), which is updated after saving the configuration as a whole. This Environment Delta File contains all the differences specific to that environment and some additional metadata for merging the differences into a new and complete configuration file that can be deployed. The main advantage here is that an Environment Delta File can be distributed separately of the original configuration file and managed by someone that has access to all the passwords, server-names and whatnot of the different environment.

Relationship between Original Configuration File, Environmental Delta File and Merged Environment Configuration
Relationships between Original Configuration File, Environment Delta File and Merged Configuration File.

Another new and hopefully useful addition is the ability to merge the Environmental Delta File and Original using a command line tool, which allows automating this process within for instance a build or integration server.


The Environmental Overrides extension will be included in the next CTP of Enterprise Library 3.0, available soon –in a web browser near you!
www.codeplex.com/entlib

 

 

Filed under: ,

# Environmental Overrides in Enterprise Library 3.0

Sunday, February 18, 2007 5:44 PM by Tom Hollander's blog

One very cool new feature which will debut in the next (and final) CTP of Enterprise Library 3.0 is something

# re: Environmental overrides made it into EntLib v3!

Sunday, February 18, 2007 11:47 PM by Vikas Goyal

Thanks for this great feature team.

http://DotNetWithMe.blogspot.com

vikas goyal

# Environmental Overrides Come to EntLib!

Monday, February 19, 2007 10:19 AM by TSHAK

We're finally getting environmental overrides with Enterprise Library! This means that you can have environment...

# re: Environmental overrides made it into EntLib v3!

Monday, February 19, 2007 2:25 PM by Erwyn van der Meer

Congratulations. Great work!

# re: Environmental overrides made it into EntLib v3!

Monday, February 19, 2007 11:41 PM by Clemens Reijnen

They are still using that pretty sophisticated build environment and all sorts of procedures and protocols to propagate changes to different environments ;-)

Congratulations.

# Enterprise Library 3.0 to have Environmental Overrides

Wednesday, February 28, 2007 11:50 AM by Words of Wisdom From The Elder

Enterprise Library 3.0 to have Environmental Overrides

# Just Released: Enterprise Library 3.0 February 2007 CTP

Wednesday, February 28, 2007 6:49 PM by Tom Hollander's blog

OK, I know the sun has already set on February in some parts of the world, but over here it's still well

# Enterprise Library 3.0 februári CTP

Monday, March 05, 2007 8:35 AM by Mount Gellért - az architekt, és aki mögötte van

Kijött a februári CTPje az Enterprise Library 3.0-nak , ami RCnek is tekinthető. Miért is jó ez nekünk?

# re: Environmental overrides made it into EntLib v3!

Monday, March 12, 2007 6:02 PM by won

Great Work!!

but I have a question. I have configured the EnvironmentConfigurationFile, but the file wasn't created...

should I create the file by using command line tool?

thanks.

# Enterprise Library 3.0 februári CTP

Tuesday, April 24, 2007 2:03 AM by petersm

Kijött a februári CTPje az Enterprise Library 3.0-nak , ami RCnek is tekinthető. Miért is jó ez nekünk

# Environmental Overrides

Monday, September 10, 2007 1:25 AM by Soledad Pano

This post was originally published at http://solepano.blogspot.com February 2007 CTP of Enterprise Library