Directory oplock
First Claim
1. A method for managing a directory oplock, the method comprising:
- receiving an oplock request for a directory oplock on a directory, the oplock request comprising a first target key and a first parent key, wherein the first target key comprises a first unique identifier for a client related to the oplock request;
generating the directory oplock based upon the oplock request;
receiving an access request for access to an object within the directory, the access request comprising a second target key and a second parent key, wherein the second parent key comprises a second unique identifier for a client related to the access request;
comparing the first target key to the second parent key;
breaking, executed by a processor, the directory oplock if the second parent key does not match the first target key; and
not breaking the directory oplock if the second parent key does match the first target key.
2 Assignments
0 Petitions
Accused Products
Abstract
Current file systems may implement opportunistic locks on files that allow clients to locally cache file data, while promoting data consistency when multiple clients read/write the same file. Unfortunately, when a client locally caches directory content of a directory, the file system may lack a mechanism for notifying the client of changes to the directory that would render the cached directory content “stale”. Accordingly, one or more systems and/or techniques for managing a directory oplock are disclosed herein. A directory oplock may be generated based upon an oplock request comprising a first target key and a first parent key. Subsequent access requests for access to the directory or objects therein may be compared with the directory oplock to determine whether to break the directory oplock, and notify the client (e.g., directory oplock is broken if the client submitting the access request is different than the client owning the directory oplock).
9 Citations
20 Claims
-
1. A method for managing a directory oplock, the method comprising:
-
receiving an oplock request for a directory oplock on a directory, the oplock request comprising a first target key and a first parent key, wherein the first target key comprises a first unique identifier for a client related to the oplock request; generating the directory oplock based upon the oplock request; receiving an access request for access to an object within the directory, the access request comprising a second target key and a second parent key, wherein the second parent key comprises a second unique identifier for a client related to the access request; comparing the first target key to the second parent key; breaking, executed by a processor, the directory oplock if the second parent key does not match the first target key; and not breaking the directory oplock if the second parent key does match the first target key. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9)
-
-
10. A system for maintaining a directory oplock, comprising:
-
at least one processor; and memory encoding computer executable instructions, that, when executed by the at least one processor, perform a method for managing a directory oplock, the method comprising; receiving an oplock request for a directory oplock on a directory, the oplock request comprising a first target key and a first parent key, wherein the first target key comprises a first unique identifier for a client related to the oplock request; generating the directory oplock based upon the oplock request; receiving an access request for access to an object within the directory, the access request comprising a second target key and a second parent key, wherein the second parent key comprises a second unique identifier for a client related to the access request; comparing the first target key to the second parent key; breaking the directory oplock if the second parent key does not match the first target key; and not breaking the directory oplock if the second parent key does match the first target key. - View Dependent Claims (11, 12, 13, 14, 15, 16, 17, 18, 19)
-
-
20. A computing device encoding computer executable instructions that, when executed by at least one processor, perform a method for managing a directory oplock, the method comprising:
-
receiving an oplock request for a directory oplock on a directory, the oplock request comprising a first target key and a first parent key; generating the directory oplock based upon the oplock request; receiving an access request for access to an object within the directory, the access request comprising a second target key and a second parent key; when the second parent key does not match the first target key, performing operations comprising; breaking the directory oplock; sending notification of the break to a first client originating the oplock request; and sending notification to a second client originating the access request to wait until acknowledgement of the break by the first client, the access request corresponding to a request by the second client to perform an operation upon the directory; and when the second parent key matches the first target key, not breaking the directory oplock.
-
Specification