Skip to content

Commit

Permalink
Throw an error when using Tarantool 3 (#2130)
Browse files Browse the repository at this point in the history
  • Loading branch information
yngvar-antonsson authored Aug 2, 2023
1 parent b5ee503 commit e70b7ba
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ Changed

- Don't perform invalid format check in Tarantool 2.10.4 and above.

- Throw an error when using Tarantool 3.

-------------------------------------------------------------------------------
[2.8.1] - 2023-07-20
-------------------------------------------------------------------------------
Expand Down
5 changes: 5 additions & 0 deletions cartridge.lua
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ local http = require('http.server')
local fiber = require('fiber')
local socket = require('socket')
local json = require('json')
local tarantool_version = require('tarantool').version

local rpc = require('cartridge.rpc')
local auth = require('cartridge.auth')
Expand Down Expand Up @@ -317,6 +318,10 @@ local function cfg(opts, box_opts)
disable_errstack = '?boolean',
}, '?table')

if tarantool_version:sub(1, 2) == '3.' then
return nil, CartridgeCfgError:new("Unsupported Tarantool version " .. tarantool_version)
end

if opts.enable_sychro_mode ~= nil then
opts.enable_synchro_mode = opts.enable_sychro_mode
log.warn('enable_sychro_mode is deprecated. Use enable_synchro_mode instead')
Expand Down

0 comments on commit e70b7ba

Please sign in to comment.