From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from resqmta-ch2-04v.sys.comcast.net (resqmta-ch2-04v.sys.comcast.net [IPv6:2001:558:fe21:29:69:252:207:36]) by hurricane.the-brannons.com (Postfix) with ESMTPS id BE573791EB for ; Wed, 30 Dec 2015 05:40:53 -0800 (PST) Received: from resomta-ch2-16v.sys.comcast.net ([69.252.207.112]) by resqmta-ch2-04v.sys.comcast.net with comcast id zph01r0042S2Q5R01phKq3; Wed, 30 Dec 2015 13:41:19 +0000 Received: from eklhad ([IPv6:2601:405:4001:e487:21e:4fff:fec2:a0f1]) by resomta-ch2-16v.sys.comcast.net with comcast id zphK1r0052MDcd701phK7Z; Wed, 30 Dec 2015 13:41:19 +0000 To: Edbrowse-dev@lists.the-brannons.com From: Karl Dahlke Reply-to: Karl Dahlke References: <20151229191702.GB1766@122oven.adamthompson.me.uk> <20151230132253.GB2471@122oven.adamthompson.me.uk> User-Agent: edbrowse/3.6.0+ Date: Wed, 30 Dec 2015 08:41:19 -0500 Message-ID: <20151130084119.eklhad@comcast.net> Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=q20140121; t=1451482879; bh=FnerojJWR0JEFY2F1aKz16UWAE1qcn09OfCmCKrtSws=; h=Received:Received:To:From:Reply-to:Subject:Date:Message-ID: Mime-Version:Content-Type; b=Z0m3WBDSyuvwpUB32d84CeiRdcSPmyhBhiQOHQ4dR/5Z1pD5vzutUWLrNslgnYANb Ac2Jrlg5ROUmiFpUXOGWE0S6JoW6fZ9kCouOG3tajDmATIrYKSIs6Q8K23lzue4LyV mX7xCWBi7zmy6NUqP5u6q71YwgeopnJyNdymffdJXjLn0c9bMby9/0kS4+Bko5AlzT Q4LlqlOSqMCdvGQRAkT9vRkaKNM1S4BC8z1GgMqm6xYLAinOkKvLAs/1QTUCi609qc TfDJekFfl8VGJrCgc0uCw9Y1Wuyn3SIrStp3iKpv++MO9C3lgoVyAcdpDy7lT2uZHY hFq0+Z2cbsarQ== Subject: [Edbrowse-dev] curl handles and general comms design X-BeenThere: edbrowse-dev@lists.the-brannons.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Edbrowse Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 30 Dec 2015 13:40:54 -0000 > I'm wondering if we actually need the exec at all or if we can fork and then > set the flag and whether that'll do. This just doesn't work well in windows. You kind of need the separate process so you can use spawn. See how Geoff has set up the invocation of edbrowse-js. I know when I worked on the separation of js, the messages were the most important part, the code just sort of fell out after that. So I'll send along some high level thoughts on curl requests and responses. Yes, a more generic messaging system, a layer above sockets, might be nice, and I almost did that with js. I sort of had to for my own sanity. The message header includes a length for an error string, and then the error string, if there is one, (length nonzero), then the length for the js side effects, and the side effects, if there are any, and finally the js item requested or the acknowledgement of the action. Now I have some general parsing of every message. I can glom onto the js error, if any, as part of the message envelope, and the same for js side effects. A higher level structure like this might be what you're looking for, and it doesn't take a lot of coding to seee that you need it. Karl Dahlke