From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-x244.google.com (mail-wr0-x244.google.com [IPv6:2a00:1450:400c:c0c::244]) by hurricane.the-brannons.com (Postfix) with ESMTPS id 9CF8B78020 for ; Mon, 24 Jul 2017 10:57:39 -0700 (PDT) Received: by mail-wr0-x244.google.com with SMTP id g32so773564wrd.5 for ; Mon, 24 Jul 2017 10:57:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=lgX0Iin+I9evD7NuilCw5TXrHE0qKFId8ZleeWorJBE=; b=q1TwCu5nQWE/9etVghgb1uEGv9ONq8I3nQmQ0Gi+Lxa/KGChugaLQs+wX5lO/hHXbV YJV9Jqb2DrvTAoAJyo+SquCaBt2it970Rm138zsP1M6DdRVp4N8/cG62G5VYfmhGY2kU Gd5RvhV2N00yzy3WD1mhJmujGZ2VDjnyx051nbUd0lxuFnyV1Z2PY1LrB6ebtHqzxw3F nmFg5E51ONaMgBLgksLdBmHkrGfv7c5JHjZyds3Y9pmddmleLLz8fLa2+jaLuVnooRZA IWCKGvyfk6DGv+b2/NxR9tJsvogTeGcFn/HFq4Ab0Hv1SDOlVLCYjjs+EOzZJ3YJG/FJ 8OcA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=lgX0Iin+I9evD7NuilCw5TXrHE0qKFId8ZleeWorJBE=; b=L9DUHtJYa74yETB23nWaNBE6fyswME7KmBycUN6Ee4J3V6Mq2vnK/3La0ogFeYpCPa DHNw1B016cBUq7aS/+v7TfYB1j6gR4YKWfFCjNfd47gRl0/lt0A4O8pKCiQz4yBRnjGd BKdCvjG/uyQf28odt8VApUkQlqX2jrvSPG59SiMowiz1g+7rjB184DvhdsllrvmNZ194 g3M2P4l3oOFhmxnocMCY3g8SwK1RsA3A+a/TCVHEIgHgBgWRdZZqTn6jluDbcxdh5MhO 1lUJF6JQ11+P5HfS3PtaBH2sOlgE8TmEBlrhYyywbJXSQibp1hgh77dMJOXU1rkM4QSs YBGA== X-Gm-Message-State: AIVw113gIZqhBX2b5co17EdTZLgis6QjRlefCoaMAURg0rLmbb1jAX/9 8epQTw+gDoVoX3Ho X-Received: by 10.223.133.97 with SMTP id 88mr2466096wrh.30.1500919073388; Mon, 24 Jul 2017 10:57:53 -0700 (PDT) Received: from odin (odin.sdf-eu.org. [178.63.35.194]) by smtp.gmail.com with ESMTPSA id b80sm8197643wmf.10.2017.07.24.10.57.52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 24 Jul 2017 10:57:52 -0700 (PDT) Date: Mon, 24 Jul 2017 17:57:51 +0000 From: Adam Thompson To: Karl Dahlke Cc: Edbrowse-dev@lists.the-brannons.com Message-ID: <20170724175751.GC20415@odin> References: <20170622224940.eklhad@comcast.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170622224940.eklhad@comcast.net> User-Agent: Mutt/1.5.23 (2014-03-12) Subject: Re: [Edbrowse-dev] JS1 X-BeenThere: edbrowse-dev@lists.the-brannons.com X-Mailman-Version: 2.1.24 Precedence: list List-Id: Edbrowse Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 24 Jul 2017 17:57:40 -0000 On Sat, Jul 22, 2017 at 10:49:40PM -0400, Karl Dahlke wrote: > This is either for fun, or for testing, or for the future. I'm not sure. > > export JS1=on Ok, so how're we going to do all the async js stuff we'll have to start doing properly soon? Tbh I'm not sure how much I'm attached to the multiple process idea other than it means js can go pop and we don't... but we *need* to sort out async js soon. Unfortunately websites are becoming increasingly reliant on ajax being genuinely async and that's before we get to websockets etc. With 2 processes it means that we can start with a simple interface with pipes and select as now. With 1 we'll need to do thread-safe programming to make this fly properly. It's not impossible but we'll have to make a bunch of changes to make the existing code properly thread-safe to make that work, or have some way to run duktape in a mode where it only does a certain amount of instructions and use select/poll/some event loop to allow io, comms and js to work together... Honestly I'm not sure what the right design is yet. I've been, unfortunately, rather busy and unable to do much on edbrowse recently so I'm still catching up with things. That being said, this variable, plus the fact that we've made the switch to duktape (well done for that, sorry I ran out of time to help) gives us a mechanism to may be play with some sort of different model for running js. Cheers, Adam.