July 2009 - Posts

Jul 26 2009

For the first time in years, a Windows without a browser (not in all editions, and probably not in OEM versions, but still an improvement), and, as usual, half of the digital world is agitated in both extremes.

Some people are starting to create some kind of fear campaign, as if this was the start of judgement day or something. Some trying to scare people, some just providing Powershell scripts to download IE8, but in general doing everything except just say “download your favourite browser and store it before installing Win7 when it arrives”.

C'mon, who doesn't have today a usb drive or a DVD-ROM to download their favourite browser? And even in that strange case, who doesn't have internet at work, or can't buy a magazine with the latest xxx browser version, or ask a friend for the browser?

And anyway, why don’t using any browser to download and isntall IE8 if that’s what you desire? Remember that along too many years we’ve had to do the opposite, use IE to download other browsers, without the option of removing then IE from our machines?

Does anyone really think that all major browsers are going to skip this opportunity to flood every possible place with free CDs containing their browser? I would do it if I were Mozilla, Microsoft... even Apple (to try to get any Safari user under Windows xD) or Opera.

For me, this is a win for freedom. Even if as it will probably happen the browser will still be inside the OS, having the freedom to instal whatever browser I want and forgetting about tricky apps or situations in which IE tries to get control back is an improvement.

Nobody forbids you from installing IE8 if you want to use it. And probably we will now get computers with all two-three major browsers installed (IE8-Firefox-Chrome), because the world of the OEM OS is a dark and tricky one. Did you knew that Dell doesn’t provides on their website drivers for XP for all of the pcs they sell with Vista, but that if you call or write them they will send them via email to you? It happened to my sister few months ago.

Also, I’m pretty sure that Windows 7 will have a higher market penetration than Vista had (specially on laptops and netbooks, it’s biggest burden), but there is still a huge share of Windows users that still have and will keep their XPs *. Most users will keep using IE because “it’s what my PC came with” or because they can’t even download a newer version (schools and similar, at least in Spain).


Update: Seems that Microsoft finally accepted the initial proposal, and will ship W7 with IE8 but allowing to remove it at install time or choose another browser. Hopefully this will shut some fanatic mouths...


* Without entering on discussions of if it’s reasonable or not, and what part it is because of ignorance, of which I plan to do another post soon.

Jul 23 2009

Today I’m going to review PC Desktop Cleaner, a Windows tool to avoid having your desktop flooded of icons.

The interface of this software is quite simple and easy to use. Just a few tabs and buttons, and context menus for some actions.


Allows either cleaning (deleting) or archieving files (moving them to another folder).


The application allows to keep track of activity, from controlling the archive folder, to storing usage logs for a given period of months.


One nice feature is rules for automatic actions (like for example move al .txt files to My Documents\notes\). It has few but very useful rules.


Finally, we have some options available, like the archive folder, date format, if we want to include folders on the cleaning process or not, or the number of months to log before truncating it.



As a conclussion, although I prefer having a ultra-tidy desktop, if you are a bit disaster keeping yours in order, the rules and archieving (I’m afraid of “auto-delete” stuff) of PC Desktop Cleaner are nice features that can avoid you manual work.

Jul 12 2009

In my last release of this Community Server 2007 pack I added a lightweight list of all posts, but it wasn’t the only optimization I had in mind to do small speed increases on blog page loads. Two new controls I’ve just finished are a readonly tag list, and a “visual tag” list, which I’ll explain in detail.


This control is just a simplified, readonly version of the default one that CS2007 ships. I have stripped down all javascript the inline tag editor uses and all related functionality, creating a smaller and faster one that just renders the list of tags/categories of a post (or a post list, just like the normal tag list did).


  • Readonly: To edit the tags you must edit the post. In exchange, no CS/ASP.NET javascript is injected, so the weight of the page and the number of http requests is decreased considerably.
  • Prefix can be specified: By default it prepends the typical “Filed under: “, but you can specify whatever you want (HTML tags included).
  • If the post has no tags, nothing is rendered.

The syntax is almost the same as with the CS one:, with the addition of the new property:

<KartonesNet:WeblogPostTagList runat="server" TagListPrefixLiteral="Tags: " Tag="Div" CssClass="em" />

For example this blog now uses it.



