Tonight We Raid Calais - OpenCalais Tools .. Coming Soon

I have been quiet of late as I have been working on a Open Calais parser tool to enable people to work effectively with open calais output - the output is fairly complex RDF and my little tool should allow quick extraction of terms and values so you can plug open calais into your .NET apps etc. Its been a sharp learning curve in terms of how RDF works (and how to parse it)  but the results now are working rather nicely.

I felt some of the other taggers / parsers let a lot great data slip by as they were just concentrating on the tags (which is fine and is probably what you want) but there can be a lot of rich relationships stored in the documents (such is the joy of RDF) and I wanted to enable people to get at that data if they wanted (which is why it took so bloody long hehe)

Quick sneak preview as you can see .. all entities resolve to real .NET objects populated with all the data and values.

It is on the sanity check stage and I will post some info about it very soon (I am tempted to write a live writer plugin but I think thats me getting disctracted and I just need to get the core thing finalised).

This may all be pointless work and Ive spent too much time getting it to extract data no one wants but it turned into a personal challenge so I had to finish it hehe :P

 


Posted by: [mRg]
Posted on: 3/31/2008 at 12:58 PM
Tags: ,
Categories: General
Actions: E-mail | Kick it! | DZone it! | del.icio.us
Post Information: Permalink | Comments (0) | Post RSSRSS comment feed

Ladies wot Launchball - Launchball wins big at SXSW

Well I nearly fell out my seat when I heard that Launchball had won best game at SXSW and was even more suprised when I scrolled down and found it had won 'Best In Show' (almost like Crufts but with more gadgets). I was smiling all the way home knowing that something I had been so directly involved with makes so many people pleased.

As I said before the main kudos has to go to the amazing hard work of Henry @ Preloaded for an outstanding job creating the game engine. My work involved plumbing the underbelly, creating the web services that communicate with the flash, the Sitecore CMS and the underlying databases so to give the science musuem the freedom to create the type of system they wanted for the users.

I had a quick poke in the database and current data is as follows:

91501 Registered Users
57927 Custom Levels have been created so far

.. eek! Poor server :)


Posted by: [mRg]
Posted on: 3/11/2008 at 5:22 PM
Tags: , , , ,
Categories: General
Actions: E-mail | Kick it! | DZone it! | del.icio.us
Post Information: Permalink | Comments (0) | Post RSSRSS comment feed

No Country for Old Browsers - IE8 Beta1

Well.. here I am .. running in IE8 , freshly released, along with a host of other goodies, from MIX08 happening right now somewhere in Las Vegas. Ive never really got on with Firefox .. I know, I know  .. shoot me .. but I find the temptation to install all those plugins a bit too much and soon poor firefox is crawling to a halt. So I was quite excited to get my hands on IE8.

Developer Tools 

At first I thought they had just included the regular developer toolbar into the main program but on further investigation the developer tools they've added have some very powerful features and should make many developers very happy (me included!) 

You will now find a lot of the debugging and CSS analysis features found in the new Visual Studio 2008 sitting in the 'Developer Tools' console.

Open it up and you find you can now set breakpoints in your javascript code the step through line by line

You can create watches, see autos and effect variables directly with the immediate console. All great stuff ! Also locating problems in CSS got a whole bunch easier (now I dont need have to switch back to Firefox just to use FireBug hehe)

Web Slices

One thing I quite like are the addition of Web Slices I just wanted to quickly note how to get them up and running :) As afr as I can see they are a way to wrap your normal feed in some custom HTML so it looks like it came from your site (so mine would have bad spelling and lots of transformers icons everywhere)

Its essentially creating a small piece of HTML within a page with the correct classes applied. IE8 then picks up these and allows you to subscribe to the 'slice' (jazzed up RSS)
(The important classes are in bold)  

<div id="myblogupdates" class="hslice" >
 <div style="display:none;">
 <a href="#" class="entry-title">Ultramagnus Blog Updates</a> ~
 <a href="#" class="entry-content">&nbsp;</a>
 <a href="http://www.ultramagnus.org/syndication.axd" class="feedurl" rel="feedurl">&nbsp;</a>
 </div>
