Proceedings of the 1st Workshop on All-Web Real-Time Systems 2015
DOI: 10.1145/2749215.2749216
|View full text |Cite
|
Sign up to set email alerts
|

Toward automatic update from callbacks to promises

Abstract: Javascript is the prevalent scripting language for the web. It lets web pages register callbacks to react to user events. A callback is a function to be invoked later with a result currently unavailable. This pattern also proved to respond efficiently to remote requests. Javascript is currently used to implement complete web applications. However, callbacks are ill-suited to arrange a large asynchronous execution flow.Promises are a more adapted alternative. They provide a unified control over both the synchro… Show more

Help me understand this report

Search citation statements

Order By: Relevance

Paper Sections

Select...
3
1
1

Citation Types

0
16
0

Year Published

2015
2015
2019
2019

Publication Types

Select...
5
3

Relationship

1
7

Authors

Journals

citations
Cited by 12 publications
(16 citation statements)
references
References 16 publications
(16 reference statements)
0
16
0
Order By: Relevance
“…Kambona et al [2013] report on a case study that investigates the effectiveness of promises and reactive extensions using an example of an online collaborative drawing editor. Brodu et al [2015] propose a technique to automatically refactoring legacy JavaScript code, written using event-handling and callbacks, into promise-based code. Gallaba et al [2017] present an empirical study in which they report on the prevalence of callback-accepting functions and callsites, and discuss several solutions for rewriting callbackbased code using alternative mechanisms for accommodating asynchrony, including Async.js and promises.…”
Section: Related Workmentioning
confidence: 99%
“…Kambona et al [2013] report on a case study that investigates the effectiveness of promises and reactive extensions using an example of an online collaborative drawing editor. Brodu et al [2015] propose a technique to automatically refactoring legacy JavaScript code, written using event-handling and callbacks, into promise-based code. Gallaba et al [2017] present an empirical study in which they report on the prevalence of callback-accepting functions and callsites, and discuss several solutions for rewriting callbackbased code using alternative mechanisms for accommodating asynchrony, including Async.js and promises.…”
Section: Related Workmentioning
confidence: 99%
“…The closest prior work is by Brodu et al [12] who propose a compiler for converting nested callbacks into a sequence of Dues, which is a simpler version of promises. There are several drawbacks to this approach: (1) the source code does not change, so it does not eliminate the issues with understandability, (2) Dues do not support the critical notions of rejection and resolution in promises and can therefore only re-write the error-first protocol in a simplified notation, (3) their approach requires developers to manually specify asynchronous callbacks that are suitable candidates to be converted.…”
Section: Related Workmentioning
confidence: 99%
“…This application, simplified in listing 3, is a real-time chat using gif-based communication channels. It was selected in a previous work [5] from the npm registry because it depends on express, it is tested, working, and simple enough to illustrate this evaluation. The server transforms the received text into a gif frame, and pushes it back to a never-ending gif to be displayed on the client.…”
Section: Listing 3: Simplified Version Of Gifsockets-servermentioning
confidence: 99%