Jun
26
2010

Jobping announcing StickyBeak

As said when we launched Jobping Open Source Short Urls Service, we at Jobping are committed to open source.

So last week we announced  StickyBeak, you might read more on the blog of Mark - Introduction to StickyBeak

StickyBeak is a logging tool for asp.net websites which logs information such as date, http method, url, User.Identity.Name, IP Address, unique session Id, unique browser Id, header values, querystring values, posted form values and cookie values for every request.

Here is a screenshot of the administration page,which lets you see the logged activity on your site.

StickyBeak is a complementary tool to the excellent elmah from Atif Aziz

We are using elmah on Jobping to log exceptions that might happen on the site, but we also wanted a raw record of each request made to our site, to make our troubleshooting life easier.

You can download the source and binaries from StickyBeak on CodePlex.

Jun
16
2010

Power of IntelliJ in video

Today I was listening and some time watching (it helps to have two monitors :) the following video that I got from Jetbrains blog post, Vaclav Pech Talking at JAX 2010

I learned several tips and I think this video shows why I like more and more IntelliJ.

If you missed Vaclav Pech speech at JAX 2010, here’s your chance to hear it right now. In this presentation he’s discussing common coding pitfalls such as possible NPE, unreachable code, and explains how they can be easily avoided.

Vaclav Pech at JAX 2010 from Egor Malyshev on Vimeo.

Jun
11
2010

From WPF functional Unit Tests to Specifications using MSpec and White

I am in the train back home and wanted to try out quickly to migrate our WPF functional tests written has Unit Tests to BDD Specifications.

Here is the code I started from, pure Unit Test using NUnit and White

[Test]
public void Opening_Valid_VersionZip()
{
    OpenAndWait("Product.zip");

    Assert.That(MainWindow.Title.Equals("Product.zip - Innoveo Skye® Editor"));
    Assert.That(Status.Text.Equals("product"));
    Assert.That(ProductTree.Nodes.Count >= 1);
    Assert.IsFalse(SplashScreen.Visible);
    Assert.IsTrue(SaveButton.Enabled);
    Assert.IsTrue(ActivateButton.Enabled);
}

Now the same functional test written as a BDD specification using MSpec

[Subject("OpenVersionZip")]
public class when_user_open_valid_versionzip : MainWindowViewSpecs
{
    Establish context = () => {};

    Because of = () => OpenAndWait("Product.zip");

    It should_display_mainwindow_title_correctly = () =>
        MainWindow.Title.ShouldEqual("Product.zip - Innoveo Skye® Editor");

    It should_display_status_correctly = () =>
        Status.Text.ShouldEqual("product");

    It should_display_the_product_tree = () =>
        ProductTree.Nodes.ShouldNotBeNull();

    It should_hide_the_splashscreen = () =>
        SplashScreen.Visible.ShouldBeFalse();

    It should_enable_save_button = () =>
        SaveButton.Enabled.ShouldBeTrue();

    It should_enable_activate_button = () =>
        ActivateButton.Enabled.ShouldBeTrue();
}

And the output in ReSharper MSpec plugin

4687909611_49a4e5a71a_o[1]

Which one do you prefer? I personally have made my choice.

Jun
4
2010

Build .NET projects from Windows Explorer using MSBuild Launch Pad (mPad)

In September 2009 I posted about a tool I am using to build my MSBuild projects from the shell “Build your .NET project with a right click in Windows Explorer

Last week I changed to MSBuild Launch Pad (mPad) which also add a context menu when you right click your project or solution files.

The added value for me is that it maintained project, 1.0 was released on May 21, 2010 with following release notes:

    • Support sln, csproj, vbproj, vcxproj, shfbproj, ccproj, oxygene and proj files execution.
    • Basic settings such as Show Prompt, and Auto Hide are provided.
    • MSBuild Shell Extension integration is achieved.

