Open Access. Powered by Scholars. Published by Universities.®

Physical Sciences and Mathematics Commons

Open Access. Powered by Scholars. Published by Universities.®

Computer Sciences

2019

City University of New York (CUNY)

Java 8

Articles 1 - 2 of 2

Full-Text Articles in Physical Sciences and Mathematics

Safe Automated Refactoring For Intelligent Parallelization Of Java 8 Streams, Raffi T. Khatchadourian, Yiming Tang, Mehdi Bagherzadeh, Syed Ahmed Jul 2019

Safe Automated Refactoring For Intelligent Parallelization Of Java 8 Streams, Raffi T. Khatchadourian, Yiming Tang, Mehdi Bagherzadeh, Syed Ahmed

Publications and Research

Streaming APIs are becoming more pervasive in mainstream Object-Oriented programming languages and platforms. For example, the Stream API introduced in Java 8 allows for functional-like, MapReduce-style operations in processing both finite, e.g., collections, and infinite data structures. However, using this API efficiently involves subtle considerations such as determining when it is best for stream operations to run in parallel, when running operations in parallel can be less efficient, and when it is safe to run in parallel due to possible lambda expression side-effects. Also, streams may not run all operations in parallel depending on particular collectors used in reductions. In …


Safe Automated Refactoring For Intelligent Parallelization Of Java 8 Streams, Raffi T. Khatchadourian, Yiming Tang, Mehdi Bagherzadeh, Syed Ahmed May 2019

Safe Automated Refactoring For Intelligent Parallelization Of Java 8 Streams, Raffi T. Khatchadourian, Yiming Tang, Mehdi Bagherzadeh, Syed Ahmed

Publications and Research

Streaming APIs are becoming more pervasive in mainstream Object-Oriented programming languages. For example, the Stream API introduced in Java 8 allows for functional-like, MapReduce-style operations in processing both finite and infinite data structures. However, using this API efficiently involves subtle considerations like determining when it is best for stream operations to run in parallel, when running operations in parallel can be less efficient, and when it is safe to run in parallel due to possible lambda expression side-effects. In this paper, we present an automated refactoring approach that assists developers in writing efficient stream code in a semantics-preserving fashion. The …