title: Can I save to a managed object context from a completion block on an NSOperation?
body: <p>My app uses Core Data and NSOperationQueue. In keeping with Apple's guidelines, I'm creating a separate managed object context for each queue. In my case this is pretty simple: I have one background queue that does all the heavy work, and another on the main thread that just reads the data. </p>
  
  <p>It would seem to make sense for me to do something like this:</p>
  
  <ul>
  <li>On the background queue, create an operation that does a bunch of work on the managed object context. </li>
  <li>Add a completion block to that operation that saves the managed object context.</li>
  </ul>
  
  <p>But I read in the NSOperation documentation: </p>
  
  <blockquote>
    <p>The exact execution context for your completion block is not guaranteed but is typically a secondary thread. Therefore, you should not use this block to do any work that requires a very specific execution context. Instead, you should shunt that work to your application’s main thread or to the specific thread that is capable of doing it. </p>
  </blockquote>
  
  <p>Of course, it's essential that this save be carried out from the same thread that 'owns' the managed object context. But I'm not always clear on whether 'thread' refers to operation queues or not. (It's sometimes used in more or less specific ways.)</p>
  
  <p>Is my 'completion block' strategy workable?</p>