Where can I find happiness?

Answer by Prayag Sonar:

Whenever I feel depressed in my life,I used to open my E-Mail inbox to find happiness and I find:

  • 10 banks are giving me easy loans up to 25 Lakhs.
  • I have won GBP 10000000 and USD 500000 for unknown reasons.
  • 15 companies having the best jobs for me.
  • 5 matrimonial sites have the most suited matches for me.
  • Dr. Batra has claimed that he will cure my hair fall.
  • 3 universities are giving me degrees in random subjects.
  • Online retailers are giving me discounts up to 70% on all products.
  • Debit & credit card companies assuring me best offers on shopping,movie,travel & food.
  • Fairness cream has promised to turn me glow in 7 weeks.
  • And approximate 40-50 mails from Priya, Payal and Neha who are feeling lonely and want to meet me.What else do I want in my life?

Where can I find happiness?

Advertisements

Conversation !!

Girl: How’s the exam preparation going?

Guy: It is like a sine wave. Studying for sometime, quorifying for sometime and thinking of you, most of the time. The cycle goes on like that. Time period 24 hours.How about you ?

Girl: My preparation is like an exponential curve.While I study, my productivity increases exponentially like, e power x graph. But, the moment I think of you, my concentration decreases like e power -x graph.

Qurly – Discover Wellness

Qurly, an online Salon and Spa guide, has become a rage amongst beautician and salon and spa businesses all over the India. In a very short span of time, it has become an established online brand by answering every query one might have before choosing a new place for rejuvenation,fitness and makeover – i.e. Rate card, photos, maps, reviews, contact information and salon & spa outlet features.

From Delhi-NCR, it has expanded to Mumbai, Bangalore, Pune, Chennai, Hyderabad & Kolkata. Before the end of 2015, the brand aims to expand to 12 states.

Such big aspirations are powered by a rather simple business model and a powerful online platform. In this post, we are listing Qurly features that helped it become a reputed online Salon ,spa & Fitness Outlet discovery and review brand.

General Features of Frontend Interface

  • Unlimited number of site Users and Salon ,spa & Fitness Businesses
  • Facilitates multiple Cities listing
  • Provides a user-friendly interface for Visitors
  • Helps users in selecting the best salon & spa outlet according to their Locations, Budgets, Choice of services, Ratings among other options.
  • Outlets can also collect Feedback from users in the form of Reviews and Comments
  • Option to Search outlet by Keywords, Outlet feature & Types/Categories and Services
  • Option to browse/search Restaurants in the city by Sitemap
  • Featured Service/Ambience Images/Pictures Slide show for outlet city wise
  • Option to sort outlet listing by various filters/options in the city
  • Top Trending outlet in this week in the selected city on the basis of user actions
  • Option to view Outlet rate card images slide show
  • Outlets Photos Galley & Images Slide show
  • View Users Reviews listing for Outlets
  • Option to get directions to Outlets
  • Option to find Nearby Outlets
  • Option to Register/Login and create users profile
  • Login/Connect with Facebook
  • Login/Connect with Google
  • Option to use Forgot Password feature
  • Keep track of your makeup journey with handy lists, reviews, and beautiful filtered photos
  • Offers Advertising options for outlet looking to generate more visibility among a highly targeted audience
  • Facilitates users to view outlet Banners and Special Offers
  • ‘Follow Us’ links for Facebook, Twitter & Google+
  • Facebook fan box
  • Option to view all Popular Localities
  • Contact Us & Feedback Forms submission
  • Ability to view & browse all CMS and customized pages
  • SEO Friendly URLs

Qurly Welcome Screen

Qurly.in/delhi

Search/Browse outlets

