摘要 |
Providing access to a shared resource in a computing environment involves maintaining a timestamp for each shared resource, the timestamp representing the time the resource was last accessed. Then, detecting if the resource is reserved before obtaining access to the resource, by reading the resource timestamp, and if the timestamp represents a future time relative to the current time, indicating that the resource is reserved and delaying access to the resource. If the resource is unreserved, then accessing the resource by reading the resource timestamp to detect any changes in the timestamp since the last reading; if unchanged, then accessing the resource. If the resource is unreserved, then obtaining exclusive access to the resource by reserving the resource by incrementing its timestamp by a reservation period; accessing the resource; and resetting the resource timestamp to the current time.
|