Thursday, November 27, 2008

Enterprise Library - Configuration

As I'm looking into creating a generic configuration solution it crossed my mind I might utilize the Application Configuration Block from the Enterprise Library.

Microsoft's Patterns & Practices - Enterprise Library

Enterprise Library - homepage on MSDN. Additional code and documentation available on the project page at Codeplex.

The latest release is 4.1, dated October 2008. According to the documentation there is no Configuration Block anymore. I find that with version 2.0 the Configuration Application Block was replaced with IConfigurationSource. Apparently this block only made things worse and was thrown out. Well, I remember the first time and I was hoping things have improved by then but I was wrong. They, actually, did the right thing and eliminated the whole block out of Enterprise Library.
So, back to creating my own configuration solution. :)

Wednesday, November 26, 2008

Syncplicity - another online sync/backup service

Syncplicity - Secure Backup, Synchronization, and Sharing

There is another online backup/synchronization service available to users. Still haven't tried it, though.
From what I can see in the tour, it has an option to share a file with people who don't have an account with Syncplicity. This is a fancy thing that will soon be one of those "can't-live-without-them" issues.
The service also plays nice with other Web 2.0 applications - Google Docs, Facebook, Zoho, Scribd, Picnik.
It has a way to prioritize files to be synchronized, stores previous versions of files that have changed (revisions) and allows one-way traffic (a feature used for backup as opposed to synchronization).
The free service offers 2GB of data space on the servers. Some additional space can be earned through referrals.

Files/folders not synchronized by Live Mesh

Are there types of files or folders that I cannot share or synchronize? : Live Mesh : Live Mesh : Microsoft Forums

Here is a link to a post on Live Mesh forum listing the types of folders and files that are not synchronized by Mesh client.

You cannot synchronize or share the following with Live Mesh:

  • Files containing obscene or copyrighted material. Copying or
    sharing unauthorized materials, including materials that you did not
    create or you do not have the rights necessary for use, is a violation
    of the Windows Live terms of use. See the Microsoft Copyright Notice and FAQ.
  • Files whose names begin with a tilde (~)
  • desktop.ini
  • thumbs.db
  • Hidden files
  • Windows Systems folders
  • Your Desktop directory folder (for example,
    C:\users\[myusername]\Desktop on Windows Vista or C:\Documents and
    Settings\[myusername]\Desktop on Windows XP)
  • Files and folders stored on removable media (such as an external hard drive, flash drive, or USB drive)
  • Files and folders stored on mapped network drives

Live Mesh also blocks files that have the following file extensions:

  • .bak
  • .gfs
  • .lnk
  • .mbf
  • .mny
  • .mpc
  • .pst
  • .sav
  • .tmp
  • .wlx
  • .laccdb

Tuesday, November 25, 2008

Netbooks and Gaming

Netbooks Will Push Games to the Cloud - Seeking Alpha

Netbooks may become the most popular computer type in the near future. They would also be the least expensive one.
Offering good connectivity, they are perfectly poised to exploit the network. With rising popularity of network gaming (like Travian, for example) these could soon become the most widely distributed gaming platform.

Friday, November 21, 2008

Visual Studio 2008 Editions

Visual Studio 2008 Product Comparison

This page lists the differences between different Visual Studio 2008 editions.

Thursday, November 20, 2008

Visual Studio 2010 and .Net Framework 4.0 Preview

Visual Studio 2010 and .NET Framework 4.0 Overview

The first glimpse of the new Visual Studio and .Net Framework is available to the public. The focus seems to be on pushing the level of abstraction. Modeling and flexible architecture bring the most new features. Software development is maturing fast. Soon the new developers will not even know the difference between bit and byte. :)

VMWare Converter

VMware Converter for workstation to virtual pc and virtual machine migration - VMware

This free product converts Microsoft Virtual PC images to VMWare images.

What source machines does VMware Converter support for conversions?

Converter supports conversions from sources such as physical machines,
VMware and Microsoft virtual machine formats and certain 3rd party disk
image formats.

What virtual machine formats can VMware Converter import?

VMware Converter can import virtual machines created in:

Workstation 5.x and Workstation 4.x
VMware Player 1.x
VMware ESX 3.x
ESX Server 2.5.x (if the virtual machine is managed by VirtualCenter 2.x)
GSX Server 3.x
VMware Server 1.x
VirtualCenter 2.x
Microsoft Virtual PC version 7 and later
Any version of Microsoft Virtual Server

Sterod Procedures VS Parameterized Queries

TheServerSide Debates: Stored Procedures v Parameterized Queries

A very good debate on the eternal topic of 'Stored Procedures vs. Parameterized Queries'. Here we see different kind of scenarios, usage of sp_executeSQL, query string concatenation, parameterized queries, stored procedures, etc. The comments below the actual articles are more valuable than the article itself.

One of the conclusions that I am looking for at the moment is that for typical CRUD operations, parameterized queries are better and more effective.

Monday, November 17, 2008

Using Stored Procedures with Linq to SQL

Scoott Gu, in his endlessly useful series of articles on Linq to SQL, has an article on how to use Stored Procedures with Linq data model.

Apart from often quoted reasons like access speed and logic used in Stored Procedures, the positive side of using Linq with SPs is that the retrieved entities are strong typend and updatable through Linq. Having said that, it is also possible to use Stored Procedures on the insert/update/delete side.

Multiple results returned by SPs can be handled, as well. User Defined Functions are supported directly in Linq queries.

Saturday, November 15, 2008

Shared Access Computing

Microsoft has a product that helps with shared access computing. The product is called Windows SteadyState.

Computers at schools, libraries, internet cafes and other places where multiple users use the same workstations usually have the same problems. Configuration, downloaded files, access rights, maintenance, etc. This product makes it easier to maintain these workstations.

Friday, November 14, 2008

25GB Free with SkyDrive

Microsoft Live newsletter announced that they will soon offer 25GB of free web space on their SkyDrive service. From what I can see, space is in abundance at the moment. :)

The problem I have with SkyDrive is not the total amount of space available but the size of individual files allowed to be uploaded. I have an e-book I want to make available for download but the size is 140MB and there are only a very few reliable free services that allow that file to be uploaded. Hopefully the space upgrade will allow larger files to be hosted on SkyDrive, as well.

App Arch Guide 2.0 – Business Layer Guidelines

As a part of Microsoft Patterns & Practices a guide to designing a business layer is available at Codeplex.

According to this guide, the business layer consists of

  • Application Facade, which is optional, and combines multiple business operations into single operation.
  • Business components, representing the business logic, data and workflows.
  • Business entity components, used for passing data between components and representing real-world business entities.
  • Business workflow components.

Ajax & ASP.Net MVC

The one question left after reading about the MVC pattern for ASP.Net was whether and how it coexists with Ajax.

Nikhil Kothari has an article on this. Since the MVC is still not in Retail status, the Ajax is not supported out-of-the-box. With some fiddling around it soon will be. It is already possible to implement Ajax features into the MVC pattern and a prototype sample application is available with the article.

Similar to previous development, Ajax will be adjusted to MVC or vice versa and then this will be a great combination. Albeit a more complex but powerful one compared to current ASP.Net.

Using Linq with MVC

At ASP.Net site, there is a video that shows how to use Linq as a model inside a MVC framework. It is useful to see it also as a very basic and simple introduction to using Linq generally.

It shows different types of queries – query syntax and method syntax. Query syntax is similar to SQL query language while method syntax uses Lambda expressions.

The recommended way of implementing a model is to use Repository pattern.

Also, demonstrated is the way to use Constructor Dependency Injection pattern to allow for easier testability of the controller classes.

More on Microsoft MVC for ASP.Net

Here’s an article from the MSDN Magazine, March 2008 issue, about ASP.Net MVC.

Model View Controller (MVC) pattern, as implemented by Microsoft for ASP.Net, is a new web application framework that sits side-by-side with the Web Forms but has a different set of design goals. A few of the main points are that it is extensible and testable. The description from Patterns & Practices site is here.

It will definitely change the way we (developers) interact with the web users and how we create the new generation of applications. It is, finally, a step away from the scripting playground that started with ASP, PHP, and similar languages. Now, the URL as a way of interacting with an application server is more dynamic, configurable, and alive, in a way. Now we have classes (controllers) and different ways to interact with them through URLs (calls). The data (model) is displayed through a web page (view), as usual.