Search is one of the core strengths of Qurly platform. Even a first time user can easily find outlets in his city or location of his choice, read reviews, go through ratecard and decide whether it is worth a shot or not. Below are features that make Qurly amazing from search point of view:

  • Option to search/find salon,spa & fitness listings city wise
  • Provide Auto suggest Keyword based search
  • Search for outlet, salon, spa and gym by Name, Locality, Category and etc.
  • Facilitates search for services being used across various outlets across all cities
  • Browse outlet through updated rate card, pictures, and user reviews to decide where you want to pamper yourself.
  • Option to use the Google Map feature to guide/find the outlet location
  • Facilitates to browse city outlet by Sitemap options like Popular Localities, Popular service, By Budget low,medium & high and Popular Searches etc.
  • Option to search & view Full Directory of outlet and pages site wide
  • Option to search & view List of outlet in all available Cities listing

Search/Browse Restaurants Screens

1. Refine Search

Untitled

 2. Outlet Listing Page

outlet


sitemap

Outlet  Features

Qurly team spent quite some time in evolving unique and helpful features to help people select a place for rejuvenation. Following are some good features that are part of the basic product/system:

  • Option to show Top 10 outlet list in your city
  • Outlet that  have maximum page views, top reviews and maximum time spend by users on a weekly basis have a chance to get selected in the trending list
  • View Ratecard, Pictures, Directions, Contact and all the other information you need to choose a outlet for rejuvenation and pampering.
  • Outlet with updated ratelist for almost all places
  • Provide outlet Address Info/details, Reviews & Map details along with Average Rating based on users votes
  • Option to view Total Reviews, Totals Favorites & Total Wishlists for outlet

Outlet Screens

Alaya Spa   Salon Outlets, PVR Anupam Complex, Saket   Qurly

…..TBC

content delivery networks (CDNs) – Working

Content delivery networks (CDNs) are an important part of Internet infrastructure that are frequently used without a full understanding of what’s happening behind the scenes. You’ll hear people saying, “oh, we put that on the CDN” or “make sure static assets go on the CDN,” when they have only a rudimentary idea of what CDNs are and how they work. As with most pieces of technology, CDNs are not magic and actually work in a pretty simple and straightforward manner.

When a web browser makes a request for a resource, the first step is to make a DNS request. Making a DNS request is a lot like looking up a phone number in a phone book: the browser gives the domain name and expects to receive an IP address back. With the IP address, the browser can then contact the web server directly for subsequent requests (there are actually multiple layers of DNS caching, but that’s beyond the scope of this post). For your simple blog or small commercial web site, a domain name may have a single IP address; for large web applications, a single domain name may have multiple IP addresses.

Physics determines how fast one computer can contact another over physical connections, and so attempting to access a server in China from a computer in the United States will take longer than trying to access a U.S. server from within the U.S. To improve user experience and lower transmission costs, large companies set up servers with copies of data in strategic geographic locations around the world. This is called a CDN, and these servers are called edge servers, as they are closest on the company’s network to the end-user.

DNS resolution

When the browser makes a DNS request for a domain name that is handled by a CDN, there is a slightly different process than with small, one-IP sites. The server handling DNS requests for the domain name looks at the incoming request to determine the best set of servers to handle it. At it’s simplest, the DNS server does a geographic lookup based on the DNS resolver’s IP address and then returns an IP address for an edge server that is physically closest to that area. So if I’m making a request and the DNS resolver I’m routed to is Virginia, I’ll be given an IP address for a server on the East coast; if I make the same request through a DNS resolver in California, I’ll be given an IP address for a server on the West coast. You may not end up with a DNS resolver in the same geographic location from where you’re making the request.

United States CDNs often have edge servers located on the Pacific and Atlantic coasts

That’s the first step of the process: getting the request to the closest server possible. Keep in mind that companies may optimize their CDNs in other ways as well, for instance, redirecting to a server that is cheaper to run or one that is sitting idle while another is almost at capacity. In any case, the CDN smartly returns the best possible IP address to handle the request.

Accessing content

Edge servers are proxy caches that work in a manner similar to the browser caches. When a request comes into an edge server, it first checks the cache to see if the content is present. The cache key is the entire URL including query string (just like in a browser). If the content is in cache and the cache entry hasn’t expired, then the content is served directly from the edge server.

