From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by sympa.inria.fr (Postfix) with ESMTPS id 74D037FFB2 for ; Fri, 11 Mar 2016 18:49:34 +0100 (CET) IronPort-PHdr: 9a23:3VrnwhMFrYsLtHeKEool6mtUPXoX/o7sNwtQ0KIMzox0KPT4rarrMEGX3/hxlliBBdydsKIbzbqH+Pm4ASQp2tWojjMrSNR0TRgLiMEbzUQLIfWuLgnFFsPsdDEwB89YVVVorDmROElRH9viNRWJ+iXhpQAbFhi3DwdpPOO9QteU1JTokbDjsMSLO01hv3mUX/BbFF2OtwLft80b08NJC50a7V/3mEZOYPlc3mhyJFiezF7W78a0+4N/oWwL46pyv+YJa6jxfrw5QLpEF3xmdjltvIy4/SXEGCWV732TVWQNpTBPCQ/ZpEX0RJ73uSz7rax33yOdIeX9QLlyVy70vIlxTxq9uS4dMDhx1WDRkc9hxPZKpROnvB9u64zdZoyOKOBzc7+bdtQfEzkSFv1NXjBMV9vvJ7AECPAMaKMB99Hw Authentication-Results: mail2-smtp-roc.national.inria.fr; spf=None smtp.pra=yminsky@janestreet.com; spf=Pass smtp.mailfrom=yminsky@janestreet.com; spf=None smtp.helo=postmaster@mxout1.mail.janestreet.com Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of yminsky@janestreet.com) identity=pra; client-ip=38.105.200.112; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="yminsky@janestreet.com"; x-sender="yminsky@janestreet.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail2-smtp-roc.national.inria.fr: domain of yminsky@janestreet.com designates 38.105.200.112 as permitted sender) identity=mailfrom; client-ip=38.105.200.112; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="yminsky@janestreet.com"; x-sender="yminsky@janestreet.com"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of postmaster@mxout1.mail.janestreet.com) identity=helo; client-ip=38.105.200.112; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="yminsky@janestreet.com"; x-sender="postmaster@mxout1.mail.janestreet.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A0BQAABXBONWjnDIaSZdhH0GuiQBDYFthg0CgSoHOBQBAQEBAQEBARABAQEBBxYJUIItghUBAQQSER0BATcBDwsLDQICJgICIhIBBQEcBhMiiAIDoF6BMT4xik9nhEEBBIpbAQEBAQEBAQMBAQEBAQEBEwYKcoUchEKEIhaDAoE6ji+JGY18jwKNMxEegQ8eAQGCOA0RCIFmTIpRAQEB X-IPAS-Result: A0BQAABXBONWjnDIaSZdhH0GuiQBDYFthg0CgSoHOBQBAQEBAQEBARABAQEBBxYJUIItghUBAQQSER0BATcBDwsLDQICJgICIhIBBQEcBhMiiAIDoF6BMT4xik9nhEEBBIpbAQEBAQEBAQMBAQEBAQEBEwYKcoUchEKEIhaDAoE6ji+JGY18jwKNMxEegQ8eAQGCOA0RCIFmTIpRAQEB X-IronPort-AV: E=Sophos;i="5.24,321,1454972400"; d="scan'208";a="207276887" Received: from mxout1.mail.janestreet.com ([38.105.200.112]) by mail2-smtp-roc.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 11 Mar 2016 18:49:32 +0100 Received: from tot-qpr-mailcore1.delacy.com ([172.27.56.68] helo=tot-qpr-mailcore1) by mxout1.mail.janestreet.com with esmtps (TLSv1:DHE-RSA-AES256-SHA:256) (Exim 4.82) (envelope-from ) id 1aeRBr-0001mx-8b for caml-list@inria.fr; Fri, 11 Mar 2016 12:49:31 -0500 X-JS-Flow: external Received: by tot-qpr-mailcore1 with JS-mailcore (0.1) (envelope-from ) id BW4wUr-AAABz2-GP; 2016-03-11 12:49:31.200868-05:00 Received: from mail-yk0-f177.google.com ([209.85.160.177]) by mxgoog1.mail.janestreet.com with esmtps (UNKNOWN:AES128-GCM-SHA256:128) (Exim 4.72) (envelope-from ) id 1aeRBr-0002Bu-4O for caml-list@inria.fr; Fri, 11 Mar 2016 12:49:31 -0500 Received: by mail-yk0-f177.google.com with SMTP id r203so46725227ykd.3 for ; Fri, 11 Mar 2016 09:49:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=janestreet.com; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=TafdPLdzIWBRCbhr5ultdhN1sVZmdlGU8+PWT7+/lgw=; b=MhOMH5RxOUij+MObRcw3Kxh1skdrcKuQFrkTAaR+lWMlicg06TU90tm3BJAohDraxX w8F/xKg+cRtg3+vc4VrYXzYPh5KCfDD79kW6kWMskRca1oHi+l1Iv1B93sJhoHSP7wJ3 wwVy+FnDDJM/UwjeYIrCmwjwIDqKVqpTj4zMk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=TafdPLdzIWBRCbhr5ultdhN1sVZmdlGU8+PWT7+/lgw=; b=Csd/6brEEwJWYTaowrLAf9T2vgRdShIYGCb+dBfv+jzXIcWvVYD9lbO27cmJ23l5sl yCI8oZaDXQhKEp9MNS0D3MY83JeHpsLrwSGXVdsXs6YLYvYs9KzYXVUjvfRHz41rfP21 rUGdz3tFi2t//+8T9n9Q/rx4tia8zf7Kyu8WRnbG+4ni6tvVhfGZALAYNjEXtBAEuMns zWlhnaG5L5mmby2msQGKhcTWbiTv0iOMTlFO4LHZgWyB02ibY2Ir8yenqqRz5UqyLmA3 ksPdQuoVVuVs3p7xWX97zapE1zJAswTf1qmWpN5uZpXGoX2EinwJV+wqsp7tywXkYHIJ MTxw== X-Gm-Message-State: AD7BkJJNx3kjsWK7Uca6Ini2gQOb8BaYaB073nzJMXBX3iy2xp04Yi0tIsoDKMp4Nb+xmlfRSKiAw2N+UTt64a2Ar2vUwMqDO9HXsPHo9UyFMZG0w4OsqiafoDhautUT43Ng/kDAYPkwk6RcAy+H X-Received: by 10.37.37.151 with SMTP id l145mr6142167ybl.65.1457718570845; Fri, 11 Mar 2016 09:49:30 -0800 (PST) X-Received: by 10.37.37.151 with SMTP id l145mr6142161ybl.65.1457718570742; Fri, 11 Mar 2016 09:49:30 -0800 (PST) MIME-Version: 1.0 Received: by 10.13.226.65 with HTTP; Fri, 11 Mar 2016 09:49:11 -0800 (PST) In-Reply-To: <56E2EF38.10603@cea.fr> References: <56E2C676.3010702@cea.fr> <56E2EF38.10603@cea.fr> From:Yaron Minsky Date: Fri, 11 Mar 2016 12:49:11 -0500 Message-ID: To:=?UTF-8?Q?Fran=C3=A7ois_Bobot?= Cc:"caml-list@inria.fr" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-JS-Processed-by: mailcore Subject: Re: [Caml-list] Question about Lwt/Async Well, Async_rpc_kernel is tied to the Deferred type, so it's not so general as to abstract over which IO monad is being used. So I'm afraid it doesn't give you a nice way of interoperating with Async programs. That said, we're hopefully going to do a rewrite of the protocol in the next few months. It's not crazy that we could try to make some of the low level protocol work shareable, at least. y On Fri, Mar 11, 2016 at 11:15 AM, Fran=C3=A7ois Bobot wrote: > On 11/03/2016 16:22, Yaron Minsky wrote: >> >> Not easily at present, I think. Obviously. if you run two runtimes in >> two threads, you can do it, but it's ugly. If you had >> lwt-on-async-runtime available, as was discussed in the thread, then >> you could do it, but you'd need some extra overhead to create matching >> pairs of Lwt.t's and Deferred.t's, since those two types would not be >> equal. >> > > Sorry I don't know if have been clear that I was thinking to make two oca= ml > process communicate together one using Async and the other Lwt. The use c= ase > for example, is to write a job server with Async and to make a web interf= ace > for it using ocsigen (Lwt); so the webserver (Lwt) would connect to the j= ob > server (Async) using the rpc protocol defined by Async_rpc_kernel. > > >> So, with some overhead, yeah, I think you could do it. > > > Does you answer is applicable to this use case? > > Thank you already for this answer. > > Best, > > -- > Fran=C3=A7ois