There is some data related to temperatures of different cities. One side(thread), will be updating the values and multiple clients will be reading the values. how do you achieve synchronization?
Answer / mskumar
My Answer was:-
Thread updating the data:- Should acquire the MUTEX lock and update the data & release the MUTEX.
While threads try to read the Data :- Should acquire the lock such that only read access allowed during the lock, not the write lock so that any no.of clients trying to read can read at the same time.
Can some give me thier thoughts if any?
| Is This Answer Correct ? | 1 Yes | 1 No |
What is the difference between 32 bit and 64 bit os?
What are the various ipc mechanisms?
What are the essential conditions for a deadlock to occur?
What are 4 types of operating systems?
Explain segmentation with paging?
What is Difference between thread and process?
28 Answers AirTies, Azingo, Bloomberg, Encora, Goldman Sachs, HCL, HP, MES, Microsoft, Samsung,
much time is spent usually in each phases and why?
How do I go to a specific line in vi?
There is some data related to temperatures of different cities. One side(thread), will be updating the values and multiple clients will be reading the values. how do you achieve synchronization?
What is the difference between exclusive lock and shared lock?
How long should a chkdsk r take?
What is Semaphore?