<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>CertPal &#187; testing</title>
	<atom:link href="http://www.certpal.com/blogs/tag/testing/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.certpal.com/blogs</link>
	<description>Technology and certifications</description>
	<lastBuildDate>Mon, 18 Jul 2011 06:48:59 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Testing in production</title>
		<link>http://www.certpal.com/blogs/2010/06/testing-in-production/</link>
		<comments>http://www.certpal.com/blogs/2010/06/testing-in-production/#comments</comments>
		<pubDate>Wed, 30 Jun 2010 15:58:31 +0000</pubDate>
		<dc:creator>CertPal</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[production]]></category>
		<category><![CDATA[testing]]></category>

		<guid isPermaLink="false">http://www.certpal.com/blogs/?p=819</guid>
		<description><![CDATA[Do you test your code in production ? If you do not you might want to consider these scenarios and rethink if it makes sense to test in the live environment. What is your opinion and why ?]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.certpal.com%2Fblogs%2F2010%2F06%2Ftesting-in-production%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.certpal.com%2Fblogs%2F2010%2F06%2Ftesting-in-production%2F&amp;style=normal&amp;service=bit.ly&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p><a href="http://www.certpal.com/blogs/wp-content/uploads/bomb_fuse.png"><img class="alignright size-full wp-image-825" title="bomb_fuse" src="http://www.certpal.com/blogs/wp-content/uploads/bomb_fuse.png" alt="" width="128" height="128" /></a>Do you ever test your code after it has been deployed to production ? During my first few years programming, I thought this was a bad idea and was told repeatedly told not to test anything in Prod.</p>
<p>After being bitten time and again by environment related problems, I decided to make it a point to perform a smoke test in Prod before handing it to users. Even if it meant a transaction with real money was involved.</p>
<p>Let me take a few moments to recite some of the follies that befell me when I did not test in Prod.</p>
<ul>
<li>Code moves to production. We find out that the SSL certificates in QA are installed in a different configuration when compared to Prod. The isSecure() flag on the HttpServletRequest returned a different value because of this and the code bombed.</li>
</ul>
<ul>
<li>A process tries to check in and check out files from clear case. The live environment has some clear case triggers that prevent check in based on certain rules. These rules are absent in QA. Kaboom.</li>
</ul>
<ul>
<li>A web service provider used an unsigned certificate in prod and didnt tell us about it. The cert chain hierarchy broke and the application stopped working.</li>
</ul>
<ul>
<li>An insert into a table in DEV was done using dummy user GUIDs. When the code was moved to Prod, we found out that all production GUIDs are of length 42 but the test GUIDs were of length 30.</li>
</ul>
<ul>
<li>And so on&#8230;</li>
</ul>
<p>I think it is justifiable to even test code in Prod when money is involved. Just test for a transaction value of one  dollar and then roll it back. Sure beats a customer coming back to you and telling you that your system is broken.</p>
<p>But enough about what I think. What do you think ? Do you test your code in the live environment ? Take a small yes / no poll and if you feel the answer should be no, feel free to leave a comment.</p>
Note: There is a poll embedded within this post, please visit the site to participate in this post's poll.
<p><script type="text/javascript">var dzone_url = 'http://www.certpal.com/blogs/2010/06/testing-in-production/';</script><br />
<script type="text/javascript">var dzone_title = 'Testing in production';</script><br />
<script type="text/javascript">var dzone_blurb = 'Do you test your code in production ? If you do not you might want to consider these scenarios and rethink if it makes sense to test in the live environment. ';</script><br />
<script type="text/javascript">var dzone_style = '2';</script><br />
<script language="javascript" src="http://widgets.dzone.com/links/widgets/zoneit.js"></script>
<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.certpal.com%2Fblogs%2F2010%2F06%2Ftesting-in-production%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.certpal.com%2Fblogs%2F2010%2F06%2Ftesting-in-production%2F&amp;style=normal&amp;service=bit.ly&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
]]></content:encoded>
			<wfw:commentRss>http://www.certpal.com/blogs/2010/06/testing-in-production/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