If, on the other hand, the content is not in the cache or the cache entry has expired, then the edge server makes a request to the origin server to retrieve the information. The origin server is the source of truth for content and is capable of serving all of the content that is available on the CDN. When the edge server receives the response from the origin server, it stores the content in cache based on the HTTP headers of the response.

When a request comes into an edge server it either contacts the origin server for the content or serves it from cache

Yahoo! created and open sourced the Apache Traffic Server, which is what Yahoo! uses in its CDN for managing this traffic. Reading through the Traffic Server documentation is highly recommended if you’d like to learn more about how cache proxies work.

Example

For example, Yahoo! serves the YUI library files off of its CDN using a tool called the combo handler. The combo handler takes a request whose query string contains filenames and concatenates the files into a single response. Here’s a sample URL:

http://yui.yahooapis.com/combo?3.4.1/build/yui-base/yui-base-min.js&3.4.1/build/array-extras/array-extras-min.js

The domain yui.yahooapis.com is part of the Yahoo! CDN and will redirect you to the closest edge server based on your location. This particular request combines two files, yui-base-min.js and array-extras-min.js, into a single response. The logic to perform this concatenation doesn’t exist on the edge servers, it only exists on the origin server. So if an edge server receives this request and has no content, a request is made to the origin server to retrieve the content. The origin server is running the proprietary combo handler (specified by/combo? in the URL) and so it combines the files and returns the result to the edge server. The edge server can then serve up the appropriate content.

What does static mean?

I frequently get confused looks when I describe systems similar to the combo handler. There is a misconception that CDNs act like FTP repositories, where you simply upload static files so that others can retrieve them. I hope that it’s clear from the previous section that this is not the case. An edge server is a proxy, the origin server is the one that tells the edge server exactly what content should be returned for a particular request. The origin server may be running Java, Ruby, Node.js, or any other type of web server and, therefore, can do anything it wants. The edge server does nothing but make requests and serve content. So the YUI combo handler exists only on the origin server and not on the edge servers.

If that’s the case, why not serve everything from the CDN? The CDN is a cache, meaning that is has value when it can serve data directly and not need to contact the origin server. If an edge server needs to make a request to the origin server for every request, then it has no value (and in fact, costs more than just making the request to the origin server itself).

The reason JavaScript, CSS, images, Flash, audio, and video are frequently served from CDNs is precisely because they don’t change that frequently. That means not only will the same user receive content from cache, but all users will receive the same data from cache. Once the cache is primed with content, all users benefit. A site’s homepage is a poor candidate for edge caching because it’s frequently customized per user and needs to be updated several times throughout the day.

Cache expiration

Yahoo! performance guidelines specify that static assets should have far-future Expiresheaders. This is for two reasons: first, so the browser will cache the resources for a long time, and second, so the CDN will cache the resources for a long time. Doing so also means you can’t use the same filename twice, because it may be cached in at least two places and users will receive the cached version instead of the new one for quite a while.

There are several ways to work around this. The YUI library uses directories containing the version number of the library to differentiate file versions. It’s also common to append identifiers to the end of a filename, such as an MD5 hash or source control revision. Any of these techniques ensures that users are receiving the most up-to-date version of the file while maintaining far-future Expires headers on all requests.

Conclusion

CDNs are an important part of today’s Internet, and they’re only going to become more important as time goes on. Even now, companies are hard at work trying to figure out ways to move more functionality to edge servers in order to provide users with the fastest possible experience. This includes a technique called Edge Side Includes (ESI) which is designed to serve partial pages from cache. A good understanding of CDNs and how they work is key to unlocking greater performance benefits for users.

visualization of server traffic is like the coolest game of Pong

This visualization of server traffic is like the coolest game of Pong

Taiga is “a free project management platform for startups, developers, and designers.” After being mentioned by Hacker News their servers got blasted with traffic, which they turned into this cool visualization that it like a game of Pong played by a zillion players against one computer.

Each little “ball” is a request to the server

