Session Property to indicate App Environment - Production DB versus Test/Dev DB

That’s a good start… But still can’t identify the actual environment.

And from what I’ve heard some folks have separate TEST and DEV environments.

I Second that @edge May 1000 elephants fertilize your pumpkin patch with their droppings. That’s awesome, we’ve been doing it via Code Blocks for years. Woohoo!!!

I have a DEV, TST, TRN, PRD, EDU – all seperate Machines, Seperate IIS Instance, same Names like “EpicorERP” and I use the Server Name to Determine it via Code, for the time being.

Previously where I worked we prefixed the Servers with PRD-APP1, PRD-RPT1, DEV-APP1 so I only needed to use .Contains() but at my new job they are random names, I started to use alot more Checkboxes on Company Configuration to Enable/Disable something. So when we do a DB Copy I just run the SQL to uncheck those Columns.

1 Like

Tangential to IsProduction, I noticed Company Maintenance also has an “Is Live” checkbox.

image

1 Like

In the web.config of the server instance, you could just add a custom appSettings key/value to indicate what environment you’re in, and then access it from a BPM by using:

var customAppSetting = System.Configuration.ConfigurationManager.AppSettings["CustomAppSetting"];

We do this with logging level and environments and a few other things.