aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexey Borzenkov <snaury@yandex-team.ru>2022-03-17 15:40:45 +0300
committerAlexey Borzenkov <snaury@yandex-team.ru>2022-03-17 15:40:45 +0300
commit6ee84f80952ac32766bd8d5b63431b59df6ee010 (patch)
treeaa8f7423ac385989b8c77b37f5e7ffddf583a6f9
parent9f7f925df954712a6b6682492493106c509c132f (diff)
downloadydb-6ee84f80952ac32766bd8d5b63431b59df6ee010.tar.gz
Avoid crashing in tablet resolver on follower update, KIKIMR-14514
ref:fe6b34a1fda9f6b503f13d6f5205f2c6d679d6ed
-rw-r--r--CMakeLists.darwin.txt36
-rw-r--r--CMakeLists.linux.txt37
-rw-r--r--CMakeLists.txt39
-rw-r--r--library/cpp/build_info/CMakeLists.txt20
-rw-r--r--ydb/core/tablet/tablet_resolver.cpp1
-rw-r--r--ydb/library/yql/parser/proto_ast/gen/jsonpath/CMakeLists.txt24
-rw-r--r--ydb/library/yql/parser/proto_ast/gen/v0/CMakeLists.txt24
-rw-r--r--ydb/library/yql/parser/proto_ast/gen/v1/CMakeLists.txt16
-rw-r--r--ydb/library/yql/parser/proto_ast/gen/v1_ansi/CMakeLists.txt16
-rw-r--r--ydb/library/yql/parser/proto_ast/gen/v1_proto/CMakeLists.txt8
10 files changed, 39 insertions, 182 deletions
diff --git a/CMakeLists.darwin.txt b/CMakeLists.darwin.txt
index f5294ac8647..78fa522f972 100644
--- a/CMakeLists.darwin.txt
+++ b/CMakeLists.darwin.txt
@@ -6,42 +6,6 @@
# original buildsystem will not be accepted.
-include(cmake/antlr.cmake)
-include(cmake/bison.cmake)
-include(cmake/conan.cmake)
-include(cmake/protobuf.cmake)
-include(cmake/yandex_common.cmake)
-include(cmake/global_vars.cmake)
-
-conan_cmake_configure(
- GENERATORS cmake_find_package
- REQUIRES
- bison/3.5.3
- c-ares/1.17.2
- libiconv/1.15
- libidn/1.36
- openssl/1.1.1l
- ragel/6.10
- yasm/1.3.0
- zlib/1.2.11
- IMPORTS
- "bin, *yasm* -> ./bin"
- "bin, bison* -> ./bin/bison/bin"
- "bin, ragel* -> ./bin"
- "bin, ytasm* -> ./bin"
- "res, * -> ./bin/bison/res"
- OPTIONS
- libiconv:shared=True
- libidn:shared=True
-)
-conan_cmake_autodetect(settings)
-conan_cmake_install(
- PATH_OR_REFERENCE .
- BUILD missing
- REMOTE conancenter
- SETTINGS ${settings}
-)
-
add_subdirectory(ydb/apps/ydbd)
add_subdirectory(contrib/libs/cxxsupp)
add_subdirectory(contrib/libs/cxxsupp/libcxx)
diff --git a/CMakeLists.linux.txt b/CMakeLists.linux.txt
index 2eab2e65f56..835cb8ed361 100644
--- a/CMakeLists.linux.txt
+++ b/CMakeLists.linux.txt
@@ -6,43 +6,6 @@
# original buildsystem will not be accepted.
-include(cmake/FindAIO.cmake)
-include(cmake/antlr.cmake)
-include(cmake/bison.cmake)
-include(cmake/conan.cmake)
-include(cmake/protobuf.cmake)
-include(cmake/yandex_common.cmake)
-include(cmake/global_vars.cmake)
-
-conan_cmake_configure(
- GENERATORS cmake_find_package
- REQUIRES
- bison/3.5.3
- c-ares/1.17.2
- libiconv/1.15
- libidn/1.36
- openssl/1.1.1l
- ragel/6.10
- yasm/1.3.0
- zlib/1.2.11
- IMPORTS
- "bin, *yasm* -> ./bin"
- "bin, bison* -> ./bin/bison/bin"
- "bin, ragel* -> ./bin"
- "bin, ytasm* -> ./bin"
- "res, * -> ./bin/bison/res"
- OPTIONS
- libiconv:shared=True
- libidn:shared=True
-)
-conan_cmake_autodetect(settings)
-conan_cmake_install(
- PATH_OR_REFERENCE .
- BUILD missing
- REMOTE conancenter
- SETTINGS ${settings}
-)
-
add_subdirectory(ydb/apps/ydbd)
add_subdirectory(contrib/libs/cxxsupp)
add_subdirectory(contrib/libs/cxxsupp/libcxx)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index d3849189fd5..324b9b5a03c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -7,7 +7,7 @@
cmake_minimum_required(VERSION 3.15)
-project(YDB LANGUAGES C CXX ASM)
+project(YDB LANGUAGES)
set(BUILD_SHARED_LIBS Off)
set(CMAKE_CXX_STANDARD 20)
@@ -117,6 +117,43 @@ list(APPEND CMAKE_MODULE_PATH ${CMAKE_BINARY_DIR} ${CMAKE_SOURCE_DIR}/cmake)
include_directories(${CMAKE_SOURCE_DIR} ${CMAKE_BINARY_DIR})
list(APPEND CMAKE_CTEST_ARGUMENTS "--output-on-failure")
enable_testing()
+include(cmake/FindAIO.cmake)
+include(cmake/antlr.cmake)
+include(cmake/bison.cmake)
+include(cmake/conan.cmake)
+include(cmake/protobuf.cmake)
+include(cmake/yandex_common.cmake)
+include(cmake/global_vars.cmake)
+
+conan_cmake_configure(
+ GENERATORS cmake_find_package
+ REQUIRES
+ bison/3.5.3
+ c-ares/1.17.2
+ libiconv/1.15
+ libidn/1.36
+ openssl/1.1.1l
+ ragel/6.10
+ yasm/1.3.0
+ zlib/1.2.11
+ IMPORTS
+ "bin, *yasm* -> ./bin"
+ "bin, bison* -> ./bin/bison/bin"
+ "bin, ragel* -> ./bin"
+ "bin, ytasm* -> ./bin"
+ "res, * -> ./bin/bison/res"
+ OPTIONS
+ libiconv:shared=True
+ libidn:shared=True
+)
+conan_cmake_autodetect(settings)
+conan_cmake_install(
+ PATH_OR_REFERENCE .
+ BUILD missing
+ REMOTE conancenter
+ SETTINGS ${settings}
+)
+
if (UNIX)
include(CMakeLists.linux.txt)
elseif (APPLE)
diff --git a/library/cpp/build_info/CMakeLists.txt b/library/cpp/build_info/CMakeLists.txt
index 6223c56b953..b1075e61da8 100644
--- a/library/cpp/build_info/CMakeLists.txt
+++ b/library/cpp/build_info/CMakeLists.txt
@@ -32,23 +32,3 @@ add_custom_command(
\"${CMAKE_CXX_COMPILER}\"
\"${CMAKE_CXX_FLAGS}\"
)
-set(
- KOSHER_SVN_VERSION
-
-)
-set(
- SANDBOX_TASK_ID
- 0
-)
-configure_file(
- ${CMAKE_SOURCE_DIR}/library/cpp/build_info/sandbox.cpp.in
- ${CMAKE_BINARY_DIR}/library/cpp/build_info/sandbox.cpp
-)
-set(
- BUILD_TYPE
- RELEASE
-)
-configure_file(
- ${CMAKE_SOURCE_DIR}/library/cpp/build_info/build_info.cpp.in
- ${CMAKE_BINARY_DIR}/library/cpp/build_info/build_info.cpp
-)
diff --git a/ydb/core/tablet/tablet_resolver.cpp b/ydb/core/tablet/tablet_resolver.cpp
index c0a39a2216b..4b1ee1a6fcd 100644
--- a/ydb/core/tablet/tablet_resolver.cpp
+++ b/ydb/core/tablet/tablet_resolver.cpp
@@ -692,6 +692,7 @@ class TTabletResolver : public TActorBootstrapped<TTabletResolver> {
case TEntry::StInitResolve:
case TEntry::StNormal:
case TEntry::StProblemResolve:
+ case TEntry::StFollowerUpdate:
break;
case TEntry::StProblemPing:
if (ev->Sender == entry.KnownLeader) {
diff --git a/ydb/library/yql/parser/proto_ast/gen/jsonpath/CMakeLists.txt b/ydb/library/yql/parser/proto_ast/gen/jsonpath/CMakeLists.txt
index 8b3d9bd37af..430da85fdd4 100644
--- a/ydb/library/yql/parser/proto_ast/gen/jsonpath/CMakeLists.txt
+++ b/ydb/library/yql/parser/proto_ast/gen/jsonpath/CMakeLists.txt
@@ -37,30 +37,6 @@ run_antlr(
-language
protobuf
)
-set(
- ANTLR_PACKAGE_NAME
- NJsonPathGenerated
-)
-configure_file(
- ${CMAKE_SOURCE_DIR}/ydb/library/yql/parser/proto_ast/org/antlr/codegen/templates/protobuf/protobuf.stg.in
- ${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/jsonpath/org/antlr/codegen/templates/protobuf/protobuf.stg
-)
-set(
- ANTLR_PACKAGE_NAME
- NJsonPathGenerated
-)
-set(
- LEXER_PARSER_NAMESPACE
- NALP
-)
-set(
- PROTOBUF_HEADER_PATH
- ydb/library/yql/parser/proto_ast/gen/jsonpath
-)
-configure_file(
- ${CMAKE_SOURCE_DIR}/ydb/library/yql/parser/proto_ast/org/antlr/codegen/templates/Cpp/Cpp.stg.in
- ${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/jsonpath/org/antlr/codegen/templates/Cpp/Cpp.stg
-)
run_antlr(
OUTPUT
${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/jsonpath/JsonPathParser.cpp
diff --git a/ydb/library/yql/parser/proto_ast/gen/v0/CMakeLists.txt b/ydb/library/yql/parser/proto_ast/gen/v0/CMakeLists.txt
index 4c8cb54762b..a6800394a85 100644
--- a/ydb/library/yql/parser/proto_ast/gen/v0/CMakeLists.txt
+++ b/ydb/library/yql/parser/proto_ast/gen/v0/CMakeLists.txt
@@ -37,30 +37,6 @@ run_antlr(
-language
protobuf
)
-set(
- ANTLR_PACKAGE_NAME
- NSQLGenerated
-)
-configure_file(
- ${CMAKE_SOURCE_DIR}/ydb/library/yql/parser/proto_ast/org/antlr/codegen/templates/protobuf/protobuf.stg.in
- ${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v0/org/antlr/codegen/templates/protobuf/protobuf.stg
-)
-set(
- ANTLR_PACKAGE_NAME
- NSQLGenerated
-)
-set(
- LEXER_PARSER_NAMESPACE
- NALP
-)
-set(
- PROTOBUF_HEADER_PATH
- ydb/library/yql/parser/proto_ast/gen/v0
-)
-configure_file(
- ${CMAKE_SOURCE_DIR}/ydb/library/yql/parser/proto_ast/org/antlr/codegen/templates/Cpp/Cpp.stg.in
- ${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v0/org/antlr/codegen/templates/Cpp/Cpp.stg
-)
run_antlr(
OUTPUT
${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v0/SQLParser.cpp
diff --git a/ydb/library/yql/parser/proto_ast/gen/v1/CMakeLists.txt b/ydb/library/yql/parser/proto_ast/gen/v1/CMakeLists.txt
index cbc87e3a95b..d9efd5e094c 100644
--- a/ydb/library/yql/parser/proto_ast/gen/v1/CMakeLists.txt
+++ b/ydb/library/yql/parser/proto_ast/gen/v1/CMakeLists.txt
@@ -17,22 +17,6 @@ target_sources(proto_ast-gen-v1 PRIVATE
${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v1/SQLv1Parser.cpp
${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v1/SQLv1Lexer.cpp
)
-set(
- ANTLR_PACKAGE_NAME
- NSQLv1Generated
-)
-set(
- LEXER_PARSER_NAMESPACE
- NALPDefault
-)
-set(
- PROTOBUF_HEADER_PATH
- ydb/library/yql/parser/proto_ast/gen/v1_proto
-)
-configure_file(
- ${CMAKE_SOURCE_DIR}/ydb/library/yql/parser/proto_ast/org/antlr/codegen/templates/Cpp/Cpp.stg.in
- ${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v1/org/antlr/codegen/templates/Cpp/Cpp.stg
-)
run_antlr(
OUTPUT
${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v1/SQLv1Parser.cpp
diff --git a/ydb/library/yql/parser/proto_ast/gen/v1_ansi/CMakeLists.txt b/ydb/library/yql/parser/proto_ast/gen/v1_ansi/CMakeLists.txt
index c87ba4e8de8..08c02b17efd 100644
--- a/ydb/library/yql/parser/proto_ast/gen/v1_ansi/CMakeLists.txt
+++ b/ydb/library/yql/parser/proto_ast/gen/v1_ansi/CMakeLists.txt
@@ -17,22 +17,6 @@ target_sources(proto_ast-gen-v1_ansi PRIVATE
${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v1_ansi/SQLv1Parser.cpp
${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v1_ansi/SQLv1Lexer.cpp
)
-set(
- ANTLR_PACKAGE_NAME
- NSQLv1Generated
-)
-set(
- LEXER_PARSER_NAMESPACE
- NALPAnsi
-)
-set(
- PROTOBUF_HEADER_PATH
- ydb/library/yql/parser/proto_ast/gen/v1_proto
-)
-configure_file(
- ${CMAKE_SOURCE_DIR}/ydb/library/yql/parser/proto_ast/org/antlr/codegen/templates/Cpp/Cpp.stg.in
- ${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v1_ansi/org/antlr/codegen/templates/Cpp/Cpp.stg
-)
run_antlr(
OUTPUT
${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v1_ansi/SQLv1Parser.cpp
diff --git a/ydb/library/yql/parser/proto_ast/gen/v1_proto/CMakeLists.txt b/ydb/library/yql/parser/proto_ast/gen/v1_proto/CMakeLists.txt
index 3765497d5de..03e33eaba04 100644
--- a/ydb/library/yql/parser/proto_ast/gen/v1_proto/CMakeLists.txt
+++ b/ydb/library/yql/parser/proto_ast/gen/v1_proto/CMakeLists.txt
@@ -33,14 +33,6 @@ run_antlr(
-language
protobuf
)
-set(
- ANTLR_PACKAGE_NAME
- NSQLv1Generated
-)
-configure_file(
- ${CMAKE_SOURCE_DIR}/ydb/library/yql/parser/proto_ast/org/antlr/codegen/templates/protobuf/protobuf.stg.in
- ${CMAKE_BINARY_DIR}/ydb/library/yql/parser/proto_ast/gen/v1_proto/org/antlr/codegen/templates/protobuf/protobuf.stg
-)
set(GRAMMAR_STRING_CORE_SINGLE "~(QUOTE_SINGLE | BACKSLASH) | (BACKSLASH .)")
set(GRAMMAR_STRING_CORE_DOUBLE "~(QUOTE_DOUBLE | BACKSLASH) | (BACKSLASH .)")
set(GRAMMAR_MULTILINE_COMMENT_CORE ".")