On the left: the IP numbers from the users connecting around the world

To the right: The url’s being served up

In the center: The “static calls being serviced by our front end

The brightness represents the speed with which the code written by our awesome developers delivers data (aided of course the great hardware)

Had any of the balls gone past to the right, that would have been a serve we couldn’t return. Try that, Federer!

Code and Implimentation : Taigaio Front EndTaigaio Back End

Instagram Search Tags API

Getting started, I visit Instagram’s API documentation to learn how I can search for photos by tag. Registration is required, so I follow the instructions under GETTING STARTED.

I find the relevant API end point here. It takes the form:

1
GET /tags/{tag-name}/media/recent

It responds with a list of recently tagged photos in JSON. The API supports JSONP – things are looking good.

Docs provide an example request:

1
https://api.instagram.com/v1/tags/snow/media/recent?client_id=CLIENT-ID

Replacing CLIENT-ID with my own, I paste the URL into a browser to see what the JSON object looks like. I could copy and paste the response into a file to use as sample data for developing against, but I can’t be bothered right now. Perhaps later.

I’m ready to start getting stuff down, so I create the necessary directories and files for my project:

1
2
3
omar:~ admin$ mkdir -p instagram/{images,javascripts,stylesheets}
omar:~ admin$ cd instagram
omar:~ admin$ touch index.html javascripts/application.js stylesheets/application.css

I add some basic markup to index.html. I’ll be using jQuery, so I load it in the document’s head:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
<!DOCTYPE html>
<html>
<head>

  <script src='https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js' type='text/javascript' charset='utf-8'></script>
  <script src='javascripts/application.js' type='text/javascript' charset='utf-8'></script>
  <link rel='stylesheet' href='stylesheets/application.css' type='text/css' media='screen'>

</head>
<body>

  <div id='photos-wrap'>
  </div>

</body>
</html>

I open up appliation.js and start writing code. So as not to pollute the global namespace, I’ll wrap my code in an anonymous function, exposing only a single method, search, to the global namespace (I love minimalist APIs). The method will take a string (a photo tag) as its only parameter.

1
2
3
4
5
6
7
8
var Instagram = {};

(function(){

 Instagram.search = search;
})();

Instagram.search('cats');

I load up index.html on Google Chrome so I can start debugging. With ‘Developer Tools’ enabled and the ‘console’ panel selected, I see:

1
Uncaught ReferenceError: search is not defined

So, I define it:

1
2
3
4
5
6
7
8
9
10
(function(){

  function search(tag){
    console.log(tag);
  }

  Instagram.search = search;
})();

Instagram.search('cats');

Reloading the page, I see the error has gone… I’m making progress.

Going to flesh out my function, search. I’ll use jQuery’s getJSON function for loading JSON-encoded data from Instagram using a GET HTTP request. See documentation here.

At a minimum, the method takes a request URL. I also pass it a success handler, so I can manage the JSON encoded data which is sent back after a successful request.

1
2
3
function search(tag){
  $.getJSON(url, toScreen);
}

Both url and toScreen need to be defined:

1
2
3
4
5
6
7
8
function toScreen(data){
  console.log(data);
}

function search(tag){
  var url = "https://api.instagram.com/v1/tags/" + tag + "/media/recent?callback=?&amp;client_id=XXXXXXXXX"
  $.getJSON(url, toScreen);
}

Refreshing Chrome I see the returned JSON object printed to the JavaScript console. Using the console I drill down into the returned object. I see the photos are contained within an array called data:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
- Object
  - data: Array[20]
    - 0: Object
      + caption: Object
      + comments: Object
        created_time: "1334402906"
        filter: "Nashville"
        id: "169306311223447303_5913362"
      - images: Object
        + low_resolution: Object
        - standard_resolution: Object
          height: 612
          url: "http://distilleryimage7.instagram.com/f3f8d7b2862411e19dc71231380fe523_7.jpg"
          width: 612
        + thumbnail: Object
        + likes: Object
          link: "http://instagr.am/p/JZfzFqtI8H/"
          location: Object
          tags: Array[1]
          type: "image"
          user: Object

