Tarantool development patches archive
 help / color / mirror / Atom feed
From: Vladislav Shpilevoy <v.shpilevoy@tarantool.org>
To: tarantool-patches@freelists.org
Cc: vdavydov.dev@gmail.com, Vladislav Shpilevoy <v.shpilevoy@tarantool.org>
Subject: [PATCH 3/3] netbox: deprecate console support
Date: Thu, 22 Mar 2018 22:17:12 +0300	[thread overview]
Message-ID: <95b811a3aa73edc02c58dcd6fb475155498457d5.1521745741.git.v.shpilevoy@tarantool.org> (raw)
In-Reply-To: <cover.1521745741.git.v.shpilevoy@tarantool.org>
In-Reply-To: <cover.1521745741.git.v.shpilevoy@tarantool.org>

Print warning about that. After a while the cosole support will
be deleted from netbox.
---
 src/box/lua/net_box.lua | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/src/box/lua/net_box.lua b/src/box/lua/net_box.lua
index f3f69f52f..cf1a04237 100644
--- a/src/box/lua/net_box.lua
+++ b/src/box/lua/net_box.lua
@@ -396,7 +396,10 @@ local function create_transport(host, port, user, password, callback,
         if err then
             return error_sm(err, msg)
         end
+        -- @deprecated since 1.10
         if greeting.protocol == 'Lua console' then
+            log.warn("Netbox text protocol support is deprecated since 1.10, "..
+                     "please use require('console').connect() instead")
             local setup_delimiter = 'require("console").delimiter("$EOF$")\n'
             method_codec.inject(send_buf, nil, nil, setup_delimiter)
             local err, response = send_and_recv_console()
@@ -673,7 +676,10 @@ local function do_connect(host, port, opts, existing_connection, greeting)
             end
         end
     end
+    -- @deprecated since 1.10
     if opts.console then
+        log.warn("Netbox console API is deprecated since 1.10, please use "..
+                 "require('console').connect() instead")
         setmetatable(remote, console_mt)
     else
         setmetatable(remote, remote_mt)
-- 
2.14.3 (Apple Git-98)

  parent reply	other threads:[~2018-03-22 19:17 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-22 19:17 [PATCH 0/3] console: do not use netbox for console text connections Vladislav Shpilevoy
2018-03-22 19:17 ` [PATCH 1/3] netbox: allow to create a netbox connection from existing socket Vladislav Shpilevoy
2018-03-22 19:33   ` [tarantool-patches] " Konstantin Osipov
2018-03-22 19:50     ` v.shpilevoy
2018-03-22 19:57       ` [tarantool-patches] " v.shpilevoy
2018-03-23 10:01         ` [tarantool-patches] " v.shpilevoy
2018-03-26 21:55       ` Konstantin Osipov
2018-03-22 19:17 ` [PATCH 2/3] console: do not use netbox for console text connections Vladislav Shpilevoy
2018-03-22 19:36   ` [tarantool-patches] " Konstantin Osipov
2018-03-22 19:17 ` Vladislav Shpilevoy [this message]
2018-03-22 19:37   ` [tarantool-patches] [PATCH 3/3] netbox: deprecate console support Konstantin Osipov

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=95b811a3aa73edc02c58dcd6fb475155498457d5.1521745741.git.v.shpilevoy@tarantool.org \
    --to=v.shpilevoy@tarantool.org \
    --cc=tarantool-patches@freelists.org \
    --cc=vdavydov.dev@gmail.com \
    --subject='Re: [PATCH 3/3] netbox: deprecate console support' \
    /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