I also very much like that when I right click and say build I get the control on the .NET framework version I want to use and if it is a Release, Debug or what so ever.

4668737460_d5f6fd3791_o[1]

Nice little productivity booster tool.

Jun
3
2010

Build and Deployment automation, VCS Root and Labeling in TeamCity

As you might now from reading my blog I tend to automate as much as I can.

Why? Because I hate to do repetitive tasks. First because it is boring, at least for me, and as a developer we have more interesting things to do. Second because executing repetitive tasks tend to be error prone.

So last week I decided that it was enough for me to have to create manually a subversion tag for Jobpingweb site then also took the time to do the same for my portal Tech Head Brothers.

At Jobping we are using TeamCity and Subversion. We use it as our Continuous Integration system but also to deploy to production server in one click. Something I promised to talk later on in more details.

So it was relatively easy to configure TeamCity so that after build/deployment process it tags our subversion.

First of all, I realized only the other day the way TeamCity works with VCS root 

A VCS Root is a set of settings that defines how TeamCity communicates with a version control (SCM) system to monitor for changes and to get sources for a build.

We are using the convention of trunk, branches, tags in our Subversion server (which is the great Visual SVN Server). In the past I always set the TeamCity VCS Root to our myproject/trunk url, and I have seen lots of people doing so on different websites/blogs…

At this point I realized that I missed a point with TeamCity VCS Root is that it contains Root in it’s name. So I might be using myproject/ in place of myproject/trunk as the VCS Root. But wait, if I do that TeamCity agent will make a checkout of my whole Subversion repository!

And here comes the VCS Checkout rules, which you can configure on every project which is using the VCS Root

4663096481_231787d2d1_o[1]

So in my case it looks like that

4663731014_a4945d38d0_o[1]

Which specify that for that particular build I want to checkout from my VCS Root extended with trunk to the build folder /. So with that I restrict the checkout to the trunk. Good

Now back to my first topic, which was to automate the subversion tag creation when our build is successful which is done using TeamCity VCS Labeling.

Here is how we set it up for our staging build

4663125553_c725cbc3dc_o[1]

For sure we have another one for our production build.

And here is the result in Subversion

4663756592_592d22d287_o[1]

Another thing that I will not forget as it is automated

One last issue that I had which you see only if you register to get info about failed build in TeamCity is the following

[TeamCity, LABELING FAILED] Staging - CI Trunk, Unit Tests, Deploy #1072

Jetbrains.buildServer.vcs.VcsException:

Labeling the path 'trunk' to 'tags/staging-1072' has failed with the error: svn: MKACTIVITY of '/svn/!svn/act/7caf50f8-2801-0010-9e80-1fedd46c5a33': 403 Forbidden

With this error message it was then easy to figure it out. I just had to modify the access right of the build user to have read/write access right and not only read.

Jun
1
2010

Using Gmail as TeamCity smtp server

Some time ago when I had to reinstall our Jobping Continuous Integration server, which is Team City I also decided not to reinstall any smtp server but to use Gmail server.

Here is the configuration that I used, which worked perfectly for me

4656773327_09a7eed279_o[1]

Use SMTP port 465 and TLS (SSL) !

About Laurent

Laurent Kempé

Laurent Kempé is the editor, founder, and primary contributor of Tech Head Brothers, a French portal about Microsoft .NET technologies.

He is currently employed by Innoveo Solutions since 10/2007 as a Senior Solution Architect and certified Scrum Master.

Founder, owner and Managing Partner of Jobping, which provides a unique and efficient platform for connecting Microsoft skilled job seekers with employers using Microsoft technologies.

Laurent was awarded Most Valuable Professional (MVP) by Microsoft from April 2002 to April 2012.

JetBrains Academy Member
Certified ScrumMaster
My status

Twitter

Flickr

www.flickr.com
This is a Flickr badge showing public photos and videos from Laurent Kempé. Make your own badge here.

Month List

Page List