(-) collapsed object. (+) expanded object.

I update toScreen to iterate through the data object, appending each photo to the browser:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
function toScreen(photos){

  // Using jQuery's generic iterator function:
  // jQuery.each http://api.jquery.com/jQuery.each/

  $.each(photos.data, function(index, photo){

    // I'll construct the image tag on the fly.
    // The images property contains objects representing images of
    // varying quality. I'll give low_resulution a try.

    photo = "<img src='"+ photo.images.low_resolution.url + "' />";

    $('div#photos-wrap').append(photo);
  });
}

Refreshing the browser, I see 20 cat photos loading… so much cuteness on one page is hard to manage.

Now’s a good time to introduce a little more markup so I can start applying some styling.

I jot down how I’d like each photo to be represented as HTML. Attribute values which will be different for each photo I wrap with curly braces:

1
2
3
4
5
<div class='photo'>
  <a href='{photo_url}' target='_blank'><img class='main' src='{photo}' width='250' height='250' /></a>
  <img class='avatar' width='40' height='40' src='{avatar_url}' />
  <span class='heart'><strong>{like_count}</strong></span>
</div>

I now insert this markup into the $.each iterator, replacing the curly braced attribute markers with the relevant datum:

1
2
3
4
5
6
7
8
9
10
11
$.each(photos.data, function(index, photo){
  photo = "<div class='photo'>" +
    "<a href='"+ photo.link +"' target='_blank'>"+
      "<img class='main' src='" + photo.images.low_resolution.url + "' width='250' height='250' />" +
    "</a>" +
    "<img class='avatar' width='40' height='40' src='"+photo.user.profile_picture+"' />" +
    "<span class='heart'><strong>"+photo.likes.count+"</strong></span>" +
  "</div>";

  $('div#photos-wrap').append(photo);
});

Refreshing the browser I see this works… but my toScreen function now looks forsaken. All that string concatenation inside the jQuery.each callback makes me angry/thirsty/feverish.

The HTML markup deserves to have it’s own object, where it can safely exist, far from the dangerous machinery operating inside toScreen.

So…

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
// Instantiate empty objects.
var Instagram = {};
Instagram.Template = {};

// HTML markup goes here, please!
Instagram.Template.Views = {

  "photo": "<div class='photo'>" +
            "<a href='{url}' target='_blank'><img class='main' src='{photo_url}' width='250' height='250' /></a>" +
            "<img class='avatar_url' width='40' height='40' src='{avatar}' />" +
            "<span class='heart'><strong>{like_count}</strong></span>" +
          "</div>"
};

(function(){

  function toScreen(photos){
    $.each(photos.data, function(index, photo){

      // Undefined function toTemplate, takes
      // the photo object and returns markup
      // ready for display.

      photo = toTemplate(photo);
      $('div#photos-wrap').append(photo);
    });
  }

  function search(tag){
    var url = "https://api.instagram.com/v1/tags/" + tag + "/media/recent?callback=?&client_id=a307c0d0dada4b77b974766d71b72e0e";
    $.getJSON(url, toScreen);
  }


  Instagram.search = search;
})();

Instagram.search('cats');

Refreshing the browser I get Uncaught ReferenceError: toTemplate is not defined. I’ll fix that…

1
2
3
4
5
6
7
8
9
10
function toTemplate(photo){
  photo = {
    like_count: photo.likes.count,
    avatar_url: photo.user.profile_picture,
    photo_url: photo.images.low_resolution.url,
    url: photo.link
  };

  return Instagram.Template.generate('photo', Instgram.Teamplate.Views['photo']);
}