This control uses the previous one as the base, but what it does is, instead of rendering text tags, renders images based on lowercasing and replacing spaces by underscores of the tag name (for example “XBox 360” would become “xbox_360.xxx”.


  • Readonly: No JS injected.
  • TagImagesURL: Property to specify the url containing the tag images.
  • ImagesExtension: Property to specify the extension of the image tags.
  • TagListPrefixLiteral: Property to specify the tag list prefix (just like the other control).
  • TagAliases: To properly display the alt/title attributes of the <img>, you can specify a list of aliases (even multiple ones for a tag). Example: 360,xbox360=XBox 360;wii=Nintendo Wii
  • If the post has no tags, nothing is rendered.

Example of how to use it:

<KartonesNet:WeblogPostVisualTagList runat="server" Tag="Div" CssClass="em"
="http://mydomain.com/images/tags/" ImagesExtension="png"
="<b>Tags</b>: " 
="360,xbox360=XBox 360;wii=Nintendo Wii" />

And a real example of how it looks:

visual tags example

This all happened because compressing ASP.NET and CS Javascripts is no easy task, and in order to do it you have to use ASP.NET AJAX (which I didn’t wanted to use either). But my battle of speeding up this blog as much as possible is still ongoing (I want to do one additional task :)

Jul 12 2009

This is going to be a small rant post not related to development, but I just couldn’t resist to talk about this semi-fraud.

Everybody who plays videogames (either on PC or on console) knows that in Europe prices are “a bit higher” and games usually come “a bit later”). Well, thanks to my friend Lobo666 (who told me about this Greasemonkey script) we can see “real-time proofs” of it.

Steam is Valve’s digital distribution system, widely used and very nice for a lot of things. When it has deals, some of them are pretty attractive, but other times… how can we be sure they are even worthy of being called deals?

Here’s an example:


So, compared with the US price, this weekend it is a real deal to buy GRID… but then why on the United Kingdom they have an even lower price? Maybe some special deal? Anyway, we can see that Steam’s currency maths are quite bad, because 1€ is not 1$. A miskate?

I don’t think so…


Now this is something we could even call fraud. Not only prices are higher on europe using the sadly so common “1$ = 1€”, but here we even get an increase of 10 additional euros!


Sadly this not only happens on Steam. The average price for Overlord on PC goes from 35€ to 45€ on Spain depending on the store/website. Only a few online sites really offer more or less correctly exchanged prices (around 28€ is the correct exchange for today).

And now, you can even buy online on a few sites (but they are growing) serial numbers for between 10-20€. Unused ones, perfectly valid. You have to download the game from anywhere else (probably a Torrent site), but you plug your serial number and voila. This is possible because in some places like Rusia or Asia prices are much lower (instead of higher as in Europe), and yes, it is perfectly legal (although companies are now starting to get worried about this problem situation, same as they are about second-hand games and rentals).


So, I’m not saying piracy is the answer to this cheating of prices, but I am definetly making a call to search for cheaper alternatives than just a local store or Steam if you have the feeling a game is a bit overpriced. There are plenty of options without entering the ilegal sector.

Jul 06 2009

Disclaimer: I’ve been only working for few months in high-scalability stuff so don’t expect super-secret techniques or expert advices. It is just a newbie 5-point basic list based on what I’ve learned and read about this subject up to now ;)

  1. Don’t touch the data layer. No matter what, try to avoid performing any SELECT query, any XML reading, except for the first time. ASP.NET page caching, XML caching or data caching (like for example PHP’s memcached or Microsoft’s Velocity). Avoid unnecesary querys: 15 queys on a page multiplied by millions equals insta-death against a DB-only data layer.
  2. Size matters. Every KB counts when daily pageviews go crazy. Compress Javascripts, CSS, output HTML, images, JSON data, DB table fields… everything you can. Remove all unnecessary data.
  3. Design for redundancy, balancing, partitioning, and implement failover architectures. Shit happens, no matter how good the system is. So better to be prepared to apply countermeasures or at least soft failures.
  4. Servers are no magical devices with unlimited resources. Skipping coding errors like memory leaks, big traffic sites need to be as optimum as possible with everything. If you use heavyweight objects here and there, think about refactoring them to smaller ones (or detach the most important and frecuently used data from the “extra” data, as when normalizing DB schemas).
  5. Design for scalability. Database partitioning, distributed web services, load balancers, archieving… We all hate twitter’s fail whale, but having millions of twitts per day requires a lot of stuff underneath (and that’s just an example, there are many more out there).

And as an extra, talking about web, prepare to enter the hell of browser incompatibilities, limitations and hacks. Desktop development is a piece of cake compared to any medium-complex web project.


Update: Here's an interesting round-up article about an example of .NET scaling.