Treffer: Communicating sequential processes in distributed JavaScript environments

Title:
Communicating sequential processes in distributed JavaScript environments
Authors:
Publisher Information:
University of Malta
Faculty of Information & Communication Technology. Department of Computer Science
Publication Year:
2016
Collection:
University of Malta: OAR@UM / L-Università ta' Malta
Document Type:
Dissertation bachelor thesis
Language:
English
Rights:
info:eu-repo/semantics/restrictedAccess ; The copyright of this work belongs to the author(s)/publisher. The rights of this work are as defined by the appropriate Copyright Legislation or as modified by any successive legislation. Users may access this work and can make use of the information contained in accordance with the Copyright Legislation provided that the author must be properly acknowledged. Further distribution or reproduction in any format is prohibited without the prior permission of the copyright holder.
Accession Number:
edsbas.CEBA63D
Database:
BASE

Weitere Informationen

B.SC.(HONS)COMP.SCI. ; By design, JavaScript is a single-threaded language, as its event-loop processes messages on its runtime queue. Since each queued message is run to completion, the opportunities for concurrency in JavaScript are limited when compared to other general purpose languages. With the inclusion of generators into the language, JavaScript offers the expressiveness to dynamically execute functions. Their design facilitate generators to be used as cooperatively multitasked processes or threads. On top of that, a library is built as part of this project, to express core functionality described by Communicating Sequential Processes. Generators are a fundamental component of this implementation, as they represent the processes, which communicate through channels. Although JavaScript is typically assimilated within browsers, it is present in a myriad of environments ranging from workers to remote servers. Consequently, the implementation is then extended to express concurrency on these environments. By using various external channel implementations, the underlying transport mechanism is abstracted. Seamless extensions of further external channels are facilitated by establishing an external communication protocol. Hence, a safe and intuitive pattern for parallelism is achieved, offering both syntactic and performance benefits. A scalable implementation is achieved albeit having some shortcomings due to the dynamic nature of the language. Moreover, the need for asynchronous callbacks is eliminated by adopting synchronous and sequential code through the presented framework. The concurrency pattern derived from this implementation eliminates the need to tailor code to the respective JavaScript environment. Generators become agnostic of the environment they operate in and the communication mechanisms being used. ; N/A