Instagram.Template.generate is undefined. I plan to create a function which finds strings matching property names in a passed object, replacing them with the corresponding values.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// A simple (it does the job) function for template parsing.
Instagram.Template.generate = function(template, photo){

  // Define variable for regular expression.
  var re;

  // Fetch template.
  template = Instagram.Template.Views[template];

  // Loop through the passed photo object.
  for(var attribute in photo){

    // Generate a regular expression.
    re = new RegExp("{" + attribute + "}","g");

    // Apply the regular expression instance with 'replace'.
    template = template.replace(re, photo[attribute]);
  }

  return template;
};

I refresh the browser; things are coming together. Time to introduce the search form:

1
2
3
4
5
6
7
8
9
10
11
12
<body>
  <div id='photos-wrap'>
    <form id='search'>
      <button type='submit' id='search-button' tabindex='2'>
        <span class='button-content'>Search</span>
      </button>
      <div class='search-wrap'>
        <input class='search-tag' type='text' tabindex='1' />
      </div>
    </form>
  </div>
</body>

I’ll bind an event handler to the form button, so I can invoke my search method whenever the form is submitted:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
$(function(){

  // Bind an event handler to the `click` event on the form's button
  $('form#search button').click(function(){
    // Extract the value of the search input text field.
    var tag = $('input.search-tag').val();

    // Invoke `search`, passing `tag`.
    Instagram.search(tag);
  });

  // Start with a search on cats. Humanity loves cat pictures, right?
  Instagram.search('cats');
});

The end of my first iteration is drawing near. I still need to slap on some makeup, which I’ll do shortly. First, I want to revisit some code I’m not too happy with:

1
2
3
4
5
6
7
8
9
function toScreen(photos){
  ....
  // Appending new photos to the bottom of 'body' - new stuff isn't visible
  // unless you scroll down the page. I want to 'prepend'!

  - $('div#photos-wrap').append(photo);
  + $('div#photos-wrap').prepend(photo);
  ....
}

Introducing an object for holding configuration data, and a new function for concatenating the request URL:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
+ Instagram.Config = {
+  clientID: "XXXXXXXXXXXXX";,
+  apiHost: "https://api.instagram.com";
+ };

  (function(){
  ...

+   function generateUrl(tag){
+     var config = Instagram.config;
+     return config.apiHost + "/v1/tags/" + tag + "/media/recent?callback=?&amp;client_id=" + config.clientID;
+   }


    function search(tag){
-     var url = "https://api.instagram.com/v1/tags/" + tag + "/media/recent?callback=?&amp;client_id=a307c0d0dada4b77b974766d71b72e0e";
-     $.getJSON(url, toScreen);
+     $.getJSON(generateUrl(tag), toScreen);
    }

  ...
  })();

Calling $.prepend for every photo is wasteful. Why not concatenate each photo string, prependingthe final result.

1
2
3
4
5
6
7
8
9
  function toScreen(photos){
+   var html = "";
    $.each(photos.data, function(index, photo){
-     photo = toTemplate(photo);
-     $("div#photos-wrap").prepend(photo);
+     html += toTemplate(photo);
    });
+   $("div#photos-wrap").prepend(html);
  }

Ok. I’ve slapped on some makeup – see stylesheets/application.css, and I think we’re good for a first go.

In another iteration it might be worth implementing the following features:

  • Error handling (gracefully deal with invalid tags, API server down…).
  • Bookmarking searches, for future reference.
  • Marking favourite photos for quick retrieval at a later date.
  • Add pagination.
  • Displaying more photo data (username, comments).

