<@U0B8ZP13Q> I ended up with this in the end (w/ c...
# klaxon
d
@cedric I ended up with this in the end (w/ coroutines v. 0.22.1 that just came out, runBlocking runs on another thread, which hopefully avoids blocking the Vert.x event loop...):
Copy code
val basePriceConverter = object: Converter<Double> {
		override fun fromJson(jv: JsonValue) =
				if (<http://jv.int|jv.int> != null) {
					runBlocking(CommonPool) {
						odooClient.read(
								"product.product",
								listOf(<http://jv.int|jv.int>!!),
								listOf("lst_price")
						)!!.get(0).get("lst_price") as Double
					}
				} else {
					throw KlaxonException("Couldn't parse product id: ${jv.string}")
				}

		override fun toJson(o: Double)
				= """ { "basePrice" : $o } """
	}

	val parser = Klaxon().fieldConverter(BasePrice::class, basePriceConverter)
and it works! Thanks for all your help 😄