pinterest / PINOperation

Apache License 2.0
103 stars 49 forks source link

Support serial queue #2

Closed garrettmoon closed 7 years ago

garrettmoon commented 7 years ago

As I originally wrote PINOperationQueue, I couldn't think of a good reason to use it over a standard serial queue when you only want a max operation. Turns out there is a good reason, support for coalescing operations and canceling them. Support for priority seems dangerous: if a high priority task depended on a lower priority task it could cause a deadlock, so I would shy away from supporting priority.

maicki commented 7 years ago

@garrettmoon You think the PR from above is enough to close the issue?

garrettmoon commented 7 years ago

Yup.