Why does Quora use MySQL as the data store instead of NoSQLs such as Cassandra, MongoDB, or CouchDB?

  1. If you partition your data at the application level, MySQL scalability isn’t an issue. Facebook reported [1] running 1800 MySQL servers with just two DBAs in 2008. You can’t do joins across partitions, but the NoSQL databases don’t allow this anyway. Facebook hasn’t confirmed using Cassandra as the primary source for any data, and it seems like inbox search might be their only use of it. [2]
  2. These distributed databases like Cassandra, MongoDB, and CouchDB[3] aren’t actually very scalable or stable. Twitter apparently has been trying to move from MySQL to Cassandra for over a year. When someone reports using one of these systems as their primary data store for over 1000 machines for over a year, I’ll reconsider my opinion on this.

    << Update as of August 2011: after I wrote this, foursquare reported an 11-hour downtime because of MongoDB. [4] Separately, a friend’s startup that was going through explosive growth tried to switch to MongoDB and gave up after a month due to instability. Twitter gave up on the Cassandra migration. [5] Facebook is moving away from Cassandra. [6] HBase is getting better but is still risky if you don’t have people around with a deep understanding of it. [7] >>

  3. The primary online data store for an application is the worst place to take a risk with new technology. If you lose your database or there’s corruption, it’s a disaster that could be impossible to recover from. If you’re not the developer of one of these new databases, and you’re one of a very small number of companies using them at scale in production, you’re at the mercy of the developer to fix bugs and handle scalability issues as they come up.
  4. You can actually get pretty far on a single MySQL database and not even have to worry about partitioning at the application level. You can “scale up” to a machine with lots of cores and tons of ram, plus a replica. If you have a layer of memcached servers in front of the databases (which are easy to scale out) then the database basically only has to worry about writes. You can also use S3 or some other distributed hash table to take the largest objects out of rows in the database. There’s no need to burden yourself with making a system scale more than 10x further than it needs to, as long as you’re confident that you’ll be able to scale it as you grow.
  5. Many of the problems created by manually partitioning the data over a large number of MySQL machines can be mitigated by creating a layer below the application and above MySQL that automatically distributes data. FriendFeed described a good example implementation of this [8].
  6. Personally, I believe the relational data model is the “right” way to structure most of the data for an application like Quora (and for most user-generated content sites). Schemas allow the data to persist in a typed manner across lots of new versions of the application as it’s developed, they serve as documentation, and prevent a lot of bugs. And SQL lets you move the computation to the data as necessary rather than having to fetch a ton of data and post-process it in the application everywhere. I think the “NoSQL” fad will end when someone finally implements a distributed relational database with relaxed semantics.

 Quora CEO – Adam-DAngelo

Indian Railways Catering and Tourism Corporation (IRCTC):

Most of the people aren’t aware that Indian Railway(not the IRCTC website maintained by CRIS but the core application the reservation centers use) already has an algorithm to ensure that a female passenger isn’t left stranded in the middle of a lot of males!
Since the IRCTC website use the same APIs provided by the reservation application(which looks much like DOS-based), we’re already a beneficiary to this feature.

As soon as you enter the details to reserve a seat for a female passenger, the entire database of that train is searched to find out empty seats close to any other female passenger travelling in the same class.
If such a female is found, the seat is given close to them, otherwise any other seat is given.

That is the reason why, if you ever noticed carefully, all talkative aunties group together at the same place quite often, disturbing the peace of others in the same compartment. 🙂
 
This is also the reason why you find yourself bumping into male travelers everytime you travel alone and curse your fate for running into girls only when your mother or sister travels with you!
 
P.S: I’m not sure if this algorithm works only for female passengers travelling alone or even when they are travelling with others.
 
Also, those who insist on beating this system through booking two tickets(one male, one female) at first and then cancelling one at the last moment(the female one) to get seats nearby other females, Guys! For all we know, it may work only for solo female passengers’ reservations booking, so hard luck!

कभी कभी मेरे दिल मैं

कभी कभी मेरे दिल मैं ख्याल आता हैं
कि ज़िंदगी तेरी जुल्फों कि नर्म छांव मैं गुजरने पाती
तो शादाब हो भी सकती थी।

यह रंज-ओ-ग़म कि सियाही जो दिल पे छाई हैं
तेरी नज़र कि शुआओं मैं खो भी सकती थी।

मगर यह हो न सका और अब ये आलम हैं
कि तू नहीं, तेरा ग़म तेरी जुस्तजू भी नहीं।

गुज़र रही हैं कुछ इस तरह ज़िंदगी जैसे,
इससे किसी के सहारे कि आरझु भी नहीं.

न कोई राह, न मंजिल, न रौशनी का सुराग
भटक रहीं है अंधेरों मैं ज़िंदगी मेरी.

इन्ही अंधेरों मैं रह जाऊँगा कभी खो कर
मैं जानता हूँ मेरी हम-नफस, मगर यूंही

कभी कभी मेरे दिल मैं ख्याल आता है.

Chicken Ghee Roast

Chicken Ghee Roast

chicken ghee roast
Chicken Ghee Roast ~ Mangalore Style

A Mangalorean delicacy, Chicken Ghee Roast, is a classic recipe among South Indian chicken dishes. Its origins go back to a small town, Kundapur, close to Mangalore. You will find this exotic chicken dish on almost every Banglore restaurant menu. Fiery red, tangy and spicy with an unmistakable flavor of ghee roasted spices, this authentic home style chicken dish is not for the faint heart. Definitely a cold weather favorite that is sure to warm your palate as well as your heart. :)

mangalore-chicken-ghee-roast
Mangalore Chicken Ghee Roast

Do not skimp on the ghee as it is the flavor of clarified butter that gives the dish its distinct flavor. One of the best Banglore that I have tried. I served the Chicken ghee roast with Ghee rice and sambar. Made for a delectable mid day meal.

Chicken Ghee Roast Recipe

Prep time: 15 min
Cook time: 45 min
Yield: 5
Main Ingredients: chicken ghee

Ingredients

  • Chicken – 1 kg, bite sized pieces, washed
  • Curd – 1/2 cup, thick yogurt
  • Turmeric powder – 1/2 tsp
  • Lemon juice – 1 tbsp
  • Salt to taste
  • Jaggery – 2 tsps (or sugar)
  • Curry leaves – 1 sprig
  • Ghee – 6 tbsps
  • Dry red chilies – 7 to 8, large (spicy variety)
  • Dry red chilies – 3 (small variety)
  • Black peppercorns – 7-8
  • Cloves – 3
  • Fenugreek seeds – pinch
  • Coriander seeds – 1 1/2 tbsps
  • Cumin seeds – 1/2 tsp
  • Garlic flakes – 7-8
  • Tamarind paste – 1 1/2 tbsps

Method

  1. Marinate chicken in curd, turmeric powder, lemon juice and half a tsp of salt for a minimum of 2 to 3 hours or overnight in the refrigerator.
  2. Dry roast the red chilies on low flame for 2 mts. Do not burn them. Remove from fire and keep aside. In the same pan, add a tsp of ghee and roast, fenugreek seeds, cumin seeds, coriander seeds, cloves and peppercorns on low flame for 3 minutes. Remove from fire and cool.
  3. Grind the roasted red chilies and spices along with garlic and tamarind to a fine paste. Keep aside.
  4. Heat 2 1/2 tbsps ghee in a heavy bottomed vessel, place the marinated pieces along with the marinade and cook for 20-22 mts or till its three foiurth cooked.
  5. Remove the sauteed chicken pieces and keep aside. Remove the remaining liquid into another bowl.
  6. In the same vessel, add the remaining ghee, and add the ground paste. Saute on low to medium flame for 8-9 mts to till the ghee separates.
  7. Add the chicken pieces and mix well. Add the left over liquid (while cooking chicken) and jaggery and cook on medium flame for 4 mts. Add salt to taste and mix.
  8. Reduce flame, place lid and cook till the chicken is cooked and you have a thick coating of the masala to the chicken pieces. This is not a curry, its a roast dish.
  9. Remove lid, roast the chicken for 2-3 mts. Turn off flame, remove onto a serving bowl.
  10. Garnish with curry leaves and serve with ghee rice, any flavored rice of your choice or white rice.

Tips

  • If you do not have the small variety of dry red chilies, use 10 large dry red chilies. Those who can take the heat of the red chilies, can increase it to 14-15.

There are quite a few chicken dishes among Mangalore recipes. But a culinary gem among them all is the Chicken Ghee Roast. Goes well with ghee rice.