Google Interview Question for Software Engineer / Developers






Comment hidden because of low score. Click to expand.
2
of 2 vote

We can have a master and a number of slave storage server with the replication factor of 3 synchronised by the master. When master gets the query, it evaluates a hash and returns the user the location handle of the slave storage server that actually has the data. The client can now go directly to the server holding the value of his requested key and get it. This works just like the google file system and scales to a huge number of queries per second. The main benefit is that the data never flows through the master, so the latency is very low.

- Ankur December 15, 2013 | Flag Reply
Comment hidden because of low score. Click to expand.
1
of 1 vote

we can design it using the token-ring topology. Distribute the (key,value) set among the processors connected in token-ring fashion. For query processing just pass the token in ring if local processor does not have enough data to serve. After getting and serving the data , the processor may maintain a cache for further queries related to this field.For replication purpose: we need some naming scheme which i think if number of systems in ring are less and connected over LAN then there physical id may be sufficiently added to duplicate data. For updation problems we can use "log write ahead" technique.

- mrn July 14, 2011 | Flag Reply
Comment hidden because of low score. Click to expand.
1
of 1 vote

We can have a number of systems serving a range of key-val pairs.
Periodically, each system will broadcast its range of keys served to other systems.
A client can connect to any system to get the value for a key.
If that particular server doesn't have the answer, it can redirect the client to the
appropriate system.

- mytestaccount2 August 24, 2013 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

Can you please tell what your approach was? It can give a hint in solving this question.

- anonymous April 30, 2011 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

You could do something similar to Memcached, but servers would be something like Master/Slave for availability

- dantepy May 21, 2011 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

We can have a master and a number of slave storage server with the replication factor of 3 synchronised by the master. When master gets the query, it evaluates a hash and returns the user the location handle of the slave storage server that actually has the data. The client can now go directly to the server holding the value of his requested key and get it. This works just like the google file system and scales to a huge number of queries per second. The main benefit is that the data never flows through the master, so the latency is very low.

- Ankur December 15, 2013 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

A distributed system can be either have a client-server architecture or peer to peer architecture. If in this case, we are taking into consideration client-server, then the master and slave design can be used. But in case of peer to peer systems, it is a Distributed Hash Table.

- Anonymous October 21, 2014 | Flag Reply
Comment hidden because of low score. Click to expand.
-2
of 2 vote

This question is on the lines of google's map reduce framework.

- Siddhesh D September 27, 2011 | Flag Reply


Add a Comment
Name:

Writing Code? Surround your code with {{{ and }}} to preserve whitespace.

Books

is a comprehensive book on getting a job at a top tech company, while focuses on dev interviews and does this for PMs.

Learn More

Videos

CareerCup's interview videos give you a real-life look at technical interviews. In these unscripted videos, watch how other candidates handle tough questions and how the interviewer thinks about their performance.

Learn More

Resume Review

Most engineers make critical mistakes on their resumes -- we can fix your resume with our custom resume review service. And, we use fellow engineers as our resume reviewers, so you can be sure that we "get" what you're saying.

Learn More

Mock Interviews

Our Mock Interviews will be conducted "in character" just like a real interview, and can focus on whatever topics you want. All our interviewers have worked for Microsoft, Google or Amazon, you know you'll get a true-to-life experience.

Learn More