Fundamentals Of Concurrency

3.Composing Objects

Invarient: multiple variable Potraying unique state of Object if anyone changes it violates Invatient state.
e.g increment a number i.e read-modify-write if performed by multithread not as atomic operation
then the Invarient may not hold. bcoz with some unlucky time simultaeous read may happen

TODO : locking examples – on differnt object results in unsaafe state ehere as on same object reslyurs in safe state.

Published by

Unknown's avatar

sevanand yadav

software engineer working as web developer having specialization in spring MVC with mysql,hibernate

Leave a comment