From: Kirill Yukhin <kyukhin@tarantool.org>
To: Alexander Turenko <alexander.turenko@tarantool.org>
Cc: tarantool-patches@dev.tarantool.org
Subject: Re: [Tarantool-patches] [PATCH 0/2] Popen Lua module
Date: Mon, 20 Apr 2020 10:52:15 +0300 [thread overview]
Message-ID: <20200420075215.jdaarxcbnimz7fe3@tarantool.org> (raw)
In-Reply-To: <cover.1587172237.git.alexander.turenko@tarantool.org>
Hello,
On 18 апр 07:13, Alexander Turenko wrote:
> The patchset implements popen Lua module upward existing backend popen
> engine.
>
> The first patch changes popen_delete() behaviour to always free
> resources even when killing a process (or a process group) fails. We
> (Alexander, Cyrill and Igor) revisited the contract for closing the
> handle after observing killpg() behaviour on a group of zombie processes
> on Mac OS. I added those details to API documentation comments to don't
> surprise a user with this.
>
> The first patch continues previous preliminary popen engine series:
>
> https://lists.tarantool.org/pipermail/tarantool-patches/2020-April/015609.html
> https://lists.tarantool.org/pipermail/tarantool-patches/2020-April/015888.html
>
> The second patch implements the Lua API for popen. It is quite
> strightforward and should be considered as very basic implementation. We
> plan to enhance it further in the upcoming releases (issues are to be
> filed).
>
> The main goal of the module it to provide popen implementation that is
> integrated into our event loop (similar to fio and socket modules). Side
> goal is to provide ability to feed data to a child process input and
> read data from its output and so work with streaming programs (like
> `grep`) and even interactive programs (like `python -i` interpreter).
>
> Let's consider the API of module as beta: it may be change in
> backward-incompatible manner in future releases if it will be valuable
> enough.
>
> It seems the main application of the module it to write various testing
> code and so the API should be extended in the future with convenient
> shortcuts: developers usually don't very like writting tests and it
> should be at least more-or-less convenient.
>
> I plan to extend the API for reading with ability to read certain amount
> of bytes, to read line-by-line (or based on other delimiter), to read
> into a buffer (ibuf): like it is implemented in the socket module. I
> plan to share an RFC document about read streams.
>
> ph:wait() should gain ability to set a timeout and should be rewritten
> to use triggers / fiber conds instead of check-yield-again loop.
>
> ----
>
> https://github.com/tarantool/tarantool/issues/4031
> https://github.com/tarantool/tarantool/tree/Totktonada/gh-4031-popen-13-full-ci
I've checked your patchset into master.
--
Regards, Kirill Yukhin
prev parent reply other threads:[~2020-04-20 7:52 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-18 4:13 Alexander Turenko
2020-04-18 4:13 ` [Tarantool-patches] [PATCH 1/2] popen: always free resources in popen_delete() Alexander Turenko
2020-04-18 6:55 ` Cyrill Gorcunov
2020-04-18 4:13 ` [Tarantool-patches] [PATCH 2/2] popen: add popen Lua module Alexander Turenko
2020-04-18 6:57 ` Cyrill Gorcunov
2020-04-19 12:38 ` Igor Munkin
2020-04-19 22:24 ` Alexander Turenko
2020-04-20 1:21 ` Igor Munkin
2020-04-20 0:57 ` Igor Munkin
2020-04-20 6:38 ` Alexander Turenko
2020-04-20 11:57 ` Igor Munkin
2020-04-21 13:38 ` Alexander Turenko
2020-04-20 7:52 ` Kirill Yukhin [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200420075215.jdaarxcbnimz7fe3@tarantool.org \
--to=kyukhin@tarantool.org \
--cc=alexander.turenko@tarantool.org \
--cc=tarantool-patches@dev.tarantool.org \
--subject='Re: [Tarantool-patches] [PATCH 0/2] Popen Lua module' \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox