Sunday, December 18, 2011

How do Manager and Programmer run ?


Programmer
runs for x minutes/hours

Manager
Sets a goal(Calories or Distance)
Calculates how to achieve goal in shortest time.


Thursday, November 24, 2011

How does BMW produce Ultimate Driving Machine?

According to Csaba Csere, a former editor of Car and Driver magazine


BMW’s goal is to make the Ultimate Driving Machine. If you work at BMW in any capacity and you’ve got a decision to make, you can sit there and say “ We’re the ultimate driving machine. Which one of these decisions is going to advance that objective”

Referenece:
http://www.msnbc.msn.com/id/43730198/ns/business-cnbc_tv/t/bmw-drives-engineering-perfection/

Friday, November 18, 2011

Difference between Factory Pattern and Abstract Factory Pattern

Factory Pattern : Produces IProduct Implementation
Abstract Factory Pattern: A factory-factory produces IFactories, which in turn produces IProducts.

http://stackoverflow.com/questions/1001767/design-patterns-factory-vs-abstract-factory

Sunday, November 06, 2011

TOGAF: Archtiecture Principles





My Architecture Principles
1. Domain Layer should be independent and lightly coupled to UI and Data Layer
2. Application should be automated tests friendly.
3.  Requirement based change
4. Easy Maintenance
5. Configurable
6.  Control Diversity


http://pubs.opengroup.org/architecture/togaf8-doc/arch/chap29.html
Architecture principles are a subset of IT principles that relate to architecture work. They relflect a consensus across the enterprise, and embody the spirit and thinking of the enterprise architecture.
Architecture principles can be further divided into :
 1. Principles that govern the architecture processes, affecting the development, maintenance and use of enterprise architecture.
2. Principles that govern the implementation of the architecture , establishing the first tenets and related guidance for designing and developing information systems.

Architecture principles are used to capture the fundamental truths about how the enterprise will use and deploy  IT resources and assets.
Too many principles can reduce the flexibility of the architecture. Many organizations prefer define only high-level principles , and to limit the number to between 10 and 20.

Business Principles
  1.    Primacy of Principles
  2.    Maximize benefit to the Enterprise
  3.    Information Management is Everybody's Business
  4.     Business Continuity
  5.     Common Use Applications
  6.     Compliance with law
  7.     IT Responsibility
  8.     Protection of Intellectual Property
     

Data Principles 
  1. Data is an Asset
  2. Data is shared
  3. Data is Accessible
  4. Data Trustee
  5. Common Vocabulary and Data Definitions
  6.  Data Security


Application Principles
1. Technology Independence
2. Ease of Use
3. Requirement based change
4.  Responsive Change Management
5. Control Technical Diversity
6. Interoperability

TOGAF

TOGAF is an architecture framework.

TOGAF 9 can be used for developing a broad range of different enterprise architectures.

The key to TOGAF is the method the TOGAF Architecture Development Method(ADM) - for developing an enterprise archtiecture that addresses business needs.

Architecture in the context of TOGAF

"The fundamental organization of a sytem, embodied in its components, their relationships to each other and the environment, and the principles governing its design and evolution."

TOGAF embraces and extends this definition .In TOGAF , "architecture" has two meanings depending upon the context

1. A formal description of a system, or a detailed plan of the system at a component level to guide its implementation.

2. The structure of components , their inter-relationships , and the principles and guidelines governing their design and evolution over time.

Saturday, September 10, 2011

IOC and DI Containers Comparison

The following link gives very good comparison of different IOC and DI Containers overview

http://elegantcode.com/2009/01/07/ioc-libraries-compared/

Saturday, July 30, 2011

What a Software Professional should know?

I have been reading Robert C. Martin’s book “The Clean Coder”.
A must read book for every software professional.
In chapter 1, Bob mention the minimal list of things that every software professional should be conversant with:
1. Design patterns.
One should be able to describe all 24 patterns in the GOF book .
One should also have a working knowledge of the component principles.
2. Design
One should know the SOLID principles
3. Methods
One should understand XP, Scrum, Lean, Kanban, Waterfall ,Structured Analysis and Structured Design
4. Disciplines:
You should practice TDD, Object-Oriented design, Structured Programming, Continous Integration and Pair Programming
5. Artifacts:
You should know UML,DFDs ,Structured Charts, Pertri Nets, State Transition Diagrams and Tables, flow charts and decision tables.

Monday, July 04, 2011

ASP.Net MVC Best Practices

ASP.Net MVC Best Practices
1. Create Extension Methods of UrlHelper to generate your url from Route.
2. Create Extension Method of UrlHelper to map your Javascript,Stylesheet and Image Folder
3. Abstract DI Container
4.Keep your controller free from HttpContext and its tail
5.Use UpdateModel Carefully
6. Avoid ViewData,user ViewData.Model(Say No to "Magic strings"
7. User PRG Pattern for Data Modification
8. Action Filters
Use ActionFitlers for "shared " data. Use Action filters to retrieve data that is shared among different views. Use Partial view to display them.
9. Write your own HTML . If there ia n if , write an HtmlHelper.
10 . Do not put javascript in you code
11. User JQuery and JQuery UI
12. Create new ActionResult if you need one.
13.


References:
1. http://weblogs.asp.net/rashid/archive/2009/04/01/asp-net-mvc-best-practices-part-1.aspx
2. http://stackoverflow.com/questions/709429/asp-net-mvc-best-practices-tips-and-tricks

Sunday, June 26, 2011

How to become iphone developer in eight easy steps

http://www.guardian.co.uk/technology/gamesblog/2009/feb/10/gameculture-apple

Step 1: Buy Mac
Step 2: Download the SDK
Step3: Learn Objective C
Step 4: Start Writing Something
Step 5: Sign-up as official developer
Step 6: Prepare for last weeks of work
Step 7: Submit you app to Apple
Step 8: Adapt, market and survive

Tuesday, June 21, 2011

Evaluating Entity Framework 4.0

I have been evaluating Entity Framework for Enterprise projects for last couple of days.
We are using Entity Framework for some small projects.
When using Entity Framework v 1.0 , we found out querying Entity object using reflection is slower than querying a dataset.
I bought Programming Entity Framework book by Julia Lerman.
It is a very good book on this topic.
PROS:
-Entity Framework is O/R Mapper plus wraper over ado.net (gives you DataReader as well as DataSet
-POCO Supports
-supports stored procedure

CONS:
-POCO does not feel right.Ayenda of NHibernator Fame explains very nicely in this post.
http://ayende.com/blog/4038/why-defer-loading-in-entity-framework-isnt-going-to-work
In short, they are tightly coupled with Entity Framework Context.

Ayende gave other examples how nhibernator is superior as compared to Entity Framework
http://ayende.com/blog/4351/nhibernate-vs-entity-framework-4-0




View -> Controller ->Model ->Business Objects ->Data Layer ->Enity Famework ->Databases
-->Automapper

Monday, March 21, 2011

Is Silverlight dead?

I was googling the current buzz about Silverlight. I was thinking of useful search term and google provided me one . The useful term was
Is Silverlight Dead ?
.
Three years back when all architects and Microsoft Speakers are all gaga about Silverlight, I was full of doubts. I asked one Microsoft speaker why does he think that Silverlight will succeed when ActiveX controls, ActiveX documents and Java Applets failed, he dodged my question.
During one presentation, I asked Rockford Lhotka same question one year back. He was kind and prudent enough to answer that it depends on failure of HTML5.

Sunday, March 20, 2011

Programming Entity Framework - Julia Lerman

We have been using Entity framework on all new projects.
I have been in the camp if_you_are_building_enterprise_applications_you
_don't_use_ORM.
I think that Entity Framework has changed.
With Entity framework , I believe that you can build both Industrial and Non-Industrial strength Software Intensive Systems.

Don Box "If you are .NET developer Entity Framework is where we'are going. We're there . Get on board, it's time."

The Entity Framework is another enhancement to ADO.NET , giving the developers an added mechanism for accessing data and working with results in addition to DataReaders and DataSets.

Saturday, March 12, 2011

Beautiful Architecture -1 Conceptual Integrity

Beautiful Architecture
Architecture should have conceptual Integrity. Developer working on one component should be able to work on any other component of the system with ease. Conceptual Integrity comes from consistency in things such as decomposition criteria, application of design patterns and data formats. As we move from system to “system-of-systems.” The conceptual integrity must also be maintained in the architecture that integrates the systems.

Reference:
Beautiful Architecture

IIS 7.0 Architecture

IIS 7.0 ArchitectureInclude the following components
1. HTTP.Sys
2. World Wide Web Publishing Service
3. Windows Process Activation Services(WAS)

HTTP.SysIs part of networking subsystem of Windows operating systems, and is implemented as a kernel mode device driver called the HTTP protocol stack(HTTP.sys). HTTP.sys listens for HTTP requests from the network, passes the requests onto IIS for processing, and then returns processed responses to client browsers.

WWS :No longer manages worker process. Instead WWS is listener adapter for HTTP.sys.
Is primarily responsible for configuring HTTP.sys,updating HTTP.sys when configuration changes, and notifying WAS when a request enters the request queue.

WAS:
Manages application pool configuration and worker processed instead of WWS

Reference:

http://learn.iis.net/page.aspx/101/introduction-to-iis-7-architecture/

Tuesday, January 25, 2011

.NET 4.0 (Code Contracts) - 1

Code Contracts

Code Contracts provide a way to specify preconditions, postconditions and object invariants.

Benefits
Improved Testing
Automatic Testing Tools
Static Verification
Reference Documentation



Preconditions


Click the Project Properties Context Menu



If you don't see Code Contracts, download and install code contracts from the following link
http://msdn.microsoft.com/en-us/devlabs/dd491992.aspx

Run the solution




PostCondition Code Contract


Object Invariant