convert sync pattern to async, and use ursa when possible