Ruby API is Improved Unix API
Tanaka Akira (National Institute of Advanced Industrial Science and Technology (AIST))
Ruby's library API is like Unix's API, but improved. Ruby tries to fix some of the problems in Unix's API. For example, non-blocking IO in Unix is provided by setting a flag when opening a file, making it difficult to specify non-blocking behavior for individual operations. Ruby overcomes this problem by providing non-blocking methods such as #read_nonblock.
Another example is the fork() system call, which has problems in multi-threaded environments. Ruby provides the #spawn method as an alternative way to launch processes safely.
This presentation will discuss techniques for API problem discovery with more examples of Ruby's improvements over Unix's API and other problematic parts of Unix which Ruby may improve in the future.
2010-08-28 15:30 - 16:30
Main Convention Hall
A Ruby committer.
Main interests are I/O, socket, process, time and other difficulties.