tag:blogger.com,1999:blog-4371826158912179022024-03-05T13:24:40.432-08:00Technology injection-A daily doze of technology keeps you running-Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.comBlogger25125tag:blogger.com,1999:blog-437182615891217902.post-20652965099855868542010-04-19T14:37:00.000-07:002010-04-19T14:38:41.468-07:00New blog stay tuned...Well after a long time with no posts, be prepared, I'm moving my blog to www.Rasmuschristensen.dk, så stay tunedRasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-49901233927618974332009-12-17T12:58:00.001-08:002009-12-17T12:58:11.435-08:00Resharper Quick Info View<p>By hitting the wrong key, I found a nice feature of resharper. By hitting Ctrl+q on almost every word you get an extended tooltip with information the “word”. For instance hitting an ITransaction for nhibernate you get:</p> <p><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgOdCNYV9YJ2x70F80BfjVimuamz4DUjz5LTf47Vbj2DR8vYkLOBSgu3KClB0mxk5Ja-L2GM8MEyrb1BcMyQ9t7ImqfBnANt9prHu5YhM0VKhRjzW3y-N-KKU_nCSwvU9-X4YjcfXIs7yNK/s1600-h/quicktip%5B3%5D.jpg"><img style="border-bottom: 0px; border-left: 0px; display: block; float: none; margin-left: auto; border-top: 0px; margin-right: auto; border-right: 0px" title="quicktip" border="0" alt="quicktip" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj1b7rWUwWwGsskhmqC-2V21DJdoKA6ZJH33kgXnKcebOQ54fVvVv2oB2OsUWQRlSlu_eRegil5j3rhyphenhyphenZOEO-6sYSmdvR0mBoQQeF7iC0JM0rXDXXFMV_8TQK_N8uz-TtPRFWt3UveqqI3i/?imgmax=800" width="244" height="207"></a></p> Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-58862272285345473942009-12-13T12:31:00.001-08:002009-12-13T12:31:33.755-08:00Nhibernate Profiler – not displaying all statements? – Solution<p>Yesterday I made some integrationtests with nhibernate and NUnit. Suddenly I could not see all statements in the NHibernate Profiler, but sql statements was displayed in Visual Studio. A quick post to the <a href="http://nhprof.com" target="_blank">NH Profiler</a> support at google groups gave me the solution. </p> <p>If the process that runs the query via NHibernate terminates too quickly not all statements will show up in the NHProfiler, but if you make the following call at the end:</p> <div id="codeSnippetWrapper"> <div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px" id="codeSnippet"><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum1"> 1:</span> ProfilerInfrastructure.FlushAllMessages();</pre><!--CRLF--></div></div><br /><p></p><br /><p>All statements will show up. For a test with NUnit as I had, I just placed the call in a TearDown method for the TestFixture, and vola now all statements are showed in the NHibernate Profiler.</p> Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-14262391637071777292009-11-19T14:20:00.001-08:002009-11-19T14:20:12.718-08:00Two Approaches For Creating Aggregates in DDD<p>Tonight I´m working on a project where I try to implement DDD. One of the things my mind has worked on for a long time is how upo should make the communication between aggregates, Should it be lazy load, should I somehow store an ID for entities in anoter aggregate or how can I do it?</p> <p>I just found this nice article showing two different approaches for exactly this topic <a href="http://rogeralsing.com/2009/11/08/two-flavors-of-ddd/" target="_blank">here</a>. I think I will try out both solutions and later thoose the one that best suites my needs and mind :)</p> <p>If anybody have other approaches, please feel free to leave a comment.</p> Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com1tag:blogger.com,1999:blog-437182615891217902.post-67015467454685019702009-11-14T16:03:00.001-08:002009-11-14T16:05:09.521-08:00Umbraco finally up and running – The Way I did it……<p>It’s getting late here in DK and it is almost 4 days since I wrote about my next technology journy, Umbraco CMS. And I finally managed to get it running on my local machine. </p> <p>I started out getting the new webplatform installer for Umbraco, It just had to be the most simple way to get started for a developer new to umbraco. I’m running XP SP3 on my developer machine, and with this in mind some of the installation trouble I had might be caused of exactly that.</p> <p>The webplatform installer did install on in IIS and created a db, but I never managed to get the IIS (5.1) on my machine running Umbraco, I tried a lot of different solutions, Uncle Google told me to, but no luck. Then finally I looked at <a href="http://umbraco.org/documentation/books/install-umbraco-4-on-localhost---simplified" target="_blank">Umbraco installation simplified</a>. Wow this is just what I was looking for. This explains how to use the Cassine webserver for running and developing with Umbraco. I Followed the installation and almost got it up and running. One of the steps in the installation guide explains how to set up AJAX 1.0, but as I’m running .NET 3.5 I skipped this part…my bad. Ofcourse I got in trouble when I stated the Umbraco web install. I could'n’t find the correct version of System.Web.Extension. Quick question for Uncle Google pointed me to <a href="http://umbraco.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=23321" target="_blank">Umbraco-Codeplex</a> where there are an updated web.config file for .NET 3.5 gotcha. Finally the installation could start and now I have just created my first sample site with Umbraco, sure hope things gets a little bit easier in the future, but as some of the sites about Umbraco says, the downside really is the documentation, you got my vote for that.</p>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com1tag:blogger.com,1999:blog-437182615891217902.post-87201895842888297372009-11-11T12:43:00.001-08:002009-11-14T16:04:54.214-08:00The Start Of My CMS Era<p>So today is the where I’ve decided to start using CMS. Actually I have for a long period of time wanted to try out a CMS system, as I think it is a must to know one. Well at JAOO this year I saw a presentation of Umbraco, presented by Niels Hartvig. So the obviously choice of mine is Umbraco. Beside Umbraco I have looked at Joomla and Drupal, two great system based on PHP.</p> <p>Well I have to make a chioce and for a start I decided to go with Umbraco. I will try to write some of my wxpirences as I go along the development of two, for the moment secret sites :).</p>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-43492713592117626022009-11-04T12:37:00.001-08:002009-11-04T12:38:08.270-08:00The simplicity pattern<blockquote> <p>Wow I wrote the word pattern, well a pattern for your brain that you must adopt imediatly. Every developer including myself tends to implement really cool, really complex solutions to every possible simple problem we can find. We just need to. Well I want to get rid of this “thing”. Try to keep both feeds to the ground at rethink what the solution should be to meet the customer.</p></blockquote> <p>During the current project i’m working on at work, I have been inspired by Domain Driven Design, DDD. well mr. DDD is quite a big topic to get started with and the question is maybe how and howmuch should you really adopt. Is it like SCRUM all or nothing to get value for money, after all new things comes at a price. </p> <p>Yesterday I found this great DDD <a href="http://dddstepbystep.com/" target="_blank">website</a>. And somewhere deep inside I found a bundle of blogposts that wrap some of the DDD terms in a single well written <a href="http://dddstepbystep.com/r.ashx?2" target="_blank">PDF</a>.</p> <p>One part the is really interesting is the should you do DDD? after all it depends on the complexcity of the domain, and I think that if you just tries to implement some og the concepts you would automatically start to think in terms of DDD, and get some really nice brain-games, you start to thing and understand the business you are creating a solution for.</p>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-45219536591954107942009-11-03T16:11:00.001-08:002009-11-04T12:38:51.686-08:00How To Unittest Entities<p>So tonight I have been refactoring some of my code again. I’m trying to get a better domainmodel with real entities, ones that have an Id. Now the problem for me was that I handed out the responsibility of generating id´s for entities to NHibernate, like this:</p> <div id="codeSnippetWrapper"> <div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;" id="codeSnippet"><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum1" style="color:#606060;"> 1:</span> <id name=<span style="color:#006080;">"ObjectIdentity"</span> column=<span style="color:#006080;">"Id"</span> type=<span style="color:#006080;">"System.Guid"</span> unsaved-<span style="color:#0000ff;">value</span>=<span style="color:#006080;">"00000000-0000-0000-0000-000000000000"</span>></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum2" style="color:#606060;"> 2:</span> <generator <span style="color:#0000ff;">class</span>=<span style="color:#006080;">"guid.comb"</span>/></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum3" style="color:#606060;"> 3:</span> </id></pre><!--CRLF--></div></div><br /><p></p><br /><p>The problem with this is unittesting. How to I make a unittest where I have no repository with a database? Whoops did anyone say persistence ignorance :)</p><br /><p>I want to create an instance of a Company I can’t just use it’s contructor as this would give me an invalid entity, one with no Id assigned. After some reading with uncle Google I thought the answer was to let the application generate the id´s and not NHibernate, but further reading told me NOT to. The was some caching/performance issues when NHibernate is not in controle of id assignment. Further I didn’t like the concept, there must be another solution. Suddenly it stroke me, I’m already using Dependency Injection, thats the answer. Well how should I do this? First some code then an explanation :)</p><br /><div><br /><div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;" id="codeSnippet"><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum1" style="color:#606060;"> 1:</span> <span style="color:#0000ff;">public</span> <span style="color:#0000ff;">class</span> Company</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum2" style="color:#606060;"> 2:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum3" style="color:#606060;"> 3:</span> <span style="color:#0000ff;">private</span> Guid id = Guid.Empty;</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum4" style="color:#606060;"> 4:</span> </pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum5" style="color:#606060;"> 5:</span> <span style="color:#0000ff;">private</span> Company()</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum6" style="color:#606060;"> 6:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum7" style="color:#606060;"> 7:</span> <span style="color:#008000;">//nhibernate uses this one </span></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum8" style="color:#606060;"> 8:</span> }</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum9" style="color:#606060;"> 9:</span> </pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum10" style="color:#606060;"> 10:</span> <span style="color:#0000ff;">internal</span> Company(<span style="color:#0000ff;">string</span> name)</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum11" style="color:#606060;"> 11:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum12" style="color:#606060;"> 12:</span> <span style="color:#008000;">//....store name etc. </span></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum13" style="color:#606060;"> 13:</span> }</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum14" style="color:#606060;"> 14:</span> </pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum15" style="color:#606060;"> 15:</span> <span style="color:#0000ff;">internal</span> <span style="color:#0000ff;">void</span> AssignId(Guid id)</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum16" style="color:#606060;"> 16:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum17" style="color:#606060;"> 17:</span> <span style="color:#008000;">//sanity check</span></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum18" style="color:#606060;"> 18:</span> <span style="color:#0000ff;">if</span>(<span style="color:#0000ff;">this</span>.id == Guid.Empty || id == Guid.Empty)</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum19" style="color:#606060;"> 19:</span> <span style="color:#0000ff;">throw</span> <span style="color:#0000ff;">new</span> InvalidOperationException(<span style="color:#006080;">"Entity already has an id and id can not be empty"</span>);</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum20" style="color:#606060;"> 20:</span> <span style="color:#0000ff;">this</span>.id = id;</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum21" style="color:#606060;"> 21:</span> }</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum22" style="color:#606060;"> 22:</span> }</pre><!--CRLF--></div></div><br /><div> </div><br /><div id="codeSnippetWrapper"><br /><div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;" id="codeSnippet"><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum1" style="color:#606060;"> 1:</span> <span style="color:#0000ff;">public</span> <span style="color:#0000ff;">class</span> CompanyAggregate</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum2" style="color:#606060;"> 2:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum3" style="color:#606060;"> 3:</span> <span style="color:#0000ff;">private</span> <span style="color:#0000ff;">readonly</span> IRepository<Company> companies;</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum4" style="color:#606060;"> 4:</span> </pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum5" style="color:#606060;"> 5:</span> <span style="color:#0000ff;">public</span> CompanyAggregate(IRepository<Company> companies )</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum6" style="color:#606060;"> 6:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum7" style="color:#606060;"> 7:</span> <span style="color:#0000ff;">this</span>.companies = companies;</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum8" style="color:#606060;"> 8:</span> }</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum9" style="color:#606060;"> 9:</span> </pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum10" style="color:#606060;"> 10:</span> Company CreateNewCompany(<span style="color:#0000ff;">string</span> name)</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum11" style="color:#606060;"> 11:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum12" style="color:#606060;"> 12:</span> Company company = <span style="color:#0000ff;">new</span> Company(name);</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum13" style="color:#606060;"> 13:</span> companies.Add(company);</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum14" style="color:#606060;"> 14:</span> <span style="color:#0000ff;">return</span> company;</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum15" style="color:#606060;"> 15:</span> }</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum16" style="color:#606060;"> 16:</span> }</pre><!--CRLF--></div></div><br /><div> </div><br /><div id="codeSnippetWrapper"><br /><div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;" id="codeSnippet"><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum1" style="color:#606060;"> 1:</span> <span style="color:#0000ff;">public</span> <span style="color:#0000ff;">interface</span> IRepository<T></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum2" style="color:#606060;"> 2:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum3" style="color:#606060;"> 3:</span> <span style="color:#0000ff;">void</span> Add(T entity);</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum4" style="color:#606060;"> 4:</span> T Get(Guid id);</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum5" style="color:#606060;"> 5:</span> <span style="color:#0000ff;">void</span> Delete(T entity);</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum6" style="color:#606060;"> 6:</span> ICollection<T> FindAll(T entity);</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum7" style="color:#606060;"> 7:</span> }</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum8" style="color:#606060;"> 8:</span> </pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum9" style="color:#606060;"> 9:</span> <span style="color:#0000ff;">public</span> <span style="color:#0000ff;">class</span> CompanyRepository : IRepository<Company></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum10" style="color:#606060;"> 10:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum11" style="color:#606060;"> 11:</span> <span style="color:#0000ff;">public</span> <span style="color:#0000ff;">void</span> Add(Company entity)</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum12" style="color:#606060;"> 12:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum13" style="color:#606060;"> 13:</span> entity.AssignId(Guid.NewGuid());</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum14" style="color:#606060;"> 14:</span> }</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum15" style="color:#606060;"> 15:</span> </pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum16" style="color:#606060;"> 16:</span> <span style="color:#0000ff;">public</span> Company Get(Guid id)</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum17" style="color:#606060;"> 17:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum18" style="color:#606060;"> 18:</span> <span style="color:#0000ff;">throw</span> <span style="color:#0000ff;">new</span> NotImplementedException();</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum19" style="color:#606060;"> 19:</span> }</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum20" style="color:#606060;"> 20:</span> </pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum21" style="color:#606060;"> 21:</span> <span style="color:#0000ff;">public</span> <span style="color:#0000ff;">void</span> Delete(Company entity)</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum22" style="color:#606060;"> 22:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum23" style="color:#606060;"> 23:</span> <span style="color:#0000ff;">throw</span> <span style="color:#0000ff;">new</span> NotImplementedException();</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum24" style="color:#606060;"> 24:</span> }</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum25" style="color:#606060;"> 25:</span> </pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum26" style="color:#606060;"> 26:</span> <span style="color:#0000ff;">public</span> ICollection<Company> FindAll(Company entity)</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum27" style="color:#606060;"> 27:</span> {</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum28" style="color:#606060;"> 28:</span> <span style="color:#0000ff;">throw</span> <span style="color:#0000ff;">new</span> NotImplementedException();</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum29" style="color:#606060;"> 29:</span> }</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum30" style="color:#606060;"> 30:</span> }</pre><!--CRLF--></div></div><br /><p>Okay, the code is just to show the concept, not to be ready for production :)</p><br /><p>Well the concept is that a CompanyRepository is created for Test, this could be done using some mocking tool, but the key point is that it is the responsibility of the repository to assign an Id to an entity, same thing as if the id is assigned using nhibernate and some id generator. And when working inside the domain, all new companies should only be created using the aggregate.</p><br /><p>It is very important to notice that the visibility of the company entity is private and internal, the private is because of nhibernate, and the internal is for me to be able to make tests. This isolates the id assignment to a very narrow part of the domain. Some might say there is still a chance that this might break as the id is assigned “later”, but I would still give it a Go. </p>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-51158270231841428072009-10-07T13:51:00.001-07:002009-10-07T13:57:18.651-07:00JAOO 2009 Finalizer<p>So today was the last of 3 days at JAOO 2009 in Aarhus. 3 days to fill your head with a lot of cool technical information from a lot of great speakers. My output from the conference and what I will follow up on in the future are:</p> <ul> <li>NServiceBus – nice messaging and cool presenration by Udi Dahan</li> <li>Umbraco – Just need to try out this cool CMS tool. I think Niels did a great job and actually managed to get a lot done in a short time, this could have something to do with a good CMS?</li> <li>REST – A topic that caught my attention, and added a book to the bookshelf.</li> <li>Agile / Pattern / Effectivity - don´t know how to seperate some of the tracks, Martin Fowler, some Leads/architects just managed to inspire in how to do your job, coache your colleauges, living in a non agile organization.</li> <li>Windows AZURE and SQL AZURE – MS in the colud :) Cloud was a hot topic at the conference, and AZURE was one of the tracks. At first glance it seems very cool and quite simple using WebRole and Worker Role, but when you dive into it, it makes you think really think. There are some limitations for instance SQL AZURE has limitation at 10 gb, some “keys” must be strings etc. I just think you have to read more about it and really think about the design of a solution using the AZURE platform. But one cool thing and simple thing to understand was instance scaleability, you just increment the number of instances for serveres in your config, and whoola you have scaled (think you should pay first ;) ). But AZURE for sure makes topics like REST and messaging really hot.</li> <li>Functional programming – Might not be a topic I will get my hands on at first, but who knows. After all Mads Torgesen did a great F# presentation and discussion at the ANUG meeting. </li> <li>NHibernate – Ayende himself presented some cool NHibernate stuff and talked about the development cycle of NHibernate profiler, Oh boy has he made a great framework for developing this cool tool. How he could add features to the tool in minutes, just to crazy!</li> <li>Google datacenter – Wow wild wild buildings with way to much power and cooling indside, nice to see where all my “googeling” goes, might be in container "#7856 :)</li></ul> <p><strong><em>What about Gadgets…</em></strong></p> <p>Well well ofcourse where developers are the gadgets are and the exhibitors had a lot of stuff with them, I got a small Airgun :).</p> <p>And I got this in a google hosted competition:</p> <p><a href="http://images.google.dk/imgres?imgurl=http://12voltsolarpanels.net/foto/Products/Solio-Classic-Solar-Charger.jpg&imgrefurl=http://www.mad4mobilephones.com/solar-cell-phone-chargers-a-green-way-to-charge-your-mobile-phone/2879/&usg=__Fmi0N2Y5YkwidRpVVuq47WcpZmY=&h=336&w=336&sz=11&hl=da&start=68&tbnid=KwZluC0DKZNLLM:&tbnh=119&tbnw=119&prev=/images%3Fq%3Dgoogle%2Bsolar%2Bcharger%26gbv%3D2%26ndsp%3D18%26hl%3Dda%26sa%3DN%26start%3D54" target="_blank">Mobile Solar Charger</a> nice little tool, just need some sun to test it :)</p> <p><em><strong>…Any books?</strong></em></p> <p>Oh yes inspired by the speakers, and to help me better understand some of the areas in which I will look further into I bought these two books:</p> <p><a href="http://www.compman.co.uk/scripts/browse.asp?ref=786563" target="_blank">Applying Domain-Driven Design & Patterns</a></p> <p><a href="http://www.compman.co.uk/scripts/browse.asp?ref=107406" target="_blank">Effective REST Services via .NET: For .NET Framework 3.5</a></p> Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-87647192845841552472009-10-02T14:40:00.001-07:002009-10-02T14:40:48.766-07:00How To Save Time Writing your Presentationmodel<p>Inspired by this <a href="http://msdn.microsoft.com/en-us/magazine/ee236638.aspx" target="_blank">article</a> about how to use DTO and seperate your domainmodel from the client in a presentationmodel, I started rewriting some of my code. </p> <p>But what have always bin a real pain in the a.. , is writing DTO´s for seperation concern between layers.</p> <p>Again a good colleauge of mine told me about <a href="http://automapper.codeplex.com/" target="_blank">AutoMapper</a>. A component for doing “object to object” mapping easily. Yesterday I couldn’t see the light, today I’m just blessed by the power of AutoMapper.</p> <p>I was just about to write my own mapper, when I found AutoMapper. By default you just provide a source and target object e.g. Domain object and DTO and AutoMapper will map by properties. Say you have a Customer.Name will automatically map to CustomerDTO.Name. Now thats what I call a real timesaver.</p> <p>And did I mention it has a lot of other features for configuration all of which can be done by Fluent, just to please Resharper.</p> Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com1tag:blogger.com,1999:blog-437182615891217902.post-46218325100119629622009-09-30T13:19:00.001-07:002009-09-30T13:19:23.497-07:00Save keystrokes with know commands in Reharper<p>I’m almost getting comftable with resharper. And today A colleauge of mine just showed me how to reduce keystrokes in a Resharper command. If you want to lookup a type of file or anything else, You can make use of uppercase typing, meaning if you have a type called GoldCustomer you can just hit (ctrl + n) and type GC. A nice little feature . </p> Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-58969346001205214442009-09-29T14:05:00.001-07:002009-09-29T14:13:51.928-07:00Register and resolve generic types with Castle Windsor<p>If you implement repositories using a generic type T, you can use a simple resolving technic in Castle Windsor. Instead of specifying every type like:</p> <div id="codeSnippetWrapper"> <div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;" id="codeSnippet"><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum1" style="color:#606060;"> 1:</span> Container.Register(Component.For<IRepository<Service>>()</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum2" style="color:#606060;"> 2:</span> .ImplementedBy<NHibernateRepository<Service>>());</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum3" style="color:#606060;"> 3:</span> Container.Register(Component.For<IRepository<Employee>>()</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum4" style="color:#606060;"> 4:</span> .ImplementedBy<NHibernateRepository<Employee>>()</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum5" style="color:#606060;"> 5:</span> .LifeStyle.Transient);</pre><!--CRLF--></div></div><br /><p>But the is a more simple approach where you don´t have to specify each actual implementation, where you just tell Windsor that it is a generic type:</p><br /><div id="codeSnippetWrapper"><br /><div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;" id="codeSnippet"><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum1" style="color:#606060;"> 1:</span> Container.Register(</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum2" style="color:#606060;"> 2:</span> Component.For(<span style="color:#0000ff;">typeof</span> (IRepository<>))</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum3" style="color:#606060;"> 3:</span> .ImplementedBy(<span style="color:#0000ff;">typeof</span> (NHibernateRepository<>))</pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; direction: ltr; border-top-style: none; border-left-style: none; overflow: visible; padding-top: 0pxfont-family:'Courier New', courier, monospace;font-size:8pt;color:black;"><span id="lnum4" style="color:#606060;"> 4:</span> .LifeStyle.Transient);</pre><!--CRLF--></div></div><br /><p>And you just saved yourself from a lot of typing. But keep in mind that people might request just anything the want, so to keep in control of what should accepted you might shield your implementation with a “…: Where T….” to encapsulate which types should be accepted.</p>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-31162208691519608742009-02-09T12:37:00.000-08:002009-02-09T12:39:34.773-08:00Tip #3 - JQuery PerformanceAs I think I'm not the only one doing JQuery at the moment I want to share this small pice of important information regarding performance.<br /><br /><a href="http://jquery-howto.blogspot.com/2009/02/5-easy-tips-on-how-to-improve-code.html">JQuery Performance tips</a>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-18180692473871125752009-02-03T14:49:00.000-08:002009-02-03T15:14:39.457-08:00Tip #2 - JSON and MVC goes hand in handAs I needed to use some json for an ASP.NET MVC application, I looked at and old sandbox project, that used som EXTJS json implementation. But along come a good frien of mine, mr. google :)<br />I asked him about "jquery json" and he told me <a href="http://geekswithblogs.net/michelotti/archive/2008/06/28/mvc-json---jsonresult-and-jquery.aspx">this</a>.<br />How simple can it be, just another kick into the great place of ASP.NET MVCand JQUERY.<br />In short terms you simple uses JsonResult instead of the default ActionResult, which is part of System.Web.Mvc. As return of the controller action you call return Json(yourdata).<br />Simple, great, just what I needed to know and didn't find else where.Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-42971184880070791682009-01-26T15:08:00.001-08:002009-01-26T15:21:45.590-08:00Tip #1: NHibernate Parent/Child relationTrying to make a NHibernate parent Child relation, there is one important note about keeping the bidirectional setting up to date. The relationship is not created automatically.<br /><span style="font-weight: bold; color: rgb(255, 255, 153);">Not working</span><br /><span style="font-size:85%;"><span style="color: rgb(153, 255, 153);font-family:courier new;" >var repo = new Repository<company>(); </company></span><span style="color: rgb(153, 255, 153);font-family:courier new;" > </span><br /><span style="color: rgb(153, 255, 153);font-family:courier new;" >MembershipUser currentUser = Membership.Provider.GetUser("John", true);</span><br /><span style="color: rgb(153, 255, 153);font-family:courier new;" >Employee employee = new Employee() { UserId = (Guid)currentUser.ProviderUserKey }; </span><br /><span style="color: rgb(153, 255, 153);font-family:courier new;" >Company company = new Company() { Name = "my company" }; </span><span style="color: rgb(153, 255, 153);font-family:courier new;" ><br />repo.Add(company);<br /><span style="color: rgb(255, 0, 0); font-weight: bold;font-size:100%;" >company.Employees.Add(employee);</span><br />......<br /><span style="color: rgb(255, 255, 153); font-weight: bold;font-family:times new roman;font-size:100%;" >Solution</span></span></span><br /><span style="font-size:85%;"><span style="color: rgb(153, 255, 153);font-family:courier new;" >var repo = new Repository<company>(); </company></span><span style="color: rgb(153, 255, 153);font-family:courier new;" > </span><br /><span style="color: rgb(153, 255, 153);font-family:courier new;" >MembershipUser currentUser = Membership.Provider.GetUser("John", true);</span><br /><span style="color: rgb(153, 255, 153);font-family:courier new;" >Employee employee = new Employee() { UserId = (Guid)currentUser.ProviderUserKey }; </span><br /><span style="color: rgb(153, 255, 153);font-family:courier new;" >Company company = new Company() { Name = "my company" }; </span><span style="color: rgb(153, 255, 153);font-family:courier new;" ><br />repo.Add(company);</span></span><br /><span style="font-size:85%;"><span style="color: rgb(153, 255, 153); font-weight: bold;"><span style=";font-family:courier new;font-size:100%;" ><span style="color: rgb(255, 0, 0);">Company.AddEmployee(employee)</span></span><span style="font-weight: bold;"><br />......<br /></span></span></span><span style="color: rgb(0, 0, 0);"><span style="font-size:100%;"><span style="font-family:times new roman;"><span style="color: rgb(255, 255, 255);">So you need to make relation kind of manually. This implementation of AddEmployee looks like this:</span><br /><span style="color: rgb(153, 255, 153);font-family:courier new;font-size:85%;" >public void AddEmployee(Employee employee)<br /> {<br /> this.employees.Add(employee);<br /> employee.Company = this;<br /> }</span><br /></span></span></span>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-21699466938948739812009-01-06T02:11:00.001-08:002009-01-06T02:28:53.063-08:00Review: Agile Thinkingfinally during christmas I finished the book "Agile Thinking Leading Successful Software projects and teams", by David Churchville. It is one among many agile books around at the moment. But this book is a different in the way it is written. It is not just a basic agile book telling you to do this and this to become agile. It addresses some practical daily issues and not just theory. Thats what makes this book so great. working in a company where we are introducing scrum and some agile principles, the book confronted me with some of the issues at work.<br />Besides the topic of the book, The book itself is well written, easy to read and only 116 pages.<br />I recommend this book for people interested in agile and scrum.<br /><br /><a href="http://www.lulu.com/content/1631745">Find the book here</a>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-76395202266646824542008-12-08T11:50:00.000-08:002008-12-08T12:16:02.948-08:00The definition of done, from a galaxy far far awayAt the moment I'm reading a very pragmatic book about agile software development, "Agile Thinking". During reading I found a very good phrase for done!. It's one of if not the most important for a team in an agile development project, to say Done! Which means ready for ship, But as the phrase in the book says, or Yoda from Starwars<br />"<span style="font-weight: bold; font-style: italic;">Done or not done, there is no almost</span>".Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-5917560992697736942008-12-04T13:04:00.000-08:002008-12-08T12:16:56.442-08:007 Rules To Do Better Agile DevelopmentJust a <span class="blsp-spelling-error" id="SPELLING_ERROR_0">short</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_1">description</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_2">of</span> 7 <span class="blsp-spelling-error" id="SPELLING_ERROR_3">rules</span> by <span class="blsp-spelling-error" id="SPELLING_ERROR_4">the</span> Agile guru Mike <span class="blsp-spelling-error" id="SPELLING_ERROR_5">Cohn.</span><br />It <span class="blsp-spelling-error" id="SPELLING_ERROR_6">esplains</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_7">how</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_8">the</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_9">Product</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_10">Owener</span> and team <span class="blsp-spelling-error" id="SPELLING_ERROR_11">togehter</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_12">makes</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_13">the</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_14">customers</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_15">satisfied</span>.<br /><a href="http://www.mountaingoatsoftware.com/search?q=WantBetterSoftware.pdf"><br />http://www.mountaingoatsoftware.com/search?q=WantBetterSoftware.pdf</a>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-17078703798540502652008-10-13T13:09:00.000-07:002008-10-13T13:48:58.584-07:00A windows developer in a web 2.0 world - Challenge yourselfSometimes things just becomes something you do every day. What happens? You start to make a cirkular reference to your self, every day looks like the day before and so forth. <div>I just had such a day, and wanted to break out of this pattern. I got stucked in a world of windows development, and saw a world of web drive by through the window. Stop! Challenge me :)</div><div>So I did, I converted a project from windows to web. But to make it something real fancy, possible a little to the alpha side, I used the latest .NET web technology ASP.NET MVC.</div><div>I played a little bit win webforms in ASP.NET, but ASP.NET MVC really got me hooked. A nice framework currently in preview 5, hope it soons becomes official, maybe at TechED, who knows?</div><div><br /></div><div>Well the project started out quite well, I looked at the controller view and model, actually quite easy to use. Put on some basic controls, and played with the ASP.NET membership provider that comes along with preview 5. at <a href="http://asp.net/mvc">http://ASP.NET/MVC</a> there are some really good toturials, else look at <a href="http://weblogs.asp.net/Scottgu/">Scott Gu blog</a>. </div><div>Well time went on and I got control of some of the basic css rules, last time I was hooked on web development was when the only way to control your layout was to use nested tabels, alias tabel Hell, similar to dll hell in a windows world :).</div><div>I created a simple form to create some employees and needed to display them in a table/grid, dragged a basic asp.net form grid, and..... no go. What I can't use std. controls #%&¤"""""""% and the f word!</div><div>After some googling (In chrome), it was clear I had to find some javascript grid, hmmmm EXTJS, the greatest javascript widget library I have ever seen. I found the source and a couple of hours later I was up and running ASP.NET MVC, EXTJS using JSON.</div><div><br /></div><div>Thats deffinently a success to me a windows man working in a web 2.0 world ;) ths is a tst</div>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-63298273371964886232008-09-30T14:38:00.000-07:002008-09-30T15:31:48.002-07:00JAOO day IISecond day at JAOO started out with a keynote presentation og Googles brand new V8 engine used insise the Google Chrome. The presentation was presented by Lars Bak, and boy could he get into the details :) from JavaSript to Assembler. A really facinating presentation shoving how they are dynamically creating classes based on the javascript code, pay the penalty first time a "function" is created by creating an "initializer" class and for properties and values on the class they somehow creates other classes......hmmmm maybe i'm not as goog as Lars Bak to present the subject, the answer is, go check out a presentation of V8 if you have the oppertunity.<br /><br />The rest of my day went listining to the following tracks:<br /><br /><strong><span style="color:#ffcc33;">[ How Cool do users feel when interacting with your software ]</span></strong><br /><em>Basically this track had the message "Think out of the box". Maianne presented a lot of non software examples of how people interacts with different hardware, for instance a coke softdrink machine, imagine a person making the exact same actions as this machine with the goal of deliver a coke to you. First you hand over some money, second you push/tells what kind of drink to get, next the person makes some noise and bends down, before he shakes your coke and servers it to you ;0).</em><br /><br /><em>As with most of the other examples a baic diciplin was to get rid of devices such as a mouse and a keyboard. One of the really cool, yet not ready for market, was a wall in the bathroom you could press your body against. The front of your refregerator would the eflect the presure, I most admit the woman on the picture did a great job.</em><br /><br /><strong><span style="color:#ffcc33;">[ The power of Retrospectives ]</span></strong><br /><em>So far this has been one of the best tracks, Linda Rising just have a gift of a story teller inside. How she came from a simple story about Winnie the pooh and into software projects. She made is so clear why we should make retrospectives. Somehow retrospectives have not been a defacto in the software industry, but with Linda in the market I think it'll be, if not now, then in a short time.</em><br /><br /><strong><span style="color:#ffcc33;">[ Architecture of RIA ]</span></strong><br /><em>Rich Internet Applications was the track I followed all afternoon, starting out with the architecture of RIA, and a lot of samples. It seemed like a good track together with the user expirence track earlier today. Technically the track explained where we are today with typically desktop applications and web applications, and where the road of RIA leads to. </em><br /><br /><em>Oh boy Oh boy this lid a fire of ideas inside my brain. The products demostrated was Microsoft Silverlight and Flex/Air from Adobe. I think most of this track was a good teaser for the next two tracks, each covering each of the technologies alone.</em><br /><br /><strong><span style="color:#ffcc33;"><em>[ Adobe Flex/Air]</em></span></strong><br /><em>Let me just say this was the technically most cool presentation I have seen so far at JAOO. I think this is what a neard like me would call beautiful :) How simple it was to create an enduser application showing all sorts of pictures from flicker, just by adding some simple components. It seems like Adobe have a product I have to investigate some more, and after all you can still use .NET at the backend.</em><br /><br /><span style="color:#ffcc33;"><strong>[ Silverlight ] [When PNG became XBAP, NOT! read on....]</strong> </span><br /><em>Stop hold, you get the red card. What just happen here? The Microsoft guy which I thought would battle the Adobe Flex with Silverlight totally missed what ever he should be presenting. He started out telling bla bla bla, took too many questions, and maybe it was time to start now? wow finally a demo, yet came another, another, another, hmmm where's the code? yet another ehhhh what going on here? 10 minutes left okay, can just show some more demoes.</em><br /><br /><em>So he went on presenting demoes with out getting technically like the Adobe guy, very boring and not selling the product at all. </em><br /><br /><em>The biggest mistake was proberly when he thought he was showing an xbap application, but when have xbap becomed png. Very embarassing to see a MS guy presenting this, I hope he just had a bad day, and as he started out earlier in the architure track, you should not be religious about your choice of technology, so lets pick up flex/air and for now drop silverligt into the cloud of donts :).</em><br /><br />Well this was all the tracks of the day, a great day. Finalized with some Wii Tenis and a great dinner at Svineriet in Århus. Now I just have to sort out how to decideRasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-85150372058696873572008-09-29T15:09:00.000-07:002008-09-30T15:32:15.204-07:00JAOO day IWow what a day, my first day at JAOO. Its been a very interesting day with a lot of interesting tracks and catch up with old collegues from Århus.<br /><br />The main topic of the day has been funtional programming presented by Anders Hejlsberg in th eopening keynote, or as Erik Meijer say "Fundamentalist functional programming", what a blow of a speech he could present. He knocked the last still active brain cells of the day to an outer galaxy whith all his philosophy about the topic, and who else would start out playing "Nirvana - Smells like teen spirit" .<br />Beside this "out of range" track with Erik, my day started out with a track about Continues Integration, really down to the basic, but actually usefull and well presented by Chris Read. The missing link for me was the "continues deployment", why not make a daily deployment to test of todays work, just as source forge or any other place to grap "nightly builds". Do this just as a pratice to traine the team in deployment. Next up was google Chrome track, really a sales speak about the new wonder :), can't wait to heat Lars Bak about V8. Then there was Glouding computer with Gregor Hohpe, yet another great speaker, explaining how to keep low of complexisity when programing for clouding, and finally showing how to use Google's API, DB and all the other goodies for developers like me, wanting to try out clouding and "BigTable" ths google Database wonder :). Finally I had one track about PowerShell, think you need to be a sys admin to keep track with that fellow. The last track "Impact of Enterprise 2.0 ...." think I missed the last part when my eyeslid closed :) NOT well presented.<br />But not to forget the last, and indeed very important topic for this conference networking, implemented with a good dinner at Ridehuset by Chili John, and finialised in hotel bar, what a great evening.Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-43238625325501033382008-09-16T13:01:00.000-07:002008-09-16T13:07:26.302-07:00The Retrospective StarfishDuring my expirence with SCRUM, I want to share one of the great tools I've been using for retrospectives, The Retrospective Starfish. A simple drawing that makes is simplify tracking of actions for retrospectives. The combination of post-it and the retrospective starfish on a whiteboard, makes it a great and effective tool for retrospectives.<br /><br /><span style="text-decoration: underline;">Check out the Starfish here</span>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-32449006963403039132008-09-16T12:51:00.000-07:002008-09-16T12:58:11.042-07:00It's almost like waiting for Santa on Christmas EveningJAOO is almost around the corner. From the 28th of and until the 1th of October I will be attending this years JAOO Conference in Denmark. I hope to get a lot of new inputs about new technology, and where existing technology is moving. And not to forget, networking with old colleges.Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com1tag:blogger.com,1999:blog-437182615891217902.post-8155620390981098182008-09-03T12:36:00.000-07:002008-09-03T12:44:56.230-07:00It's silver, it's gold, oh no wait it's.......CHROMELast night while reading some blogs I suddenly discovered a new link at google search, "CHROME beta, download". Hmmm what could that possible be. Google already have a bunch of really nice applications and service, like docs, Calendar GMail, Apps and so on.<div>Just one thing to do Download. And fianally I saw it, the new child in the google family, a web browser. Not just a ordinary webbrowser, but a new one based on googles until now secret javascript engine V8.</div><div>And now almost a day after I have used CHROME with a smile on my face. It's fast, It's light It's CHROME. I only had one crash last night, after all it is a beta, but not just any kind, I actually got a nice message tellling me "Ooops your browser .....". Count me in on the details. </div><div><br /></div><div>Get the new CHROME here:</div><div><a href="http://www.google.com/chrome/index.html?hl=da&brand=CHMG&utm_source=da-hpp&utm_medium=hpp&utm_campaign=da">http://www.google.com/chrome/index.html?hl=da&brand=CHMG&utm_source=da-hpp&utm_medium=hpp&utm_campaign=da</a><br /></div><div><br /></div>Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0tag:blogger.com,1999:blog-437182615891217902.post-27916758642205672562008-09-01T13:02:00.001-07:002008-09-03T12:24:39.221-07:00Who is the "Alpha male" on your team?One of the great things about using SCRUM for development is the great team spirit, you are "one" or zero, a team or a disaster, part of he binary world.<br />But to become this team you need to support different roles, and this is where you meet the "Aplha male". Actually he is just a developer, but what drives him is his interest in always wanting to try out new opportunities, to keep your project on the top of the new technology. A typically indication of the Alpha male could be this comment in the daily SCRUM: "<span style="font-style: italic;">..Okay, have you heard about this new database service? It is so great, really fantastic. If we just implement this it will save us for a bunch of work. It's so great it can do all we need to do and also a lot more :). We can't wait to grap and integrate it into production.."</span> .<br />And this is where you as part of exactly the same team need to act as a team. You need to cool down for a moment from the excitement about this new component. When the Alpha male stops talking you start to ask. But do not hide the excitement in your voice as you speak as this will be disregarding your team member, after all everybody trust each other to be the best at what they are doing.<br /><ul><li>Wow this sounds great, but what is the state of this new component?</li><li>Is it something we are allowed to release yet?</li><li>How does it actually perform, have you tried it?</li><li>How much need to be refactored to integrate it?</li><li>So what is the ROI?</li><li>Current state, is it alpha, beta, CTP etc.</li></ul>What you decide to do is up to the team.<br />The key point in this is that almost every team has this Alpha male, and you need to be aware of it, as is might be crucial to the success of your project, whether you make a success or a failure, back to the basics.<br /><br />And please apologize for the use of male where it could as well be female, it just sounds greater :)Rasmushttp://www.blogger.com/profile/04165050459629378055noreply@blogger.com0