</div>

 

If all is working, when you view the page you will see a new little swirly purple icon (where your RSS feeds normally appear) with the name of your WebSlice in it...

... clicking on the link will bring up a dialog asking if you want to subscribe to this webslice ..

.. once done the 'slice' will appear as a link in your toolbar.

You do need to tweak the code in your RSS feed to include a new namespace ..

<rss version="2.0"xmlns:mon="http://www.microsoft.com/schemas/rss/monitoring/2007">

 .. it will then use the HTML you defined originally to display the slice in the browser drop-down .. so you can now add a bit of personalisation your RSS feed :)

 


Posted by: [mRg]
Posted on: 3/5/2008 at 11:08 PM
Tags: ,
Categories: Guides
Actions: E-mail | Kick it! | DZone it! | del.icio.us
Post Information: Permalink | Comments (0) | Post RSSRSS comment feed

My Dina with Andre - Lurve those fonts ..

While I get stick in the office for my Visual Studio theme (Yes, I like a dark background, I'm old, my eyes hurt) one thing I must recommend is the Dina monospace font .. I started using it mainly for the output windows (black with a green font looks lovely!) but now its replaced Consolas as my IDE font of choice. I often remote desktop into work and Consolas, while being very nice, only looks very nice when using ClearType .. without ? .. freaking awful! I switched over to Dinas for my main font on a whim, loved it and havent looked back. Im sure another font will trump it one day but for now Ill stop rambling !

Dina Programming Font - by Jørgen Ibsen.

FYI - All my code snippets here use this font so if you want to see them how I intended please go, grab and install this right away (hey its only 1 file !) :)

( Some folks like Liberation which is a nice font too and worth checking out if your looking for some new fontage :P )


Posted by: [mRg]
Posted on: 2/7/2008 at 9:58 PM
Tags: ,
Categories: General
Actions: E-mail | Kick it! | DZone it! | del.icio.us
Post Information: Permalink | Comments (0) | Post RSSRSS comment feed

Mass Code Auto - Team City

Over the past week or so I have been trialing Team City from JetBrains (makers of Resharper et al). There has been a lot of buzz around this product and I wanted to include all the bits I had found and my thoughts on it as a product.

First a bit of background, as well as our development team we also have an application support team. Its imperative that they can get access to the latest, working builds of all our companies code. After our move to TFS we setup a series of team builds that people could run to produce DLLs / websites etc. on demand. This worked to a certain extent but wasnt perfect. A while ago we changed to running CI builds for our major projects using Cruise Control .NET and havent looked back.

CC.NET is a fantastic tool, we were able to get all the things we want, NUnit tests, code coverage (NCover), documentation generation (Sandcastle), code metrics etc but the bus factor is quite high (ie if the guy who maintains it gets run over by a bus then the rest of the team is screwed cause no one else knows how it works). The mass of XML and supporting files (BATs or MSBuild tasks) that had to be edited to get a new project up and running was quite frightening and most of the time you are copying the same config code various times. I was starting to write a large document on how to get CI up and running for new projects when I realised it was really quite stupidly complicated and began hearing good things about TeamCity.

The test I set for myself with TeamCity was  - Could I get all the things I had running with CC.NET running in TeamCity in less time and with less fiddling with config files ? The answer was suprisingly .. Yes !

The installation was very straight forward and I was up and running with zero issues. I chose a simple project to start off with, I created a source control root to monitor in TFS. The integration with TFS was seamless and posed no problems.

Next I began to setup the build. This takes the form of a 7 stage wizard ... nothing frightening here .. just common sense settings such as when you want a build to be triggered (scheduling is very nice), dependencies and runners (the things that will do the actual build). It comes with a mass of runners for Java and .NET.

For this simple setup I used the 'SLN2008' runner to build from a VS2008 Solution File in the root of my project and set it to build when i checked something in. 

NCover

I used the Ncover MSBuild tasks that come with the program .. pretty standard stuff .. one for a summary and one for a full report. Only one thing to note is that the NCover help file doesnt list the correct enum for genearting a full HTML report out so I had to get busy with Reflector to find that one ! (Its "FullCoverageReport" btw!)