Views now can be Master Pages and regular pages, so page nesting is possible, allowing for a more modular and flexible design. The model can be strongly typed. That way it is accessible to a View through object properties, which implies type checking during compilation time. The view, actually, is a scripted version of the presentation layer and very much more like ASP than ASP.Net.

For the moment, as the technology is still not in its Release stage, Web Forms still have some advantages. But soon after the MVC framework catches up with the UI controls concept it might become more appropriate for a large-scale web development.

To see an introductory video on MVC, click here.

Scaling and Performance of ASP.Net Applications

Looking how to generally improve scaling and performance of ASP.Net applications shows how complex the problem is. Every problem will have a different solution as it needs to be broken down and analyzed to find bottlenecks and ways to solve them.

Some informational texts on the topic include:

Performance: Scaling Strategies for ASP.NET Applications

One of the solutions can be to use the newly emerging distributed data layer. Similar to Scale-Out, NCache, and others, Microsoft has started the Velocity project.

To see MySpace architecture and how it solved the scalability issue, read here. It confirms that the right approach in building high-capacity scalable sites lies in correctly implementing the caching or distributed-storage technology.

Linq for SQL vs Entity Framework

Performance Considerations for Entity Framework Applications

There are lots of good articles, comparisons and tests of raw Ado.Net SQLDataReader, Linq for SQL, and Entity Framework.
From the performance comparison results, it appears that the Entity Framework was intended as a middle-layer business object repository. The performance sucks if the queries are created and executed ad-hoc, whereas it gets much better during repeated queries. The business object should be instantiated and kept memory in a separate layer/service.
For better performance and scaling applications, Linq for SQL or just plain old datasets and stored procedures are still a faster option. But, that comes at a loss of a proper business layer.

Wednesday, November 12, 2008

GridView & LinqDataSource

LINQ to SQL (Part 9 - Using a Custom LINQ Expression with the control) - ScottGu's Blog
I'm playing with finding the easiest way to display and manipulate the content of a data table at an ASP.Net page.
The UI control is Grid View. The data is in SQL Server. I'm using Linq for SQL to generate the entities/tables. Entity Framework can only generate entities from tables which contain the primary key.
LinqDataSource is used to provide data and insert/update/delete features to the GridView.

Tuesday, November 11, 2008

3D Kitchen Planner

3D kitchen planning/modeling in Flash. For all of you kitchen lovers out there. Sooner or later everyone needs something like this.

Sunday, November 09, 2008

THM File

Today I copied some photos from my new Canon camera onto the PC and noticed that, besides the JPG photos, there was a .THM file, as well.
The .THM file can be renamed to .JPG and viewed. It turns out it was a preview of one of the first images I made and safe to delete.

Thursday, November 06, 2008

ASP.Net Distributed Caching

ScaleOut Software - Distributed Caching for Server Farms

To read about the current shortcomings of ASP.Net caching in a web farm environment, read the description - here.
Another product, besides NCache above, is ScaleOut. We are using it at work. It is one of the pioneers in the field and the performance is impressive.
To read a bit on Gigaspaces, its pros and cons, go here. It mentions a number of open source solutions, including Terracota.
In the newsgroups, people seem to praise NCache.

Designing Data Tier

Designing Data Tier Components and Passing Data Through Tiers

An article about how to design the Data Tier part. A thing I'm focused on at the moment.

Web Applications Patterns & Practices

patterns & practices Catalog by Application Type
Web Applications
Since I'm into doing some architecture work again, here is the link to Microsoft Patterns and Practices recommendations for application design. I'm focusing on Web Applications for the moment but that may be extended when other parts of the systems (libraries, services, etc.) come into play.
I am looking into current guidelines for the best practices application design.

Monday, November 03, 2008

Electric Vehicles and Batteries - I Want One!

Market for Electric Vehicle Batteries Is Heating Up - Seeking Alpha
The cars produced by Phoenix can go 130 to 250 miles on a charge, but can be recharged in as little as 10 minutes.
Excellent article on electrical batteries. With the development of the electric car market, the market for electrical batteries also develops. Good to hear there are already some great achievements, like the one quoted above. A battery that recharges in 10 minutes is definitely a breakthrough for normal use in electric vehicles.
I'd like to have some sort of electric car in the near future.