Sunday, November 2, 2008

Towards Distributed Applications…

2008 is the year when we saw the commercial emergence of the many-core / multi -core hardware architecture. As a result of this, field of distributed computing is really buzzing with a lot of activities and cool technologies. Two such projects that attracted my attention are project Volta and DryadLINQ in Microsoft domain and Lively Kernel in the Java world. Let’s focus on Dryad and Volta first.

One common thing about Volta and DryadLINQ is that they focus on making distributed computing easy for the common programmer like me. [DryadLINQ documentation refers to this class of programmers as ordinary programmer – LOL!] . The strategy here is to abstract away the underlying complexity in building the distributed systems and to minimize the disruptive impact of the new technology.


This goal is achieved by focusing on different levels of the .NET implementation stack. This way, as a developer, I can still write my same old C# / VB sequential, LOB code and the technology will transform it into a distributed application.

As with any new technology, there will be few bumps on the road. At the time of writing this post, I found following message on the Volta site –

“Project "Volta" Temporarily Unavailable”

Good news is that big vendors like Microsoft and Sun are taking the bull by the horns. There is no one right answer in solving this complex problem of converting existing sequential , single processor LOB applications into multi-core/ many-core enabled , inherently parallel, distributed applications. We will witness multitude of solutions on hardware and software level. We have seen this gold rush before in the good old days of RDBMS emergence. Let’s hope that same thing will happen with the distributed computing infrastructure.

For more details on Volta and Dryad, check out the following links and publication

1.http://channel9.msdn.com/posts/Charles/Erik-Meijer-Volta-Wrapping-the-Cloud-with-NET-Part-1

2.Volta: Developing Distributed Applications by Recompiling, IEEE Software Sept/Oct 2008 issue

3.http://research.microsoft.com/research/sv/dryad/

Monday, October 27, 2008

Caching in the Distributed Environment Slides

I did a presentation on "Caching in the Distributed Environment" at SoCal Code Camp 2008. Here is the link from where you can download this presentation

http://www.scribd.com/doc/7564192/Caching-in-the-Distributed-Environment

Let me know if you have any questions / suggestions

thanks.

abhi

Saturday, October 4, 2008

Caching in the Distributed Environment

Microsoft Architecture Journal has published an issue on Distributed Computing. A pdf copy of this issue can be downloaded from MAJ Issue 17



My paper on caching is included in this issue. I will be presenting this paper at SOCal Code camp 2008.. In this presentation, we will cover the fundamentals of caching, different caching patterns [for example, shared, primed, demand, transactional caching] and some real life caching examples. We will also discuss about the project Velocity - MS distributed caching platform.

See you @ the code camp

Saturday, September 13, 2008

Finally, I learned something

I had a chance to talk to one of my friend who is working on his dissertation. He is focusing on psychological aspects of success. After a long discussion with him about many topics, one thing really stood out by itself. Success is all about creating realistic targets and achieving them with pragmatic efforts. For example, if you can lift say 35 lbs/kgs then go for 35 or say 36-37, but beyond that you are in the stress zone. Now if you set the target of lifting say 40 lbs then give yourself some time – a realistic one would be a few weeks – anywhere between 2-3 weeks. If you try to achieve this overnight then you are in the stress zone. Be realistic is what I heard almost every time we talked about success.

I am definitely overweight. My weight should be in the 150 lbs range and it hovers around 162 lbs. So I belong to the club of 60% overweight Americans. If I set the target of 150 lbs in 3 weeks, I am in the stress zone, but if I do it in say 8 weeks – that’s more realistic.

Another stress factor was really a news to me. The Focus – almost every job requirement on DICE and Monster has it – we need someone who can multitask. Multitasking is not a synonym for focus – is it? According to psychologist, multitasking will reduce the quality of your work and will lead you to a stressful situation. So realizing the limits of what is doable and what is not is really important. Yes, we can chat with our friends while seating in a long design meeting, but I don’t think that’s possible if you are in the middle of a refactoring session.

Personally, I would like to avoid multitasking as much as possible. Now I know this is not something my boss or employer would like to know. But I would prefer quality over quantity anytime – anywhere. I have just started reading a WCF book –Learning WCF. My goal was to finish it over the weekend and to get the ball rolling come next Monday. Without realizing, I was pushing myself into the stress zone. Practically, this is an impossible target. So I am going to give myself a few more weeks and try to stick to my plan. I have one more book seating on my desk – Service Oriented Modeling. But for now, I am going to move this book back to my bookshelf. Wow! Finally, I learned something…

Sunday, September 7, 2008

A great fit ..

[And] I think you are a great fit for this…

What is Business? From Nature of the Firm by Coase [1] to the Porter's 5 forces analysis [2], this question is analyzed and explained in numerous studies and research. Still this important question is overlooked in many discussions related to this topic like a role of an architect. Figure 1 is another interpretation of the Marketplace and the Business



Figure 1: The Marketplace and the Business

There are enterprise architects, solution architects and infrastructure architects. Sometime the job description is a combination of all of the above or none of the above based on the situation and the project. A new way of looking at it is in terms of depth and width. An enterprise architect is responsible for managing the big picture and hence is a width base role. Solution architect focus on the project or a particular part of the project like performance or security and hence is a depth based role. Infrastructure architect is responsible for the infrastructure – viz SAN/WAN, servers, scalability, etc.

