Legal claims defining the scope of protection. Each claim is shown in both the original legal language and a plain English translation.
1. A method for causally ordering a set of events in a cluster of nodes operating as a distributed file system comprising: maintaining an event transaction log, wherein events in the event transaction log are associated with an event identifier and each event includes a set of viewed inode number and inode revision number pairs and a set of modified inode number and inode revision number pairs; generating an inode map based on the event transaction log, wherein the inode map maps event identifiers to inode revision numbers associated with each inode number referenced in the event transaction log; generating a directed acyclic graph based on the inode map and the event transaction log, wherein a vertex in the directed acyclic graph represents an event identifier and an edge in the directed acyclic graph represents a causal relationship, wherein edges in the directed acyclic graph are strong if the causal relationship is based on the set of modified inode number and inode revision number pairs and weak if the causal relationship is based on an earlier event of the causal relationship being in the set of viewed inode number and inode revision number pairs; and causally ordering events in the event transaction log based on a topological sort of the directed acyclic graph.
2. The method of claim 1 further comprising: in response to drawing a strong edge that contradicts a weak edge, removing the weak edge from the directed acyclic graph.
3. The method of claim 1 , wherein generating the directed acyclic graph includes not drawing a weak edge between two vertices if a strong edge has already been drawn between the two vertices.
4. The method of claim 1 further comprising: in response to the topological sort indicating a contradictory loop, removing a weak edge from the directed acyclic graph.
5. The method of claim 1 , wherein a weak edge is converted to a strong edge if event associated with the view inode number and inode revision number pair is associated with an exclusive lock.
6. A system comprising at least one storage device and at least one hardware processor configured to: maintain an event transaction log, wherein events in the event transaction log are associated with an event identifier and each event includes a set of viewed inode number and inode revision number pairs and a set of modified inode number and inode revision number pairs; generate an inode map based on the event transaction log, wherein the inode map maps event identifiers to inode revision numbers associated with each inode number referenced in the event transaction log; generate a directed acyclic graph based on the inode map and the event transaction log, wherein a vertex in the directed acyclic graph represents an event identifier and an edge in the directed acyclic graph represents a causal relationship, wherein edges in the directed acyclic graph are strong if the causal relationship is based on the set of modified inode number and inode revision number pairs and weak if the causal relationship is based on an earlier event of the causal relationship being in the set of viewed inode number and inode revision number pairs; and causally order events in the event transaction log based on a topological sort of the directed acyclic graph.
7. The system of claim 6 , further configured to: in response to drawing a strong edge that contradicts a weak edge, remove the weak edge from the directed acyclic graph.
8. The system of claim 6 , wherein generating the directed acyclic graph includes not drawing a weak edge between two vertices if a strong edge has already been drawn between the two vertices.
9. The system of claim 6 , further configured to: in response to the topological sort indicating a contradictory loop, remove a weak edge from the directed acyclic graph.
A system for analyzing and resolving contradictions in directed acyclic graphs (DAGs) is disclosed. The system detects topological sorting errors, specifically identifying contradictory loops within the graph structure. When such a loop is detected, the system automatically removes a weak edge from the DAG to resolve the contradiction. The weak edge is defined as an edge that, when removed, does not significantly disrupt the overall graph structure or its intended functionality. This process ensures the graph remains acyclic while preserving as much of the original structure as possible. The system may be applied in various domains where DAGs are used, such as dependency management, scheduling, or data processing pipelines, to maintain logical consistency and prevent infinite loops or circular dependencies. The removal of weak edges is performed in a way that minimizes impact on the graph's integrity, ensuring reliable operation in applications requiring strict acyclic constraints.
10. The system of claim 6 , wherein a weak edge is converted to a strong edge if event associated with the view inode number and inode revision number pair is associated with an exclusive lock.
11. A non-transitory computer readable medium with program instructions stored thereon to perform the following acts: maintaining an event transaction log, wherein events in the event transaction log are associated with an event identifier and each event includes a set of viewed inode number and inode revision number pairs and a set of modified inode number and inode revision number pairs; generating an inode map based on the event transaction log, wherein the inode map maps event identifiers to inode revision numbers associated with each inode number referenced in the event transaction log; generating a directed acyclic graph based on the inode map and the event transaction log, wherein a vertex in the directed acyclic graph represents an event identifier and an edge in the directed acyclic graph represents a causal relationship, wherein edges in the directed acyclic graph are strong if the causal relationship is based on the set of modified inode number and inode revision number pairs and weak if the causal relationship is based on an earlier event of the causal relationship being in the set of viewed inode number and inode revision number pairs; and causally ordering events in the event transaction log based on a topological sort of the directed acyclic graph.
This invention relates to a system for tracking and analyzing file system events to determine causal relationships between operations. The technology addresses the challenge of reconstructing the sequence of file system changes, particularly in distributed or concurrent environments where events may not occur in a strictly linear order. The system maintains an event transaction log where each event is tagged with an identifier and includes pairs of inode numbers (file identifiers) and their revision numbers, both for viewed and modified inodes. From this log, an inode map is generated, linking event identifiers to inode revision numbers. A directed acyclic graph (DAG) is then constructed, where nodes represent events and edges represent causal dependencies. Edges are classified as strong (based on modified inodes) or weak (based on viewed inodes). The system uses a topological sort of this DAG to determine a causal ordering of events, enabling accurate reconstruction of file system state changes. This approach improves consistency in distributed file systems and aids in debugging concurrent operations.
12. The non-transitory computer readable medium of claim 11 , with program instructions stored thereon to further perform the following acts: in response to drawing a strong edge that contradicts a weak edge, removing the weak edge from the directed acyclic graph.
13. The non-transitory computer readable medium of claim 11 , wherein generating the directed acyclic graph includes not drawing a weak edge between two vertices if a strong edge has already been drawn between the two vertices.
14. The non-transitory computer readable medium of claim 11 , with program instructions stored thereon to further perform the following acts: in response to the topological sort indicating a contradictory loop, removing a weak edge from the directed acyclic graph.
15. The non-transitory computer readable medium of claim 11 , wherein a weak edge is converted to a strong edge if event associated with the view inode number and inode revision number pair is associated with an exclusive lock.
Unknown
February 23, 2021
Browse 5M+ US patents with plain-English claim translations and AI-generated analysis.