Simple single threaded event loop API