Windows 8 – Reset Your PC using Chocolatey

I don’t want to do too much copy and paste, go and read this blog post from Maarten Balliauw

this is how I can reinstall most of the software I use with a couple of command line commands

Go to http://www.myget.org,

  • setup your feed
  • add http://chocolatey.org/api/v2/ to the package sources
  • feeds
  • add all the packages you want to install.
  • packages

Install chocolatey on your machine:

@powershell -NoProfile -ExecutionPolicy unrestricted -Command “iex ((new-object net.webclient).DownloadString(‘https://chocolatey.org/install.ps1’))” && SET PATH=%PATH%;%systemdrive%\chocolatey\bin

and install all the packages from the feed you just created:
cinst All -source http://www.myget.org/F/smnbsswin8

Problem with @teamcity & #svn – can you help?

 

We installed a new svn server on a linux box a few weeks ago and we’re now migrating all our repos to that new shiny box.

We are using TeamCity Enterprise 6.0.1 (build 15816) as or CI platform, and while TC was perfectly able to talk to the old svn server running on a windows box, when we try to configure TC to read from the new one we got this error:

svn: SASL(-13): authentication failure: Password verification failed

If I try to connect to svn using Tortoise SVN, everything works just fine, but it looks like TC is unable to negotiate an authentication mechanism with svn, as you can see from TC logs:

[2011-11-28 16:16:00,953]  DEBUG -                 javasvn.output – NETWORK: READ

( success ( 2 2 ( ) ( edit-pipeline svndiff1 absent-entries commit-revprops depth log-revprops partial-replay ) ) )

[2011-11-28 16:16:00,953]  DEBUG -                 javasvn.output – NETWORK: SENT

( 2 ( edit-pipeline svndiff1 absent-entries depth mergeinfo log-revprops ) 38:svn://xxxbossvn02.tdpg.loc/EditorLite )

[2011-11-28 16:16:00,969]  DEBUG -                 javasvn.output – NETWORK: READ

( success ( ( PLAIN ) 36:3a6327f8-976c-bd49-aeeb-750278934a40 ) )

[2011-11-28 16:16:00,969]  DEBUG -                 javasvn.output – NETWORK: SENT

( PLAIN ( 4:AAA= ) )

[2011-11-28 16:16:00,969]  DEBUG -                 javasvn.output – NETWORK: READ

( failure ( 63:SASL(-13): authentication failure: Password verification failed ) )

[2011-11-28 16:16:00,969]  DEBUG -                 javasvn.output – NETWORK: svn: SASL(-13): authentication failure: Password verification failed

Enable click to play FLASH on Chrome

There’s an interesting hidden feature in Chrome, that allows you to disable by default all the plugins, but allows you to enable the one you want by clicking on it.

To enable the feature, open about:flags on chrome and enable the Click to play feature:

image

At that point when you open a page that use a plugin you’ll see something like this:

image

Clicking on the plugin you’ll automatically start the execution of that single plugin:

image

It surely is annoying to have the FLASH plugin disabled when browsing youtube, so you can setup exception from the Chrome setting page: chrome://settings/content

image

Click on Manage Exceptions and add the site where you want the plugin to play by default

image

 

You can now enjoy a life without flash ads Smile and with a lot less browser crash.

Continuous Learner #12

HTML5

”Modernizr adds classes to the <html> element which allow you to target specific browser functionality in your stylesheet. You don’t actually need to write any Javascript to use it”

http://www.modernizr.com/

”So here we’re collecting all the shims, fallbacks, and polyfills in order to implant html5 functionality in browsers that don’t natively support them.”
https://github.com/Modernizr/Modernizr/wiki/HTML5-Cross-browser-Polyfills

HTML5 Improvements with the ASP.NET MVC 3 Tools Update
http://weblogs.asp.net/scottgu/archive/2011/05/09/html5-improvements-with-the-asp-net-mvc-3-tools-update.aspx

Deep Dive into HTML5 and CSS3
http://www.infoq.com/presentations/Deep-Dive-into-HTML5-and-CSS3

High Scalability

Large-Scale Websites: Lessons from eBay
http://www.infoq.com/presentations/Best-Practices-eBay

Visual Studio

http://visualstudiogallery.msdn.microsoft.com/fa85b17d-3df2-49b1-bee6-71527ffef441

Other
Clean Up Your Mess – A Guide to Visual Design for Everyone
http://www.visualmess.com/

Webmachine and RESTful Web Frameworks with Justin Sheehy
http://www.infoq.com/interviews/webmachine-and-restful-web-frameworks

Memory Dump Analysis–W3WP IIS Process
http://romikoderbynew.wordpress.com/2011/05/07/memory-dump-analysisw3wp-iis-process/

Facebook’s new energy efficient data center
http://www.youtube.com/watch?v=JZUX3n2yAzY&feature=feedf

21 principles for innovating in the real world from IDEO’s Diego Rodriguez
http://thenextweb.com/dd/2011/05/08/21-principles-for-innovating-in-the-real-world-from-ideos-diego-rodriguez/

Sharding with SQL Azure – Introducing Federation in SQL Azure

Scalability often mean scaling out, and sharding the DB.
Until now, the sharding has always been managed at the application level, with a lot of manual work by developers with big scalability requirements.

Most of the NOSQL dbs like MongoDB, Raven etc, already support sharding, since it’s much easier to shard a non relational database than a relational database.

Finally MS is trying to add this concept of sharding built in into Sql, specifically into SQL Azure.
A single instance of SQL Azure can be up to 50GB, I believe this limit is due to the fact that each instance is replicated in 2 other locations, so it is be quite difficult to keep in sync a single massive instance bigger than that. For this reason Azure users where invited to shard their data across multiple SQL instances, adding a lot of work  to the developers implementing the solution.

MS released a whitepaper on sharding few days ago [1]. It’s a long and interesting document about the best practices of data sharding, and some details of the implementation of SQL Azure Federations and how we’ll be able in future to do it at the database level instead of doing it at the application level.

The following schematic outlines the concepts in SQL Azure with Federations:

6131.F1.bmp-550x0

 

Cihan Biyikoglu (Program Manager at Microsoft – SQL Azure) has the most interesting blog [2] about SQL Azure and has recently posted about this new Federation concept.

He has a very useful introduction to the new “keywords” (or key concepts if you want) [3] that will be useful to understand how everything works.

  • Federations represent all data being partitioned. It defined the distribution method as well as the domain of valid values for the federation key. In the picture below, you can see that the customer_federation is part of sales_db.
  • Federation Key is the key used for partitioning the data.
  • Atomic Unit (AU) represent a single instance value of the federation key. Atomic units cannot be separated thus all rows that contain the same instance value of the federation key always stay together.
  • Federation Member (aka Shard) is the physical container for a range of atomic units.
  • Federation Root is the database that houses federations and federation directory.
  • Federated Tables refer to tables in federation members that contain partitioned data, as opposed to
  • Reference Tables refer to table that contain data that is repeated in federation members for lookup purposes.

2627.image_thumb_4451A556

It’s all very exiting to see such a technology being implemented at the database level, keeping the ACID (http://en.wikipedia.org/wiki/ACID) properties inside a single Shard, and at the same time allowing the horizontal scalability needed in most modern systems.

1 – Sharding with SQL Azure
http://social.technet.microsoft.com/wiki/contents/articles/sharding-with-sql-azure.aspx

2 – SQL Azure – Your Data in the Cloud
http://blogs.msdn.com/b/cbiyikoglu/

3 – Building Scalable Database Solution with SQL Azure – Introducing Federation in SQL Azure
http://blogs.msdn.com/b/cbiyikoglu/archive/2010/10/30/building-scalable-database-solution-in-sql-azure-introducing-federation-in-sql-azure.aspx

My favourite Chrome plugin (Feedly) has a new wonderful version

I’ve been using Feedly for a long time. It’s a smart plugin that connects to Google Reader and presents your blogs in a magazine-like page.

It’s super cool because it presents you with nice images, that helps you screening what you want to read.

Another of my favourite plugins was Shareaholic, but I’ve been having some problems recently sharing stuff on Facebook because of the popup blocker in Chrome.

Now finally Feedly took over Shareholic and started to offer a sharing service via Feedly Mini.

You can read more on the official blog: http://blog.feedly.com/2010/11/08/feedly-mini-redesigned/

 

Thanks Feedly to make my life a little bit better Smile

Continuous Learner #7

jQuery

http://stackoverflow.com/questions/46214/good-ways-to-improve-jquery-selector-performance

http://www.artzstudio.com/2009/04/jquery-performance-rules/

Unit Test

http://site.typemock.com/test-lint/

Steve jobs was inspired by Italian cars
http://bit.ly/aT5LBP

MVVM & WP7

http://codingsolutions.blogspot.com/2010/03/windows-phone-7-tdd-kata-using-mvvm-and.html

Templify – making solution creation simple.
http://opensource.endjin.com/templify/download.htm