Continuous Learner #9

 

No Callbacks Required: StratifiedJS Returns Sequential Programming to Javascript
http://www.infoq.com/articles/stratifiedjs

This StratifiedJS sound a lot like Async for .NET. It’s cool to see the client stack improving in parallel with the server side stack

VS2010 – JScript Editor Extensions
http://visualstudiogallery.msdn.microsoft.com/en-us/872d27ee-38c7-4a97-98dc-0d8a431cc2ed

VS2010 – resharper
http://www.hmemcpy.com/blog/2010/12/my-talk-at-the-alt-net-israel-tools-meetingresharpers-hidden-gems/

WINDOWS PHONE 7
New Windows Phone 7 Developer Guidance released for building line of business applications
http://geekswithblogs.net/iupdateable/archive/2010/12/21/new-windows-phone-7-developer-guidance-released-for-building-line.aspx

Continuous Learner #8

MVC

View Model versus Domain Entity Validation with MVC
[1]http://blogs.msdn.com/b/simonince/archive/2010/01/26/view-models-in-asp-net-mvc.aspx

View Models in ASP.NET MVC
[2]http://blogs.msdn.com/b/ukadc/archive/2010/12/16/view-model-versus-domain-entity-validation-with-mvc.aspx

ASP.NET MVC 3: Razor’s @: and <text> syntax
http://weblogs.asp.net/scottgu/archive/2010/12/15/asp-net-mvc-3-razor-s-and-lt-text-gt-syntax.aspx

Validation with the Data Annotation Validators
http://www.asp.net/mvc/tutorials/validation-with-the-data-annotation-validators-cs

EF Feature CTP5: Validation
http://blogs.msdn.com/b/adonet/archive/2010/12/15/ef-feature-ctp5-validation.aspx

Using ASP.NET MVC and jQuery to create confirmation prompts
http://blogs.msdn.com/b/stuartleeks/archive/2010/12/16/using-asp-net-mvc-and-jquery-to-create-confirmation-prompts.aspx

Question:
Given I have an MVC app that use EF4 with validation attributes on the model, and I have a Controller that return a ViewModel ([1]Variant 3).
How would you do validation on the client side?
One example is on [2], do you have an alternative where I don’t have to write so much code?

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

So… Bookarmy IS closing

Thursday I received a very sad email from Bookarmy: the website is being closed…

I’ve spent 2 intense years of my life building the site, and the community, with a fantastic Team of people.

Unfortunately I had to leave the team, because of some major disagreement with the new management that came in to turn the project around, that did not happened and I had a strong feeling that they had no idea about what they where trying to do, so I abandoned the ship a year ago.

Now I’m happily working as Technical Product Lead for TDPG, where we are building a set of business intelligence product for Estate Agents. It’s a complex and fascinating job, and a great team of people.

Going back to Bookarmy, I have received a plea from a BA user to keep the site open. I was so touched by the love some of our users have for us that I have decided to publish the plea, even if no one can really do anything to keep it open.

“Dear Simone,

I wish first of all, to thank you for your help with my bookarmy account problems.
Secondly, please read my plea below and pass it on to the rest of the bookarmy team.

”Dear EVERYBODY on the Bookarmy.com team,

I absolutely LOVE this site, it has held the only sense of community I have felt in a long 6 years in my current locale. I have found everyone here on Bookarmy friendly, helpful, quirky, and fun-loving.

I would HATE for Bookarmy to go down without a fight from its members.

If we made this at least temporarily a low-pay membership site, until the economic climate changes, and brought to bear new marketing techniques to drum up new advertising, we could have our Bookarmy and read it, too!

I think there are enough adult members who would not miss $2-$3 (or 1-2 pounds, as the case may be) per month to keep this grand experiment in truely genuine social networking going long enough to ride out the economic downturn!!

PLEASE consider keeping Bookarmy going under these terms, and spread the option to all members(if  enough adults pay to keep the site going ((even voluntarily)) the younger members could even stay on for free).

If you can set up a secure site, I will start the donations off with $5 (and I’m out of work).   If I can do a small membership fee thus, so can most of the other members!

Sincerely,”

It’s always sad to see something that took 2 years of your life to disappear like that, especially after I tried to convince the people in charge that they were going head down to destruction.

Anyway, life goes on, and I’m sure there’ll be other occasions for everybody in the team to shine even if in different projects and walks of life.

I want to thank Hannah, Eilidh, Evaldas for spending a painful last year with me (2009) and Tom and Frank for starting the project.