<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://debianws.lexgopc.com/wiki143/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=103.53.232.35</id>
	<title>wiki143 - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="http://debianws.lexgopc.com/wiki143/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=103.53.232.35"/>
	<link rel="alternate" type="text/html" href="http://debianws.lexgopc.com/wiki143/index.php?title=Special:Contributions/103.53.232.35"/>
	<updated>2026-05-03T21:09:57Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.1</generator>
	<entry>
		<id>http://debianws.lexgopc.com/wiki143/index.php?title=Happened-before&amp;diff=706368</id>
		<title>Happened-before</title>
		<link rel="alternate" type="text/html" href="http://debianws.lexgopc.com/wiki143/index.php?title=Happened-before&amp;diff=706368"/>
		<updated>2025-06-02T19:34:25Z</updated>

		<summary type="html">&lt;p&gt;103.53.232.35: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Short description|Relation between two events in computer science}}&lt;br /&gt;
In [[computer science]], the &#039;&#039;&#039;happened-before&#039;&#039;&#039; [[binary relation|relation]] (denoted: &amp;lt;math&amp;gt;\to \;&amp;lt;/math&amp;gt;) is a relation between the result of two events, such that if one event should happen before another event, the result must reflect that, even if those events are in reality executed out of order (usually to optimize program flow). This involves [[partially ordered set|ordering]] events based on the potential [[causal relationships|causal relationship]] of pairs of events in a concurrent system, especially [[asynchronous communication|asynchronous]] [[distributed systems]]. It was formulated by [[Leslie Lamport]].&amp;lt;ref&amp;gt;Lamport, Leslie (1978). [http://research.microsoft.com/en-us/um/people/lamport/pubs/time-clocks.pdf &amp;quot;Time, Clocks and the Ordering of Events in a Distributed System&amp;quot;], &#039;&#039;Communications of the ACM&#039;&#039;, 21(7), 558-565.&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The happened-before relation is formally defined as the least [[strict partial order]] on events such that:&lt;br /&gt;
* If events &amp;lt;math&amp;gt;a \;&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;b \;&amp;lt;/math&amp;gt; occur on the same process, &amp;lt;math&amp;gt;a \to b\;&amp;lt;/math&amp;gt; if the occurrence of event &amp;lt;math&amp;gt;a \;&amp;lt;/math&amp;gt; preceded the occurrence of event &amp;lt;math&amp;gt;b \;&amp;lt;/math&amp;gt;.&lt;br /&gt;
* If event &amp;lt;math&amp;gt;a \;&amp;lt;/math&amp;gt; is the sending of a message and event &amp;lt;math&amp;gt;b \;&amp;lt;/math&amp;gt; is the reception of the message sent in event &amp;lt;math&amp;gt;a \;&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;a \to b\;&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If two events happen in different isolated processes (that do not exchange messages directly or indirectly via third-party processes), then the two processes are said to be concurrent, that is neither &amp;lt;math&amp;gt;a \to b&amp;lt;/math&amp;gt; nor &amp;lt;math&amp;gt;b \to a&amp;lt;/math&amp;gt; is true.&amp;lt;ref&amp;gt;{{Cite web|title=Distributed Systems 3rd edition (2017)|url=https://www.distributed-systems.net/index.php/books/ds3/|access-date=2021-03-20|website=DISTRIBUTED-SYSTEMS.NET|language=en-US}}&amp;lt;/ref&amp;gt; &lt;br /&gt;
&lt;br /&gt;
If there are other causal relationships between events in a given system, such as between the creation of a process and its first event, these relationships are also added to the definition.&lt;br /&gt;
For example, in some programming languages such as Java,{{sfn|Goetz|Peierls|Bloch|Bowbeer|2006|loc=§16.1.3 The Java Memory Model in 500 words or less|pp=339-342}} C, C++ or Rust, a &#039;&#039;&#039;happens-before&#039;&#039;&#039; edge exists if memory written to by statement A is visible to statement B, that is, if statement A completes its write before statement B starts its read.&lt;br /&gt;
&lt;br /&gt;
Like all strict partial orders, the happened-before relation is &#039;&#039;[[transitive relation|transitive]]&#039;&#039;, &#039;&#039;[[irreflexive relation|irreflexive]]&#039;&#039; (and vacuously, &#039;&#039;[[Asymmetric relation|asymmetric]]&#039;&#039;), i.e.:&lt;br /&gt;
* &amp;lt;math&amp;gt;\forall a, b, c&amp;lt;/math&amp;gt;, if &amp;lt;math&amp;gt;a \to b\;&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;b \to c\;&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;a \to c\;&amp;lt;/math&amp;gt; (transitivity). This means that for any three events &amp;lt;math&amp;gt;a, b, c&amp;lt;/math&amp;gt;, if &amp;lt;math&amp;gt;a&amp;lt;/math&amp;gt; happened before &amp;lt;math&amp;gt;b&amp;lt;/math&amp;gt;, and &amp;lt;math&amp;gt;b&amp;lt;/math&amp;gt; happened before &amp;lt;math&amp;gt;c&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;a&amp;lt;/math&amp;gt; must have happened before &amp;lt;math&amp;gt;c&amp;lt;/math&amp;gt;.&lt;br /&gt;
* &amp;lt;math&amp;gt;\forall a, a \nrightarrow  a&amp;lt;/math&amp;gt; (irreflexivity). This means that no event can happen before itself.&lt;br /&gt;
* &amp;lt;math&amp;gt;\forall a, b,&amp;lt;/math&amp;gt; if &amp;lt;math&amp;gt;a \to b&amp;lt;/math&amp;gt; then &amp;lt;math&amp;gt;b \nrightarrow a&amp;lt;/math&amp;gt; (asymmetry). This means that for any two events &amp;lt;math&amp;gt;a, b&amp;lt;/math&amp;gt;, if &amp;lt;math&amp;gt;a&amp;lt;/math&amp;gt; happened before &amp;lt;math&amp;gt;b&amp;lt;/math&amp;gt; then &amp;lt;math&amp;gt;b&amp;lt;/math&amp;gt; cannot have happened before &amp;lt;math&amp;gt;a&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Let us observe that the asymmetry property directly follows from the previous properties: by contradiction, let us suppose that &amp;lt;math&amp;gt;\forall a, b,&amp;lt;/math&amp;gt; we have &amp;lt;math&amp;gt;a \to b\;&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;b \to a&amp;lt;/math&amp;gt;. Then by transitivity we have &amp;lt;math&amp;gt;a \to a,&amp;lt;/math&amp;gt; which contradicts irreflexivity.&lt;br /&gt;
&lt;br /&gt;
The processes that make up a distributed system have no knowledge of the happened-before relation unless they use a [[logical clock]], like a [[Lamport clock]] or a [[vector clock]]. This allows one to design algorithms for [[mutual exclusion]], and tasks like debugging or optimising distributed systems.&lt;br /&gt;
&lt;br /&gt;
== Byzantine Faults and the Impossibility of Detection ==&lt;br /&gt;
In distributed systems, the happened-before relation can be accurately tracked under crash failures using vector clocks, their variants, and other causality tracking mechanisms. However, under Byzantine faults, where processes may behave arbitrarily or maliciously, it is fundamentally impossible to detect the happened-before relation &amp;lt;ref&amp;gt;{{cite conference&lt;br /&gt;
 | last1 = Misra&lt;br /&gt;
 | first1 = Anshuman&lt;br /&gt;
 | last2 = Kshemkalyani&lt;br /&gt;
 | first2 = Ajay D.&lt;br /&gt;
 | title = Detecting Causality in the Presence of Byzantine Processes: There is No Holy Grail&lt;br /&gt;
 | book-title = 2022 IEEE 21st International Symposium on Network Computing and Applications (NCA)&lt;br /&gt;
 | year = 2022&lt;br /&gt;
 | pages = 73–80&lt;br /&gt;
 | doi = 10.1109/NCA57778.2022.10013644&lt;br /&gt;
 | publisher = IEEE&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;. The intuitive reasoning for this is that Byzantine processes can forge or manipulate metadata, making it impossible to determine true causal dependencies.&lt;br /&gt;
&lt;br /&gt;
==See also==&lt;br /&gt;
* [[Race condition]]&lt;br /&gt;
* [[Java memory model]]&lt;br /&gt;
* [[Lamport timestamps]]&lt;br /&gt;
* [[Logical clock]]&lt;br /&gt;
&lt;br /&gt;
==Citations==&lt;br /&gt;
{{reflist}}&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
*{{cite book&lt;br /&gt;
 | last = Goetz&lt;br /&gt;
 | first = Brian&lt;br /&gt;
 | last2 = Peierls&lt;br /&gt;
 | first2 = Tim&lt;br /&gt;
 | last3 = Bloch&lt;br /&gt;
 | first3 = Joshua&lt;br /&gt;
 | last4 = Bowbeer&lt;br /&gt;
 | first4 = Joseph&lt;br /&gt;
 | last5 = Holmes&lt;br /&gt;
 | first5 = David&lt;br /&gt;
 | last6 = Lea&lt;br /&gt;
 | first6 = Doug&lt;br /&gt;
 | year = 2006&lt;br /&gt;
 | title = Java Concurrency in Practice&lt;br /&gt;
 | publisher = Addison Wesley&lt;br /&gt;
 | isbn = 0-321-34960-1&lt;br /&gt;
 | url = https://archive.org/details/javaconcurrencyi00goet&lt;br /&gt;
 }}&lt;br /&gt;
&lt;br /&gt;
{{DEFAULTSORT:Happened-Before}}&lt;br /&gt;
[[Category:Logical clock algorithms]]&lt;br /&gt;
[[Category:Distributed computing problems]]&lt;br /&gt;
[[Category:Transitive relations]]&lt;/div&gt;</summary>
		<author><name>103.53.232.35</name></author>
	</entry>
	<entry>
		<id>http://debianws.lexgopc.com/wiki143/index.php?title=Vector_clock&amp;diff=1072441</id>
		<title>Vector clock</title>
		<link rel="alternate" type="text/html" href="http://debianws.lexgopc.com/wiki143/index.php?title=Vector_clock&amp;diff=1072441"/>
		<updated>2025-06-01T15:08:53Z</updated>

		<summary type="html">&lt;p&gt;103.53.232.35: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Short description|Algorithm for partial ordering of events and detecting causality in distributed systems}}&lt;br /&gt;
{{distinguish|Version vector}}&lt;br /&gt;
A &#039;&#039;&#039;vector clock&#039;&#039;&#039; is a [[data structure]] used for determining the [[partial ordering]] of events in a [[distributed system]] and detecting [[causality]] violations. Just as in [[Lamport timestamp]]s, inter-process messages contain the state of the sending process&#039;s [[logical clock]]. A vector clock of a system of &#039;&#039;N&#039;&#039; processes is an [[array data structure|array]]/vector of &#039;&#039;N&#039;&#039; logical clocks, one clock per process; a local &amp;quot;largest possible values&amp;quot; copy of the global clock-array is kept in each process.&lt;br /&gt;
&lt;br /&gt;
Denote &amp;lt;math&amp;gt;VC_i&amp;lt;/math&amp;gt; as the vector clock maintained by process &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;, the clock updates proceed as follows:&amp;lt;ref&amp;gt;{{Cite web|title=Distributed Systems 3rd edition (2017)|url=https://www.distributed-systems.net/index.php/books/ds3/|access-date=2021-03-21|website=DISTRIBUTED-SYSTEMS.NET|language=en-US}}&amp;lt;/ref&amp;gt;&lt;br /&gt;
[[Image:Vector Clock.svg|thumb|upright=1.9|Example of a system of vector clocks. Events in the blue region are the causes leading to event B4, whereas those in the red region are the effects of event B4.]]&lt;br /&gt;
* Initially all clocks are zero.&lt;br /&gt;
* Each time a process experiences an internal event, it increments its own [[logical clock]] in the vector by one. For instance, upon an event at process &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;, it updates &amp;lt;math&amp;gt;VC_{i}[i] \leftarrow VC_{i}[i] + 1&amp;lt;/math&amp;gt;.&lt;br /&gt;
* Each time a process sends a message, it increments its own logical clock in the vector by one (as in the bullet above, but not twice for the same event) then it pairs the message with a copy of its own vector and finally sends the pair.&lt;br /&gt;
* Each time a process receives a message-vector clock pair, it increments its own logical clock in the vector by one and updates each element in its vector by taking the maximum of the value in its own vector clock and the value in the vector in the received pair (for every element). For example, if process &amp;lt;math&amp;gt;P_i&amp;lt;/math&amp;gt; receives a message &amp;lt;math&amp;gt;(m, VC_{j})&amp;lt;/math&amp;gt; from &amp;lt;math&amp;gt;P_j&amp;lt;/math&amp;gt;, it first increments its own logical clock in the vector by one &amp;lt;math&amp;gt;VC_{i}[i]\leftarrow VC_{i}[i]+1&amp;lt;/math&amp;gt; and then updates its entire vector by setting &amp;lt;math&amp;gt;VC_{i}[k]\leftarrow \max(VC_{i}[k], VC_{j}[k]), \forall k&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
==History==&lt;br /&gt;
&lt;br /&gt;
Lamport originated the idea of logical [[Lamport clock]]s in 1978.&amp;lt;ref name=&amp;quot;Lamport 1978&amp;quot;&amp;gt;{{Cite journal | last1 = Lamport | first1 = L. |authorlink1=Leslie Lamport| title = Time, clocks, and the ordering of events in a distributed system | doi = 10.1145/359545.359563 | journal = [[Communications of the ACM ]]| volume = 21 | issue = 7 | pages = 558–565| year = 1978 | s2cid = 215822405 | url=http://research.microsoft.com/users/lamport/pubs/time-clocks.pdf}}&amp;lt;/ref&amp;gt; However, the logical clocks in that paper were scalars, not vectors. The generalization to vector time was developed several times, apparently independently, by different authors in the early 1980s.&amp;lt;ref name=Schwarz&amp;gt;{{cite journal |last1=Schwarz |first1=Reinhard |last2=Mattern |first2=Friedemann |title=Detecting causal relationships in distributed computations: In search of the holy grail |journal=Distributed Computing |date=March 1994 |volume=7 |issue=3 |pages=149–174 |doi=10.1007/BF02277859|s2cid=3065996 |url=https://nbn-resolving.org/urn:nbn:de:hbz:386-kluedo-4006 }}&amp;lt;/ref&amp;gt; At least 6 papers contain the concept.&lt;br /&gt;
&amp;lt;ref&amp;gt;{{cite web |last1=Kuper |first1=Lindsey |title=Who invented vector clocks? |url=https://decomposition.al/blog/2023/04/08/who-invented-vector-clocks/ |website=decomposition ∘ al |language=en |date=8 April 2023}} The papers are (in chronological order):&lt;br /&gt;
* {{cite book |last1=Fischer |first1=Michael J. |last2=Michael |first2=Alan |title=Proceedings of the 1st ACM SIGACT-SIGMOD symposium on Principles of database systems - PODS &#039;82 |chapter=Sacrificing serializability to attain high availability of data in an unreliable network |date=1982 |pages=70 |doi=10.1145/588111.588124|isbn=0897910702 |s2cid=8774876 }}&lt;br /&gt;
* {{cite journal |last1=Parker |first1=D.S. |last2=Popek |first2=G.J. |last3=Rudisin |first3=G. |last4=Stoughton |first4=A. |last5=Walker |first5=B.J. |last6=Walton |first6=E. |last7=Chow |first7=J.M. |last8=Edwards |first8=D. |last9=Kiser |first9=S. |last10=Kline |first10=C. |title=Detection of Mutual Inconsistency in Distributed Systems |journal=IEEE Transactions on Software Engineering |date=May 1983 |volume=SE-9 |issue=3 |pages=240–247 |doi=10.1109/TSE.1983.236733|s2cid=2483222 }}&lt;br /&gt;
* {{cite book |last1=Wuu |first1=Gene T.J. |last2=Bernstein |first2=Arthur J. |title=Proceedings of the third annual ACM symposium on Principles of distributed computing - PODC &#039;84 |chapter=Efficient solutions to the replicated log and dictionary problems |date=1984 |pages=233–242 |doi=10.1145/800222.806750|isbn=0897911431 |s2cid=2384672 }}&lt;br /&gt;
* {{cite journal |last1=Strom |first1=Rob |last2=Yemini |first2=Shaula |title=Optimistic recovery in distributed systems |journal=ACM Transactions on Computer Systems |date=August 1985 |volume=3 |issue=3 |pages=204–226 |doi=10.1145/3959.3962|s2cid=1941122 |doi-access=free }}&lt;br /&gt;
* {{cite tech report |last1=Schmuck |first1=Frank B. |title=Software clocks and the order of events in a distributed system |date=November 1985 |type=unpublished }}&lt;br /&gt;
* {{cite book |last1=Liskov |first1=Barbara |last2=Ladin |first2=Rivka |title=Proceedings of the fifth annual ACM symposium on Principles of distributed computing - PODC &#039;86 |chapter=Highly available distributed services and fault-tolerant distributed garbage collection |date=1986 |pages=29–39 |doi=10.1145/10590.10593|isbn=0897911989 |s2cid=16148617 }}&lt;br /&gt;
* {{cite journal |last1=Raynal |first1=Michel |title=A distributed algorithm to prevent mutual drift between n logical clocks |journal=Information Processing Letters |date=February 1987 |volume=24 |issue=3 |pages=199–202 |doi=10.1016/0020-0190(87)90186-4}}&lt;br /&gt;
&amp;lt;/ref&amp;gt; The papers canonically cited in reference to vector clocks are Colin Fidge’s and [[Friedemann Mattern]]’s 1988 works,&lt;br /&gt;
&amp;lt;ref&amp;gt;{{cite conference|first=Colin J.|last=Fidge|date=February 1988|title=Timestamps in message-passing systems that preserve the partial ordering|book-title=Proceedings of the 11th Australian Computer Science Conference (ACSC&#039;88)|volume=10|issue=1 | editor = K. Raymond|pages=56–66 | url = http://zoo.cs.yale.edu/classes/cs426/2012/lab/bib/fidge88timestamps.pdf&lt;br /&gt;
 | access-date = 2009-02-13}}&amp;lt;/ref&amp;gt;&amp;lt;ref&amp;gt;{{cite conference|title=Virtual Time and Global States of Distributed systems|book-title=Proc. Workshop on Parallel and Distributed Algorithms|first=Friedemann|last=Mattern | editor-last=Cosnard | editor-first=M. &lt;br /&gt;
 | place=Chateau de Bonas, France |date=October 1988 |publisher=Elsevier&lt;br /&gt;
 | pages=215–226}}&amp;lt;/ref&amp;gt; as they (independently) established the name &amp;quot;vector clock&amp;quot; and the mathematical properties of vector clocks.&amp;lt;ref name=Schwarz/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Partial ordering property==&lt;br /&gt;
&lt;br /&gt;
Vector clocks allow for the partial causal ordering of events. Defining the following:&lt;br /&gt;
* &amp;lt;math&amp;gt;VC(x)&amp;lt;/math&amp;gt; denotes the vector clock of event &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt;, and &amp;lt;math&amp;gt;VC(x)_z&amp;lt;/math&amp;gt; denotes the component of that clock for process &amp;lt;math&amp;gt;z&amp;lt;/math&amp;gt;.&lt;br /&gt;
* &amp;lt;math&amp;gt;VC(x) &amp;lt; VC(y) \iff \forall z [VC(x)_z \le VC(y)_z] \land \exists z&#039; [ VC(x)_{z&#039;} &amp;lt; VC(y)_{z&#039;} ]&amp;lt;/math&amp;gt;&lt;br /&gt;
** In English: &amp;lt;math&amp;gt;VC(x)&amp;lt;/math&amp;gt; is less than &amp;lt;math&amp;gt;VC(y)&amp;lt;/math&amp;gt;, if and only if &amp;lt;math&amp;gt;VC(x)_z&amp;lt;/math&amp;gt; is less than or equal to &amp;lt;math&amp;gt;VC(y)_z&amp;lt;/math&amp;gt; for all process indices &amp;lt;math&amp;gt;z&amp;lt;/math&amp;gt;, and at least one of those relationships is strictly smaller (that is, &amp;lt;math&amp;gt;VC(x)_{z&#039;} &amp;lt; VC(y)_{z&#039;}&amp;lt;/math&amp;gt;).&lt;br /&gt;
* &amp;lt;math&amp;gt;x \to y\;&amp;lt;/math&amp;gt; denotes that event &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; happened before event &amp;lt;math&amp;gt;y&amp;lt;/math&amp;gt;. It is defined as: if &amp;lt;math&amp;gt;x \to y\;&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;VC(x) &amp;lt; VC(y)&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Properties:&lt;br /&gt;
&lt;br /&gt;
* [[antisymmetric relation|Antisymmetry]]: if &amp;lt;math&amp;gt;VC(a) &amp;lt; VC(b)&amp;lt;/math&amp;gt;, then ¬&amp;lt;math&amp;gt;(VC(b) &amp;lt; VC(a))&amp;lt;/math&amp;gt;&lt;br /&gt;
* [[transitive relation|Transitivity]]: if &amp;lt;math&amp;gt;VC(a) &amp;lt; VC(b)&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;VC(b) &amp;lt; VC(c)&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;VC(a) &amp;lt; VC(c)&amp;lt;/math&amp;gt;; or, if &amp;lt;math&amp;gt;a \to b\;&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;b \to c\;&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;a \to c\;&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Relation with other orders: ==&lt;br /&gt;
* Let &amp;lt;math&amp;gt;RT(x)&amp;lt;/math&amp;gt; be the real time when event &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; occurs. If &amp;lt;math&amp;gt;VC(a) &amp;lt; VC(b)&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;RT(a) &amp;lt; RT(b)&amp;lt;/math&amp;gt;&lt;br /&gt;
* Let &amp;lt;math&amp;gt;C(x)&amp;lt;/math&amp;gt; be the [[Lamport timestamps|Lamport timestamp]] of event &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt;. If &amp;lt;math&amp;gt;VC(a) &amp;lt; VC(b)&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;C(a) &amp;lt; C(b)&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Limitations under Byzantine Failures ==&lt;br /&gt;
Vector clocks can reliably detect causality in distributed systems subject to crash failures. However, when processes behave arbitrarily or maliciously—as in the Byzantine failure model—causality detection becomes fundamentally impossible &amp;lt;ref&amp;gt;{{cite conference&lt;br /&gt;
 | last1 = Misra&lt;br /&gt;
 | first1 = Anshuman&lt;br /&gt;
 | last2 = Kshemkalyani&lt;br /&gt;
 | first2 = Ajay D.&lt;br /&gt;
 | title = Detecting Causality in the Presence of Byzantine Processes: There is No Holy Grail&lt;br /&gt;
 | book-title = 2022 IEEE 21st International Symposium on Network Computing and Applications (NCA)&lt;br /&gt;
 | year = 2022&lt;br /&gt;
 | pages = 73–80&lt;br /&gt;
 | doi = 10.1109/NCA57778.2022.10013644&lt;br /&gt;
 | publisher = IEEE&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;&lt;br /&gt;
, rendering vector clocks ineffective in such environments. This impossibility result holds for all variants of vector clocks, as it stems from core limitations inherent to the problem of causality detection under Byzantine faults.&lt;br /&gt;
&lt;br /&gt;
==Other mechanisms==&lt;br /&gt;
{{Incomplete list|date=June 2023}}&lt;br /&gt;
&lt;br /&gt;
* In 1999, Torres-Rojas and Ahamad developed &#039;&#039;&#039;Plausible Clocks&#039;&#039;&#039;,&amp;lt;ref&amp;gt;{{Citation |author1=Francisco Torres-Rojas |author2=Mustaque Ahamad&lt;br /&gt;
|title=Plausible clocks: constant size logical clocks for distributed systems |journal=Distributed Computing |volume=12 |issue=4 |year=1999 |pages=179–195 |doi=10.1007/s004460050065 |s2cid=2936350&lt;br /&gt;
|url=https://www.cc.gatech.edu/fac/Mustaque.Ahamad/pubs/plausible.ps|url-access=subscription }}&amp;lt;/ref&amp;gt; a mechanism that takes less space than vector clocks but that, in some cases, will totally order events that are causally concurrent.&lt;br /&gt;
&lt;br /&gt;
* In 2005, Agarwal and Garg created &#039;&#039;&#039;Chain Clocks&#039;&#039;&#039;,&amp;lt;ref&amp;gt;{{cite book |last1=Agarwal |first1=Anurag |last2=Garg |first2=Vijay K. |title=Proceedings of the twenty-fourth annual ACM symposium on Principles of distributed computing |chapter=Efficient dependency tracking for relevant events in shared-memory systems |date=17 July 2005 |pages=19–28 |doi=10.1145/1073814.1073818 |chapter-url=http://users.ece.utexas.edu/~garg/dist/agarwal-garg-DC.pdf |access-date=21 April 2021 |publisher=Association for Computing Machinery|isbn=1-58113-994-2 |s2cid=11779779 }}&amp;lt;/ref&amp;gt; a system that tracks dependencies using vectors with size smaller than the number of processes and that adapts automatically to systems with dynamic number of processes.&lt;br /&gt;
* In 2008, Almeida &#039;&#039;et al.&#039;&#039; introduced &#039;&#039;&#039;Interval Tree Clocks&#039;&#039;&#039;.&amp;lt;ref&amp;gt;{{Citation |&lt;br /&gt;
last1=Almeida | first1=Paulo | last2=Baquero | first2=Carlos | last3=Fonte | first3=Victor |&lt;br /&gt;
contribution=Interval Tree Clocks: A Logical Clock for Dynamic Systems |&lt;br /&gt;
title=Principles of Distributed Systems |&lt;br /&gt;
volume=5401 |&lt;br /&gt;
publisher=Springer-Verlag, Lecture Notes in Computer Science |&lt;br /&gt;
year=2008 | doi=10.1007/978-3-540-92221-6 |&lt;br /&gt;
url=http://gsd.di.uminho.pt/members/cbm/ps/itc2008.pdf |&lt;br /&gt;
pages=259–274 |&lt;br /&gt;
series=Lecture Notes in Computer Science | bibcode=2008LNCS.5401.....B |&lt;br /&gt;
editor1-last=Baker |&lt;br /&gt;
editor1-first=Theodore P. |&lt;br /&gt;
editor2-last=Bui |&lt;br /&gt;
editor2-first=Alain |&lt;br /&gt;
editor3-last=Tixeuil |&lt;br /&gt;
editor3-first=Sébastien |&lt;br /&gt;
isbn=978-3-540-92220-9 }}&amp;lt;/ref&amp;gt;&amp;lt;ref&amp;gt;{{Citation | last1=Almeida | first1=Paulo | last2=Baquero | first2=Carlos | last3=Fonte | first3=Victor | title=Interval Tree Clocks: A Logical Clock for Dynamic Systems | volume=5401 | pages=259 | contribution=Interval Tree Clocks: A Logical Clock for Dynamic Systems | year=2008 | doi=10.1007/978-3-540-92221-6_18 | url=https://www.researchgate.net/publication/235246938 | series=Lecture Notes in Computer Science | isbn=978-3-540-92220-9 | hdl=1822/37748 | hdl-access=free }}&amp;lt;/ref&amp;gt;&amp;lt;ref&amp;gt;{{Citation | last1=Zhang | first1=Yi | title=Background Preliminaries: Interval Tree Clock Results | contribution=Background Preliminaries: Interval Tree Clock Results | year=2014 | url=https://cs.uwaterloo.ca/~mkarsten/cs755-F14/presentations/ITC.pdf }}&amp;lt;/ref&amp;gt; This mechanism generalizes Vector Clocks and allows operation in dynamic environments when the identities and number of processes in the computation is not known in advance.&lt;br /&gt;
&lt;br /&gt;
* In 2019, Lum Ramabaja proposed &#039;&#039;&#039;Bloom Clocks&#039;&#039;&#039;, a probabilistic data structure based on [[Bloom filters]].&amp;lt;ref&amp;gt;{{cite journal |last1=Pozzetti |first1=Tommaso |last2=Kshemkalyani |first2=Ajay D. |title=Resettable Encoded Vector Clock for Causality Analysis With an Application to Dynamic Race Detection |journal=IEEE Transactions on Parallel and Distributed Systems |date=1 April 2021 |volume=32 |issue=4 |pages=772–785 |doi=10.1109/TPDS.2020.3032293|s2cid=220362525 |doi-access=free }}&amp;lt;/ref&amp;gt;&amp;lt;ref&amp;gt;{{Citation |author1=Lum Ramabaja |title=The Bloom Clock |year=2019 |arxiv=1905.13064 |bibcode=2019arXiv190513064R }}&amp;lt;/ref&amp;gt;&amp;lt;ref&amp;gt;{{cite book |last1=Kulkarni |first1=Sandeep S |last2=Appleton |first2=Gabe |last3=Nguyen |first3=Duong |title=Proceedings of the 23rd International Conference on Distributed Computing and Networking |chapter=Achieving Causality with Physical Clocks |date=4 January 2022 |pages=97–106 |doi=10.1145/3491003.3491009|arxiv=2104.15099 |isbn=9781450395601 |s2cid=233476293 }}&amp;lt;/ref&amp;gt; Compared to a vector clock, the space used per node is fixed and does not depend on the number of nodes in a system. Comparing two clocks either produces a true negative (the clocks are not comparable), or else a suggestion that one clock precedes the other, with the possibility of a false positive where the two clocks are unrelated. The false positive rate decreases as more storage is allowed.&lt;br /&gt;
&lt;br /&gt;
==See also==&lt;br /&gt;
*[[Lamport timestamps]]&lt;br /&gt;
*[[Matrix clock]]s&lt;br /&gt;
*[[Version vector]]&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
{{Reflist|30em}}&lt;br /&gt;
&lt;br /&gt;
== External links ==&lt;br /&gt;
* [http://queue.acm.org/detail.cfm?id=2917756 Why Logical Clocks are Easy (Compares Causal Histories, Vector Clocks and Version Vectors)]&lt;br /&gt;
* [http://basho.com/why-vector-clocks-are-easy/ Explanation of Vector clocks]&lt;br /&gt;
* [https://github.com/cliffmoon/dynomite/blob/master/elibs/vector_clock.erl Timestamp-based vector clock implementation in Erlang]&lt;br /&gt;
* [https://github.com/jeremytregunna/JVectorClock Vector clock implementation in Objective-C]&lt;br /&gt;
* [https://github.com/basho/riak_core/blob/master/src/vclock.erl Vector clock implementation in Erlang]&lt;br /&gt;
* [http://basho.com/why-vector-clocks-are-hard/ Why Vector Clocks are Hard]&lt;br /&gt;
* [http://www.datastax.com/dev/blog/why-cassandra-doesnt-need-vector-clocks Why Cassandra doesn’t need vector clocks]&lt;br /&gt;
&lt;br /&gt;
{{DEFAULTSORT:Vector Clock}}&lt;br /&gt;
[[Category:Logical clock algorithms]]&lt;/div&gt;</summary>
		<author><name>103.53.232.35</name></author>
	</entry>
</feed>