Architects are also responsible for coordinating operations between all other components of the business like HR, Marketing, Sales, etc. and the IT. Sometimes this means a political position and in other cases it’s a technical responsibility. Enterprise frameworks did an excellent job in capturing the technology component. The political/people part of the puzzle is mostly an on-job learning/training activity.

The role of an architect is to understand the business strategy/vision and implement it successfully in terms of improving existing process or by creating new processes. As explained in figure 1, it is important to understand the reason behind the project. For example, a project to support a new service or product will be totally different from the project focused on improving existing product/service. With a new product or service, an architect has got the freedom to start from scratch with a blank slate. Project focused on improving the existing product/service will mostly be a migration project like upgrading a legacy system, implementing some sort of application integration, etc.

An architect is like a conductor of an orchestra. Although, conductor does not play any instrument, he is responsible for producing the melody bounded by the music rules like the Symphony No. 40 [3].

Oh! What about an enterprise solution architect? The headhunter kept going on and on for almost five minutes. And then he said, you know, you should consider this seriously as their business is doing really good and they are growing really fast. A position with a local, stable, fast growing, privately owned company and yes, the salary is in six digits. I asked him, what is their business and he said does it matter? They are looking for an enterprise solution architect. [And] I think you are a great fit for this…

Resources:

1.http://en.wikipedia.org/wiki/Ronald_Coase
2.http://en.wikipedia.org/wiki/Porter_5_forces_analysis
3.http://en.wikipedia.org/wiki/Symphony_No._40_(Mozart)

Monday, September 1, 2008

David Linthicum on SOA

Vendor Driven Architecture [VDA] ,Manage by Magazine [MBM], Rabbit Consulting, think strategically and not around the quarter for making the bonuses. I heard all these terms in a SOA presentation by David Linthicum.


Here is the youtube URL - http://www.youtube.com/watch?v=0CbjUNzBV6I&feature=related

Here are some tidbits from this presentation

Architecture is something that you build not buy

Good Architects are expensive

Its up to you to decide what you want to build – SOA Zoo or SOA architecture

How NOT to build EA - signs to look for

Enterprise Architect is a position with no power and no authority

Architects write the documents that nobody read and talk about the things no body listens

Friday, August 22, 2008

ORM Manager

ORM manager will populate the data stored in the persistent storage like a database in the form of an object graph. ORM manager will use different object mapping strategies like table per hierarchy [TPH], table per type [TPT] or table per concrete class [TPC], etc. in populating the object graph. LINQ to SQL is based on TPH. Hibernate supports TPC, TPH and table per subclass mapping strategy [1]. Following is an example of the TPH.



Table Per Hierarchy ORM implementation


Reference:
1. http://www.hibernate.org/hib_docs/reference/en/html/inheritance.html accessed on 08/21/2008

Monday, July 21, 2008

Meaningful Identifiers

Anthony, _anthony and anthony were good friends. Anthony is a grown up guy,_anthony is a boy and anthony is a dog. One day, Anthony invited _anthony and anthony to his place for the party. _anthony was not feeling well but decided to tag along anthony. _anthony is too young to drive so they decided to walk to the Anthony’s place. Unfortunately, anthony could not walk so they called a cab. _anthony…

Who cannot walk? A dog or a boy…

Let’s re-factor this story a little bit. Let’s rename Anthony to MAnthony, _anthony to BAnthony and anthony to DAnthony. M for men, B for boy and D for dog.

With these new identifiers this story will be much better [to read and understand]. As in any story or a novel, meaningful identifiers are really important. Identifiers in any source code provide a meaningful token for the underlying memory. Identifiers tell a lot about the program. Just looking at the identifiers like account, debit and credit one can figure out that the system is a financial system.

This is a good read for anyone interested in more details on the way we program

Monday, July 14, 2008

VS 2008 Debugger going crazy?

Look at the code below and put the breakpoint on line
if (_s == null)

observe the behavior when we do something like
s2 = Singleton.getSingletonInstance();


using System;

namespace Pattern
{
class Program
{
static void Main(string[] args)
{
Singleton s1, s2;

s1 = Singleton.getSingletonInstance();

s1.instanceCount = 100;

s2 = Singleton.getSingletonInstance();
}
}


sealed class Singleton
{
private static Singleton _s = null;
public int instanceCount;

private Singleton()
{
}

public static Singleton getSingletonInstance()
{
if (_s == null)
{
_s = new Singleton();
}

return _s;
}

}
}


When the breakpoint will hit, try watching the value of _s. The watch window will pop endlessly all over the screen when you click on the following + sign next to the static members icon.
Screenshot:

Friday, June 20, 2008

SoCal Code Camp 2008




I will be presenting at Next Code Camp June 28th and 29th at University California San Diego Extension [www.socalcodecamp.com]

Topic: Using LinqDataSource with ASP.NET data controls

When: 3:00 PM - Sessions Room 110 on 06/29/2008 - driving directions can be found here

Check out LinqDataSource Sample


We will work on this sample in session.

Thanks

Friday, June 6, 2008

LINQ to SQL model

Saturday, April 19, 2008

Type of Exceptions

Wednesday, April 16, 2008

Nullable Object Pattern

Friday, April 4, 2008

Experience

Tuesday, February 19, 2008

Logic

Tuesday, January 8, 2008

Wrapper Application