<NCover ToolPath="$(NCoverPath)"
    CommandLineExe="$(NUnitPath)\nunit-console.exe" 
    CommandLineArgs="$(TestDll)" 
    CoverageFile="@(CoverageFile)" />

<!-- Summary Page -->
<NCoverExplorer ToolPath="$(NCoverPath)" 
    ProjectName="$(ProjectName)" 
    OutputDir="..\Docs" 
    CoverageFiles="@(CoverageFile)" 
    SatisfactoryCoverage="80" 
    ReportType="ModuleClassSummary" 
    HtmlReportName="CoverageSummary.html" 
    Exclusions="$(CoverageExclusions)" />

<!-- Full HTML Report -->
<NCoverExplorer ToolPath="$(NCoverPath)" 
    ProjectName="$(ProjectName)" 
    OutputDir="..\Docs\Coverage" 
    CoverageFiles="@(CoverageFile)" 
    SatisfactoryCoverage="80" 
    ReportType="FullCoverageReport" 
    HtmlReportName="Coverage.html" 
    Exclusions="$(CoverageExclusions)" />

The next thing to do was to declare the coverage as artifacts of the build in the configuration section of the build.

Docs/Coverage/* => Coverage,
Docs/Coverage/files/* => Coverage/files,
Docs/CoverageSummary.html

The final part (and this only has to be done once!) is to update the main config so it adds two tabs for the summary and the full report (Dont worry .. if the files arent there the tabs arent shown) 

Locate the TeamCity config file (\.BuildServer\config\main-config.xml) and add two entries.

<report-tab title="Code Coverage Summary" basePath="" startPage="CoverageSummary.html" />
<
report-tab title="Code Coverage" basePath="/Coverage/" />

 

Sandcastle

I used a pretty standard MSBuild task for Sandcastle but ran into one problem (nothing to do with TeamCity directly) .. it wouldnt run .. the script worked fine from Visual Studio, worked fine from the command line msbuild but wouldnt run when executed from within TC, one of the sandcastle tools MRefBuilder exits with Code 1 (helpful!).. turns out you need to remember to add DXROOT as an environmental variable to point to the sandcastle folder. 

 

.. and thats it ! All setup essentially in a few clicks .. the great thing is the tasks like adding tabs and setting environment variables only need to done once and now I can copy the configuration and futher reduce my setup times. More importantly, anyone in the team should be able to look at this config and see whats happening and tweak if needed. (Lets hope the bus thing doesnt happen quite yet though)

My experience with TeamCity, so far, has lived up to expectations .. and hopefully Ill be able to tweak it more as time goes on. Ive also found that the new vs2008 web deployment project gives a great framework for adding little MSBuild scripts even if your not used to using MSBuild .. but maybe ill blog about that another time as Im going off on a tangent ! 

Pros 

  • Most basic builds are created in a few clicks.
  • Duplicating build configuration is a single click - simple enough but this is really time saving.
  • Artifacts - This feature, i would imagine, is designed for those people whos projects produce MSI installers etc but as a web developer I found this gave me a nice persepctive on what the actual deliverables of a web project are. In the past a build would deliver the contents as a whole web dir but now ive found myself zipping up the different parts (bin dir / main site) which should will make it more maintainable for our support team as they can just grab the bits they need !
  • Custom tabs for different reports (NCover etc.)  - This means if i can add anything I want to as long as its added to my artifacts.
  • Personal Builds - Bah didnt have time to talk about this but its like a sort of gatekeeper .. you can get the TC server to build your new code changes and check they work before you officially check it in .. very cool !

Cons

  • Doesnt support triggering a TFS team build (as far as I can see, I had to use a custom plugin for CC.NET) - Not a huge issue but would be a nice-to-have. 

Posted by: [mRg]
Posted on: 2/1/2008 at 8:24 PM
Tags: , , , ,
Categories: Guides
Actions: E-mail | Kick it! | DZone it! | del.icio.us
Post Information: Permalink | Comments (0) | Post RSSRSS comment feed