Tarantool development patches archive
 help / color / mirror / Atom feed
* [tarantool-patches] [PATCH v2 0/5] box/console: Improve lua mode for remote console
@ 2019-08-30 21:48 Cyrill Gorcunov
  2019-08-30 21:48 ` [tarantool-patches] [PATCH 1/5] box/console: Add mapping for direct symbols Cyrill Gorcunov
                   ` (4 more replies)
  0 siblings, 5 replies; 13+ messages in thread
From: Cyrill Gorcunov @ 2019-08-30 21:48 UTC (permalink / raw)
  To: tml; +Cc: Alexander Turenko, Konstantin Osipov, Kirill Yukhin, Cyrill Gorcunov

This series address a problem where we can hang a connection setting up
lua mode while server continue treating all data as having built-in yaml
end of string terminator.

We've a long discussion with @alexander.turenko about our test engine
and console eos in general and at first concluded that by default we
should not use ";" as lua terminator but continue using empty string
instead. Actually after thinking more I fear it won't work -- a user
might connect to remote console and this connection will hang because
server will reply with empty eos while we're using read() from socket
with terminator at the end of string. Moreover since our yaml serializer
*always* yield eos terminator I think we should do the same for lua
mode just to be consistent in architecture.

Still for convenience I added ability to zap lua terminator via
require('console').eos("") command. Thus users on local consoles
can drop ';' eos if they want to.

Next to test engine:

1) I think we should convert each test one by one, not the
   whole bunch of tests in a single pass

2) For this sake we need to send something like "\set output lua"
   to the server for a particular test

3) We need to describe somehow which mode a test uses. Sasha pointed
   that he has a string on top of "result" file where we could provide
   some kind of settings describing output mode. But I think maybe we
   could introduce .desc files in json format where we could add per-file
   settings instead (in addition to ini files). Putting test description
   in "result" file looks a bit inconvenient for me. Guys, what do you think?

Regardless of the test engine issues which I have to address I think the
series should be merged since it closes real bugs.

---

The following changes since commit 51d8e4c35ca1da255b4ebea9850ec2a84365e0a3:

  box/memtx: strip_core -- Warn on linux only (2019-08-29 22:27:15 +0300)

are available in the Git repository at:

  https://github.com/cyrillos/tarantool.git console-fix-1

for you to fetch changes up to 9236f677fcf1bde39f9eb004693865c40b449abc:

  box/console: Provide console.eos() api (2019-08-30 23:46:32 +0300)

----------------------------------------------------------------
Cyrill Gorcunov (5):
      box/console: Add mapping for direct symbols
      box/console: Add explicit output EOS mapping
      box/console: Refactor command handling
      box/console: Fix hang in remote console lua mode
      box/console: Provide console.eos() api

 src/box/lua/console.lua | 129 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++------------
 1 file changed, 116 insertions(+), 13 deletions(-)

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2019-09-04 14:53 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-30 21:48 [tarantool-patches] [PATCH v2 0/5] box/console: Improve lua mode for remote console Cyrill Gorcunov
2019-08-30 21:48 ` [tarantool-patches] [PATCH 1/5] box/console: Add mapping for direct symbols Cyrill Gorcunov
     [not found]   ` <20190903082351.GB9438@atlas>
2019-09-03  8:26     ` [tarantool-patches] " Cyrill Gorcunov
     [not found]   ` <20190903082446.GC9438@atlas>
2019-09-03  8:28     ` Cyrill Gorcunov
2019-08-30 21:48 ` [tarantool-patches] [PATCH 2/5] box/console: Add explicit output EOS mapping Cyrill Gorcunov
     [not found]   ` <20190903082725.GD9438@atlas>
2019-09-03  8:32     ` [tarantool-patches] " Cyrill Gorcunov
2019-08-30 21:48 ` [tarantool-patches] [PATCH 3/5] box/console: Refactor command handling Cyrill Gorcunov
2019-08-30 21:48 ` [tarantool-patches] [PATCH 4/5] box/console: Fix hang in remote console lua mode Cyrill Gorcunov
     [not found]   ` <20190903190002.GC15611@atlas>
2019-09-03 19:18     ` [tarantool-patches] " Cyrill Gorcunov
     [not found]       ` <20190904064657.GD30636@atlas>
2019-09-04  7:12         ` Cyrill Gorcunov
2019-08-30 21:48 ` [tarantool-patches] [PATCH 5/5] box/console: Provide console.eos() api Cyrill Gorcunov
     [not found]   ` <20190903190057.GD15611@atlas>
2019-09-03 19:19     ` [tarantool-patches] " Cyrill Gorcunov
     [not found]       ` <20190904064725.GE30636@atlas>
2019-09-04  7:12         ` Cyrill Gorcunov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox