Your SlideShare is downloading. ×
Convention Over Configuration
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Convention Over Configuration

2,131

Published on

Published in: Technology, Business
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
2,131
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
35
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. Convention over Configuration Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc.
  • 2. So what is it? Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc. We use it all the time, in our everyday life, and in software development! Here goes the boring definition: “ Convention over Configuration is a software design paradigm which seeks to decrease the number of decisions that developers need to make, gaining simplicity, but not necessarily losing flexibility.”
  • 3. We use it all the time! Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc. Each of us have conventions e.g. where we keep DVDs, morning chores, habits (good or bad)! We have conventions for where we place our files in our hard disks! Conventions help us to be more productive in our daily lives!
  • 4. We also use it when developing software! Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc. Each of us have conventions when in comes to naming files, functions, classes Conventions for how we add comments Where we place models, controllers and views How and when we add events to DOM And many more ...
  • 5. If everyone already knows and uses it, then whats my point? Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc.
  • 6. We can use the idea of 'Conventions' to reduce the amount of configuration files: Convention over Configuration Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc.
  • 7. Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc. With configuration files, it takes time to get a project running, each time, everytime! Many software development platforms and frameworks have tones of configuration files!!! With the complexity of an application the size and number of those files grows as well.
  • 8. Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc. Instead <hibernate-mapping> <class name=&quot;User&quot; table=&quot;users&quot;> <id name=&quot;ID&quot; column=&quot;id&quot; type=&quot;string&quot;> <generator class=&quot;assigned&quot;></generator> </id> <property name=&quot;password&quot; column=&quot;password&quot; type=&quot;string&quot; /> </class> </hibernate-mapping> CREATE TABLE users ( id VARCHAR(20) NOT NULL, password VARCHAR(20), PRIMARY KEY(id)‏ ); Convention: all model classes will be singular, and will have plural table names Configuration Convention
  • 9. Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc. Faster development Good things!!!! Promotes uniformity Easier to maintain software No huge configuration files Structured Code Base
  • 10. Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc. Requires familiarity Bad Things!!!! Larger framework Hard to refactor existing frameworks to adopt a new convention
  • 11. Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc. A few frameworks that uses CoC Ruby on Rails CakePHP Grails JBoss Seam And many more
  • 12. So it is really that useful? Thats for you to find out and decide. Ahsanul Bari // Ahsan ( http://ahsanity.com )‏ Trippert Labs , Inc. I like it, so here I am , talking about it! :D

×