Skip to Main content Skip to Navigation
Conference papers

Weak Fairness Semantic Drawbacks in Java Multithreading

Abstract : With the development of embedded and mobile systems, Java is widely used for application programs and is also considered for implementing systems kernel or application platforms. It is the aim of this paper to exemplify some subtle programming errors that may result from the process queuing and awaking policy, which corresponds to a weak fairness semantic and which has been chosen for implementing the monitor concept in this language. Two examples show some subtle deadlocks resulting from this policy. The first example deals with process synchronization: processes seeking after partners for a peer-to-peer communication call a symmetrical rendezvous server. The second example concerns resource sharing according to a solution of the dining philosophers paradigm. In this example, several implementations are presented, the last ones aiming to provide deterministic process awakening. All these examples have been validated and simulated and this allows comparing their concurrency complexity and effectiveness. Our conclusion is, first, that the use of Java for multithreading programming necessitates sometimes additional shielding code for developing correct programs and, second, that a good acquaintance with several styles of concurrent programming helps designing more robust Java solutions, once the choice of the implementation language is irrevocable.
Complete list of metadata

https://hal.archives-ouvertes.fr/hal-03401976
Contributor : Jean-François Pradat-Peyre Connect in order to contact the contributor
Submitted on : Monday, October 25, 2021 - 2:57:47 PM
Last modification on : Tuesday, November 16, 2021 - 5:08:59 AM

File

Weak_Fairness_Semantic_Drawbac...
Files produced by the author(s)

Identifiers

Citation

Claude Kaiser, Jean-François Pradat-Peyre. Weak Fairness Semantic Drawbacks in Java Multithreading. 14th International Conference on Reliable Software Technologies, Jun 2009, Brest, France. pp.90-104, ⟨10.1007/978-3-642-01924-1_7⟩. ⟨hal-03401976⟩

Share

Metrics

Record views

15

Files downloads

6