title: Use cases for RxJava schedulers
body: <p>In RxJava there are <a href="http://reactivex.io/RxJava/javadoc/rx/schedulers/Schedulers.html">5 different schedulers</a> to choose from:</p>
  
  <blockquote>
    <ol>
    <li><p><strong>immediate()</strong>: Creates and returns a Scheduler that executes work immediately on the current thread.</p></li>
    <li><p><strong>trampoline()</strong>: Creates and returns a Scheduler that queues work on the current thread to be executed after the current work completes.</p></li>
    <li><p><strong>newThread()</strong>: Creates and returns a Scheduler that creates a new Thread for each unit of work.</p></li>
    <li><p><strong>computation()</strong>: Creates and returns a Scheduler intended for computational work. This can be used for event-loops, processing callbacks and other computational work. Do not perform IO-bound work on this scheduler. Use Schedulers.<strong>io()</strong> instead.</p></li>
    <li><p><strong>io()</strong>: Creates and returns a Scheduler intended for IO-bound work.
    The implementation is backed by an Executor thread-pool that will grow as needed. This can be used for asynchronously performing blocking IO. Do not perform computational work on this scheduler. Use Schedulers.<strong>computation()</strong> instead.</p></li>
    </ol>
  </blockquote>
  
  <h2>Questions:</h2>
  
  <p>The first 3 schedulers are pretty self explanatory; however, I'm a little confused about <strong>computation</strong> and <strong>io</strong>.</p>
  
  <ol>
  <li>What exactly is "IO-bound work"? Is it used for dealing with streams (<code>java.io</code>) and files (<code>java.nio.files</code>)? Is it used for database queries? Is it used for downloading files or accessing REST APIs?</li>
  <li>How is <strong>computation()</strong> different from <strong>newThread()</strong>? Is it that all <strong>computation()</strong> calls are on a single (background) thread instead of a new (background) thread each time?</li>
  <li>Why is it bad to call <strong>computation()</strong> when doing IO work?</li>
  <li>Why is it bad to call <strong>io()</strong> when doing computational work?</li>
  </ol>