Free the Bugs: Disclosing Blocking Violations in Reactive Programming
Autor: | Felix Dobslaw, Robin Sundstrom, Morgan Vallin |
---|---|
Rok vydání: | 2020 |
Předmět: |
Java
Computer science Distributed computing Concurrency 020207 software engineering 02 engineering and technology Blocking (computing) Java compiler Asynchronous communication 020204 information systems 0202 electrical engineering electronic engineering information engineering Reactive programming Fork (file system) computer computer.programming_language Abstraction (linguistics) |
Zdroj: | SCAM |
DOI: | 10.1109/scam51674.2020.00025 |
Popis: | In programming, concurrency allows threads to share processing units interleaving and seemingly simultaneous to improve resource utilization and performance. Previous research has found that concurrency faults are hard to avoid, hard to find, often leading to undesired and unpredictable behavior. Further, with the growing availability of multi-core devices and adaptation of concurrency features in high-level languages, concurrency faults occur reportedly often, which is why countermeasures must be investigated to limit harm. Reactive programming provides an abstraction to simplify complex concurrent and asynchronous tasks through reactive language extensions such as the RxJava and Project Reactor libraries for Java. Still, blocking violations are possibly resulting in concurrency faults with no Java compiler warnings. BlockHound is a tool that detects incorrect blocking by wrapping the original code and intercepting blocking calls to provide appropriate runtime errors. In this study, we seek an understanding of how common blocking violations are and whether a tool such as BlockHound can give us insight into the root-causes to highlight them as pitfalls to developers. The investigated Softwares are Java-based open-source projects using reactive frameworks selected based on high star ratings and large fork quantities that indicate high adoption. We activated BlockHound in the project’s test-suites and analyzed log files for common patterns to reveal blocking violations in 7/29 investigated open-source projects with 5024 stars and 1437 forks. A small number of system calls could be identified as root-causes. We here present countermeasures that successfully removed the uncertainty of blocking violations. The code’s intentional logic was retained in all validated projects through passing unit-tests. |
Databáze: | OpenAIRE |
Externí odkaz: |