Hello all,
I have a Map with Hotel Bookings as Cache ...
How did people implement search with Synchronization ?
Is the map locked while another
thread is searching for Bookings ?
Should delete be possible during a search ?
In Andrew's book, there was no locking in the search algorithm, what if a thread deleted a record after a call to <Map>.keySet.iterator() ?
I'm just wondering if using reentrant.readWriteLock to lock for even searches is not going to impact significantly on the app.
Regards