<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-7170613974457474822</id><updated>2012-02-16T16:40:00.461+10:00</updated><category term='MEF'/><category term='IOC'/><category term='MVC'/><category term='Provider Model'/><category term='ASP.NET'/><title type='text'>Health-e-Dev</title><subtitle type='html'>Software Development in the Health Industry</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://healthedev.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7170613974457474822/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://healthedev.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Andrew Newton</name><uri>https://profiles.google.com/100508578871900935503</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh3.googleusercontent.com/-94Wc3a4Qgis/AAAAAAAAAAI/AAAAAAAAAC0/j2PEqn5j4Go/s512-c/photo.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>3</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-7170613974457474822.post-3890475546110163864</id><published>2011-12-20T13:52:00.000+10:00</published><updated>2011-12-20T13:52:02.051+10:00</updated><title type='text'>Move TFS 2010 Project Collection Database to Different SQL Server</title><content type='html'>If you started using TFS 2010 on a &lt;a href="http://msdn.microsoft.com/en-us/library/dd631899.aspx" target="_blank"&gt;single server&lt;/a&gt;&amp;nbsp;then you might get to a point where you want to move one or more Project Collection databases off that server. &amp;nbsp;The reaons for that could be improved performance, or that you installed SQL Express and your database hit the &lt;a href="http://blogs.msdn.com/b/sqlexpress/archive/2010/04/21/database-size-limit-increased-to-10gb-in-sql-server-2008-r2-express.aspx" target="_blank"&gt;4GB limit (now 10GB)&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Another common scenario where these steps might be handy is if you're in an environment with Shared SQL Server infrastructure, and your DBA's don't want your TFS account having "sysadmin" access on the server. &amp;nbsp;What you can do is grant your TFS account "sysadmin" access for a few minutes while you configure the server (see Part 1 below), then they can take it away for good. &amp;nbsp;Alternatively you could try give a DBA account TFS Administrator access and get them to follow the steps in Part 1. &amp;nbsp;You can then create Project Collections on your SQL Express instance, and have them moved in a controlled manner using the steps in Part 2 below.&lt;br /&gt;&lt;br /&gt;I found it difficult to find "easy to follow" instructions on how to move an individual TFS Project Collection database. &amp;nbsp;Some instructions &lt;a href="http://msdn.microsoft.com/en-us/library/ms252516.aspx" target="_blank"&gt;show how to move all databases&lt;/a&gt; including SharePoint and Reporting Services which makes the instructions complicated if you just want to move one of the databases. &amp;nbsp;So my &lt;b&gt;disclaimer&lt;/b&gt; is "&lt;i&gt;this worked for me&lt;/i&gt;"! &amp;nbsp;If you do try this yourself and hit any issues or have any questions please leave a comment on this blog post and I will see if I can help.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;&lt;u&gt;Part 1: Prepare the SQL Server Instance for TFS:&lt;/u&gt;&lt;/b&gt;&lt;br /&gt;This part can actually be the most challenging because you need a service account that is a TFS Administrator, and has "sysadmin" access on the SQL Server box! &amp;nbsp;You better either have really nice DBA's who will temporarily grant your service account "sysadmin" access on the SQL box, or you better be a nice TFS Administrator and prepared to give your DBA's account TFS Administrator access.&lt;br /&gt;&lt;br /&gt;I went with the "nice DBA" option and got the DBA's to give my TFS service account "sysadmin" access on a SQL box, so I can't confirm whether giving a DBA account TFS Administrator access works but there is no reason it should not.&lt;br /&gt;&lt;br /&gt;Here are the steps:&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Choose "Account X" which is already a TFS administrator service account, &lt;a href="http://blog.sqlauthority.com/2008/12/27/sql-server-add-any-user-to-sysadmin-role-add-users-to-system-roles/" target="_blank"&gt;grant it "sysadmin" access on the Destination SQL Server&lt;/a&gt;&lt;/li&gt;&lt;li&gt;Remote into the TFS Server and fire up a command prompt running as "Account X"&lt;/li&gt;&lt;li&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/ee349267.aspx" target="_blank"&gt;Run the "TFSConfig PrepSQL" command&lt;/a&gt;&amp;nbsp;passing through the Destination SQL Server Instance name&lt;/li&gt;&lt;li&gt;Revoke the "sysadmin" access for "Account X" on the Destination SQL Server&lt;/li&gt;&lt;/ol&gt;&lt;div&gt;Assuming this works, the server is now ready to host any TFS databases! &amp;nbsp;It seems that command somehow notifies TFS about the SQL Instance as well as SQL Server being "prepared". &amp;nbsp;That is why the account needs such a high level of access on both systems.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;&lt;u&gt;Part 2: Move the database and Reconfigure TFS:&lt;/u&gt;&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;ol&gt;&lt;li&gt;Remote into the TFS Server and open the TFS Admin app&lt;/li&gt;&lt;li&gt;Stop the Project Collection you are going to move&lt;/li&gt;&lt;li&gt;Take a full backup of the current Project Collection database&lt;/li&gt;&lt;li&gt;Restore the Project Collection database to the Destination SQL Server&lt;/li&gt;&lt;li&gt;Back in the TFS Admin App, edit the Project Collection giving it the Destination SQL Server Instance name and hit "Save" (this took a few minutes for me)&lt;/li&gt;&lt;li&gt;Bring the Project Collection back online&amp;nbsp;&lt;/li&gt;&lt;/ol&gt;&lt;div&gt;I have&amp;nbsp;definitely&amp;nbsp;noticed a massive performance improvement having the Project Collection database running on a high-spec SQL Server Instance rather than the lower-spec single server install that TFS is on.&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7170613974457474822-3890475546110163864?l=healthedev.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://healthedev.blogspot.com/feeds/3890475546110163864/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://healthedev.blogspot.com/2011/12/move-tfs-2010-project-collection.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7170613974457474822/posts/default/3890475546110163864'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7170613974457474822/posts/default/3890475546110163864'/><link rel='alternate' type='text/html' href='http://healthedev.blogspot.com/2011/12/move-tfs-2010-project-collection.html' title='Move TFS 2010 Project Collection Database to Different SQL Server'/><author><name>Andrew Newton</name><uri>https://profiles.google.com/100508578871900935503</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh3.googleusercontent.com/-94Wc3a4Qgis/AAAAAAAAAAI/AAAAAAAAAC0/j2PEqn5j4Go/s512-c/photo.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7170613974457474822.post-226339538898187935</id><published>2011-12-13T20:49:00.000+10:00</published><updated>2011-12-13T20:49:09.055+10:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='MEF'/><category scheme='http://www.blogger.com/atom/ns#' term='MVC'/><category scheme='http://www.blogger.com/atom/ns#' term='Provider Model'/><category scheme='http://www.blogger.com/atom/ns#' term='IOC'/><category scheme='http://www.blogger.com/atom/ns#' term='ASP.NET'/><title type='text'>Making Custom Built Applications “Saleable”</title><content type='html'>&lt;br /&gt;One of the requirements for my team is to ensure any software we build for our own organisation could be packaged up and sold to another organisation with instructions on how to customize and deploy it. &amp;nbsp;This came about through various requests for our software that had been shown at conferences and demonstrations. &amp;nbsp;Back when the original requests came in (2007-2008) we would have had to do a significant amount of work to be able to “sell” the applications. &amp;nbsp;One of the requests was from a Healthcare software vendor, wanting to purchase an application we wrote to address inadequacies in their system! &amp;nbsp;Most requests however come from other Healthcare organisations (including Government) and they have just seen what we have produced and think it will also work in their environment. &amp;nbsp;This requirement now exists by default for most new applications unless there is a specific reason we would not want to sell a particular application.&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;I am not sure if this kind of requirement is common in other industries. &amp;nbsp;I am assuming not because in a lot of industries that are developing custom software, each company is trying to get a competitive edge by building software that makes them more efficient and gives them an advantage over their rivals. &amp;nbsp;In the not-for-profit Healthcare space we share as many ideas as possible with other Healthcare organisations and Government Healthcare agencies to help reduce rework and produce a better outcome for patients.&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Our team primarily builds web applications. &amp;nbsp;Back in 2007 when this requirement was introduced the best solution seemed to be to use the &lt;a href="http://en.wikipedia.org/wiki/Provider_model" target="_blank"&gt;ASP.NET Provider Model&lt;/a&gt;. &amp;nbsp;We successfully used that in applications up until now and it works nicely. &amp;nbsp;Before the introduction of IOC into our team, it gave us nice separation of concerns for our “integration” code. &amp;nbsp;Basically any functionality that was not core to the system would be extracted out into a “custom provider”. &amp;nbsp;So for example, “SearchForPatient” might be a method on one custom provider. &amp;nbsp;If another company were to purchase the software and deploy it, they could create their own implementation of the custom provider (which is just an abstract class) and implement that patient search method to search their own repository of patient data. &amp;nbsp;They could then drop the DLL into the BIN folder and update the web.config to tell the application to use their provider instead of ours. &amp;nbsp;This was a good solution for its time, but can cause issues with nasty configuration as there are no conventions!&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;With such great IOC containers available (we are currently using &lt;a href="http://code.google.com/p/autofac/" target="_blank"&gt;AutoFac&lt;/a&gt; for ASP.NET MVC applications); I have started to investigate if there is a “better way” to achieve this “saleability” than using the Provider Model. &amp;nbsp;If we use IOC properly, we might be “double hopping” in order to use a provider – because the IOC container needs to register the custom provider, which then uses the provider’s config to set itself up and get an implementation instance. &amp;nbsp;I have not done any performance testing but this seems like overkill and if nothing else it is a bit confusing for new developers. &amp;nbsp;In another project I have seen, there is a mix of IOC and providers due to commonly used providers such as the Membership and Role Providers. &amp;nbsp;So that is a good example where the project will generally have an interface to wrap the Membership Provider methods it needs, then the implementation at run time will pick up a class that instantiates the Membership Provider via configuration (as normal) and passes through the calls to that Membership Provider. &amp;nbsp;It makes sense to do that because the &lt;a href="http://msdn.microsoft.com/en-us/library/system.web.security.sqlmembershipprovider.aspx" target="_blank"&gt;OOB Membership Providers&lt;/a&gt; have a lot of logic within them that you don’t want to be replicating. &amp;nbsp;However in my case, we are hand-rolling Custom Providers which would then get wrapped by an interface and calling implementation class for IOC purposes – so it seems wrong.&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;One option to replace the Provider Model would be to use the &lt;a href="http://code.google.com/p/autofac/wiki/XmlConfiguration" target="_blank"&gt;configuration "mode" of an IOC container&lt;/a&gt;. &amp;nbsp;This could be slightly cleaner than the Provider Model because you could programmatically hook up the dependencies by default, but just allow configuration as an optional “override”, leaving our in-house code base nice and clean but anyone else who uses it with a bit of a configuration mess.&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Another option might be MEF. &amp;nbsp;The &lt;a href="http://mef.codeplex.com/" target="_blank"&gt;next version of MEF&lt;/a&gt; (still in preview) is a viable IOC container and it has some great conventions which should allow someone to “drop in” an implementation over the top of the default one and that could pick it up with absolutely no configuration!&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;For now since we have decided to go with AutoFac in MVC project my aim is to set it up that way to do away with any Provider Model implementations in those new MVC projects.&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;I jumped on the IOC bandwagon later than I would have liked to (and am never looking back) so I would be interested to hear some comments from some IOC/MEF “gurus” on whether I am heading down the right track or if there is something I have not thought of! &amp;nbsp;Also if you are facing a similar issue and want to discuss leave a comment.&lt;/span&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7170613974457474822-226339538898187935?l=healthedev.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://healthedev.blogspot.com/feeds/226339538898187935/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://healthedev.blogspot.com/2011/12/making-custom-built-applications.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7170613974457474822/posts/default/226339538898187935'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7170613974457474822/posts/default/226339538898187935'/><link rel='alternate' type='text/html' href='http://healthedev.blogspot.com/2011/12/making-custom-built-applications.html' title='Making Custom Built Applications “Saleable”'/><author><name>Andrew Newton</name><uri>https://profiles.google.com/100508578871900935503</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh3.googleusercontent.com/-94Wc3a4Qgis/AAAAAAAAAAI/AAAAAAAAAC0/j2PEqn5j4Go/s512-c/photo.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7170613974457474822.post-2006496038238513987</id><published>2011-12-13T10:28:00.000+10:00</published><updated>2011-12-13T12:17:00.200+10:00</updated><title type='text'>Welcome to Health-E-Dev! What is the purpose of this blog?</title><content type='html'>I read a lot of blogs.&amp;nbsp; Mostly technology related to do with programming languages and frameworks as they help me learn about the latest and greatest technologies I can use to help me build the best software possible.&amp;nbsp; I also read some blogs about management and agile development methodologies, as that is another part of my role.&amp;nbsp; The other main category of blogs I read is Health Industry related news.&amp;nbsp; That gives me a good knowledge of what’s going on in the Industry so I can try and be ahead of the game.&lt;br /&gt;I decided to start my own blog for the following reasons:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Knowledge base – so I can record my thoughts/decisions to refer to them at a future date  &lt;/li&gt;&lt;li&gt;To get feedback from other people about my thoughts/decisions  &lt;/li&gt;&lt;li&gt;To try and provide a useful news source for other people in a similar position to me who are looking for a Health Industry related Software Development blog&lt;/li&gt;&lt;/ol&gt;I have no technology bias although I do tend to use Microsoft products for a large amount of the programming work I do.&amp;nbsp; I find the Microsoft toolsets and frameworks very conducive to a productive programming team.&lt;br /&gt;I am not sure how often I will blog or what content will come out in the blog, I have no set plan, I will just see where it takes me.&amp;nbsp; If I end up getting nothing out of it, I will cease, so please provide any comments or feedback if I seem to be slowing down and you would like to see more.&lt;br /&gt;&lt;br /&gt;I may also use the name of this blog as a play on words and explain how I try to keep "healthy" myself while being a developer as that can be a challenge!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7170613974457474822-2006496038238513987?l=healthedev.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://healthedev.blogspot.com/feeds/2006496038238513987/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://healthedev.blogspot.com/2011/01/welcome-to-health-e-dev-what-is-purpose.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7170613974457474822/posts/default/2006496038238513987'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7170613974457474822/posts/default/2006496038238513987'/><link rel='alternate' type='text/html' href='http://healthedev.blogspot.com/2011/01/welcome-to-health-e-dev-what-is-purpose.html' title='Welcome to Health-E-Dev! What is the purpose of this blog?'/><author><name>Andrew Newton</name><uri>https://profiles.google.com/100508578871900935503</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh3.googleusercontent.com/-94Wc3a4Qgis/AAAAAAAAAAI/AAAAAAAAAC0/j2PEqn5j4Go/s512-c/photo.jpg'/></author><thr:total>0</thr:total></entry></feed>
