mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-11 17:02:25 +00:00
Merge branch 'yandex-to-clickhouse-in-configs' of github.com:yandex/ClickHouse into yandex-to-clickhouse-in-configs
This commit is contained in:
commit
a48d422bc1
12
.arcignore
12
.arcignore
@ -1,12 +0,0 @@
|
||||
# .arcignore is the same as .gitignore but for Arc VCS.
|
||||
# Arc VCS is a proprietary VCS in Yandex that is very similar to Git
|
||||
# from the user perspective but with the following differences:
|
||||
# 1. Data is stored in distributed object storage.
|
||||
# 2. Local copy works via FUSE without downloading all the objects.
|
||||
# For this reason, it is better suited for huge monorepositories that can be found in large companies (e.g. Yandex, Google).
|
||||
# As ClickHouse developers, we don't use Arc as a VCS (we use Git).
|
||||
# But the ClickHouse source code is also mirrored into internal monorepository and our collegues are using Arc.
|
||||
# You can read more about Arc here: https://habr.com/en/company/yandex/blog/482926/
|
||||
|
||||
# Repository is synchronized without 3rd-party submodules.
|
||||
contrib
|
@ -1,63 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL(
|
||||
GLOBAL clickhouse/base
|
||||
)
|
||||
|
||||
CFLAGS (GLOBAL -DARCADIA_BUILD)
|
||||
|
||||
CFLAGS (GLOBAL -DUSE_CPUID=1)
|
||||
CFLAGS (GLOBAL -DUSE_JEMALLOC=0)
|
||||
CFLAGS (GLOBAL -DUSE_RAPIDJSON=1)
|
||||
CFLAGS (GLOBAL -DUSE_SSL=1)
|
||||
|
||||
IF (OS_DARWIN)
|
||||
CFLAGS (GLOBAL -DOS_DARWIN)
|
||||
ELSEIF (OS_FREEBSD)
|
||||
CFLAGS (GLOBAL -DOS_FREEBSD)
|
||||
ELSEIF (OS_LINUX)
|
||||
CFLAGS (GLOBAL -DOS_LINUX)
|
||||
ENDIF ()
|
||||
|
||||
PEERDIR(
|
||||
contrib/libs/cctz
|
||||
contrib/libs/cxxsupp/libcxx-filesystem
|
||||
contrib/libs/poco/Net
|
||||
contrib/libs/poco/Util
|
||||
contrib/libs/poco/NetSSL_OpenSSL
|
||||
contrib/libs/fmt
|
||||
contrib/restricted/boost
|
||||
contrib/restricted/cityhash-1.0.2
|
||||
)
|
||||
|
||||
CFLAGS(-g0)
|
||||
|
||||
SRCS(
|
||||
DateLUT.cpp
|
||||
DateLUTImpl.cpp
|
||||
JSON.cpp
|
||||
LineReader.cpp
|
||||
StringRef.cpp
|
||||
argsToConfig.cpp
|
||||
coverage.cpp
|
||||
demangle.cpp
|
||||
errnoToString.cpp
|
||||
getFQDNOrHostName.cpp
|
||||
getMemoryAmount.cpp
|
||||
getPageSize.cpp
|
||||
getResource.cpp
|
||||
getThreadId.cpp
|
||||
mremap.cpp
|
||||
phdr_cache.cpp
|
||||
preciseExp10.cpp
|
||||
setTerminalEcho.cpp
|
||||
shift10.cpp
|
||||
sleep.cpp
|
||||
terminalColors.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,41 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL(
|
||||
GLOBAL clickhouse/base
|
||||
)
|
||||
|
||||
CFLAGS (GLOBAL -DARCADIA_BUILD)
|
||||
|
||||
CFLAGS (GLOBAL -DUSE_CPUID=1)
|
||||
CFLAGS (GLOBAL -DUSE_JEMALLOC=0)
|
||||
CFLAGS (GLOBAL -DUSE_RAPIDJSON=1)
|
||||
CFLAGS (GLOBAL -DUSE_SSL=1)
|
||||
|
||||
IF (OS_DARWIN)
|
||||
CFLAGS (GLOBAL -DOS_DARWIN)
|
||||
ELSEIF (OS_FREEBSD)
|
||||
CFLAGS (GLOBAL -DOS_FREEBSD)
|
||||
ELSEIF (OS_LINUX)
|
||||
CFLAGS (GLOBAL -DOS_LINUX)
|
||||
ENDIF ()
|
||||
|
||||
PEERDIR(
|
||||
contrib/libs/cctz
|
||||
contrib/libs/cxxsupp/libcxx-filesystem
|
||||
contrib/libs/poco/Net
|
||||
contrib/libs/poco/Util
|
||||
contrib/libs/poco/NetSSL_OpenSSL
|
||||
contrib/libs/fmt
|
||||
contrib/restricted/boost
|
||||
contrib/restricted/cityhash-1.0.2
|
||||
)
|
||||
|
||||
CFLAGS(-g0)
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests/ | grep -v -F examples | grep -v -F Replxx | grep -v -F Readline | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,19 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
NO_COMPILER_WARNINGS()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
CFLAGS(-g0)
|
||||
|
||||
SRCS(
|
||||
BaseDaemon.cpp
|
||||
GraphiteWriter.cpp
|
||||
SentryWriter.cpp
|
||||
)
|
||||
|
||||
END()
|
@ -1,19 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
CFLAGS(-g0)
|
||||
|
||||
SRCS(
|
||||
ExtendedLogChannel.cpp
|
||||
Loggers.cpp
|
||||
OwnFormattingChannel.cpp
|
||||
OwnPatternFormatter.cpp
|
||||
OwnSplitChannel.cpp
|
||||
)
|
||||
|
||||
END()
|
@ -1,39 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
LIBRARY()
|
||||
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
CFLAGS(-g0)
|
||||
|
||||
PEERDIR(
|
||||
contrib/restricted/boost/libs
|
||||
contrib/libs/libmysql_r
|
||||
contrib/libs/poco/Foundation
|
||||
contrib/libs/poco/Util
|
||||
)
|
||||
|
||||
ADDINCL(
|
||||
GLOBAL clickhouse/base
|
||||
clickhouse/base
|
||||
contrib/libs/libmysql_r
|
||||
)
|
||||
|
||||
NO_COMPILER_WARNINGS()
|
||||
|
||||
NO_UTIL()
|
||||
|
||||
SRCS(
|
||||
Connection.cpp
|
||||
Exception.cpp
|
||||
Pool.cpp
|
||||
PoolFactory.cpp
|
||||
PoolWithFailover.cpp
|
||||
Query.cpp
|
||||
ResultBase.cpp
|
||||
Row.cpp
|
||||
UseQueryResult.cpp
|
||||
Value.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,28 +0,0 @@
|
||||
LIBRARY()
|
||||
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
CFLAGS(-g0)
|
||||
|
||||
PEERDIR(
|
||||
contrib/restricted/boost/libs
|
||||
contrib/libs/libmysql_r
|
||||
contrib/libs/poco/Foundation
|
||||
contrib/libs/poco/Util
|
||||
)
|
||||
|
||||
ADDINCL(
|
||||
GLOBAL clickhouse/base
|
||||
clickhouse/base
|
||||
contrib/libs/libmysql_r
|
||||
)
|
||||
|
||||
NO_COMPILER_WARNINGS()
|
||||
|
||||
NO_UTIL()
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests/ | grep -v -F examples | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,7 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL (GLOBAL clickhouse/base/pcg-random)
|
||||
|
||||
END()
|
@ -1,11 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
CFLAGS(-g0)
|
||||
|
||||
SRCS(
|
||||
readpassphrase.c
|
||||
)
|
||||
|
||||
END()
|
@ -1,13 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL(GLOBAL clickhouse/base/widechar_width)
|
||||
|
||||
CFLAGS(-g0)
|
||||
|
||||
SRCS(
|
||||
widechar_width.cpp
|
||||
)
|
||||
|
||||
END()
|
11
base/ya.make
11
base/ya.make
@ -1,11 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
RECURSE(
|
||||
common
|
||||
daemon
|
||||
loggers
|
||||
mysqlxx
|
||||
pcg-random
|
||||
widechar_width
|
||||
readpassphrase
|
||||
)
|
@ -1,25 +0,0 @@
|
||||
INCLUDE(${ARCADIA_ROOT}/clickhouse/cmake/autogenerated_versions.txt)
|
||||
|
||||
# TODO: not sure if this is customizable per-binary
|
||||
SET(VERSION_NAME "ClickHouse")
|
||||
|
||||
# TODO: not quite sure how to replace dash with space in ya.make
|
||||
SET(VERSION_FULL "${VERSION_NAME}-${VERSION_STRING}")
|
||||
|
||||
CFLAGS (GLOBAL -DDBMS_NAME=\"ClickHouse\")
|
||||
CFLAGS (GLOBAL -DDBMS_VERSION_MAJOR=${VERSION_MAJOR})
|
||||
CFLAGS (GLOBAL -DDBMS_VERSION_MINOR=${VERSION_MINOR})
|
||||
CFLAGS (GLOBAL -DDBMS_VERSION_PATCH=${VERSION_PATCH})
|
||||
CFLAGS (GLOBAL -DVERSION_FULL=\"\\\"${VERSION_FULL}\\\"\")
|
||||
CFLAGS (GLOBAL -DVERSION_MAJOR=${VERSION_MAJOR})
|
||||
CFLAGS (GLOBAL -DVERSION_MINOR=${VERSION_MINOR})
|
||||
CFLAGS (GLOBAL -DVERSION_PATCH=${VERSION_PATCH})
|
||||
|
||||
# TODO: not supported yet, not sure if ya.make supports arithmetic.
|
||||
CFLAGS (GLOBAL -DVERSION_INTEGER=0)
|
||||
|
||||
CFLAGS (GLOBAL -DVERSION_NAME=\"\\\"${VERSION_NAME}\\\"\")
|
||||
CFLAGS (GLOBAL -DVERSION_OFFICIAL=\"-arcadia\")
|
||||
CFLAGS (GLOBAL -DVERSION_REVISION=${VERSION_REVISION})
|
||||
CFLAGS (GLOBAL -DVERSION_STRING=\"\\\"${VERSION_STRING}\\\"\")
|
||||
|
2
contrib/libhdfs3
vendored
2
contrib/libhdfs3
vendored
@ -1 +1 @@
|
||||
Subproject commit 095b9d48b400abb72d967cb0539af13b1e3d90cf
|
||||
Subproject commit 082e55f17d1c58bf124290fb044fea40e985ec11
|
@ -44,6 +44,7 @@ int mainEntryClickHouseFormat(int argc, char ** argv)
|
||||
|
||||
boost::program_options::options_description desc = createOptionsDescription("Allowed options", getTerminalWidth());
|
||||
desc.add_options()
|
||||
("query", po::value<std::string>(), "query to format")
|
||||
("help,h", "produce help message")
|
||||
("hilite", "add syntax highlight with ANSI terminal escape sequences")
|
||||
("oneline", "format in single line")
|
||||
@ -86,8 +87,16 @@ int mainEntryClickHouseFormat(int argc, char ** argv)
|
||||
}
|
||||
|
||||
String query;
|
||||
ReadBufferFromFileDescriptor in(STDIN_FILENO);
|
||||
readStringUntilEOF(query, in);
|
||||
|
||||
if (options.count("query"))
|
||||
{
|
||||
query = options["query"].as<std::string>();
|
||||
}
|
||||
else
|
||||
{
|
||||
ReadBufferFromFileDescriptor in(STDIN_FILENO);
|
||||
readStringUntilEOF(query, in);
|
||||
}
|
||||
|
||||
if (obfuscate)
|
||||
{
|
||||
|
@ -962,7 +962,7 @@ namespace
|
||||
if (isRunning(pid_file))
|
||||
{
|
||||
throw Exception(ErrorCodes::CANNOT_KILL,
|
||||
"The server process still exists after %zu ms",
|
||||
"The server process still exists after {} tries (delay: {} ms)",
|
||||
num_kill_check_tries, kill_check_delay_ms);
|
||||
}
|
||||
}
|
||||
|
@ -1,22 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
PROGRAM(clickhouse-server)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/base/common
|
||||
clickhouse/base/daemon
|
||||
clickhouse/base/loggers
|
||||
clickhouse/src
|
||||
contrib/libs/poco/NetSSL_OpenSSL
|
||||
)
|
||||
|
||||
CFLAGS(-g0)
|
||||
|
||||
SRCS(
|
||||
clickhouse-server.cpp
|
||||
|
||||
MetricsTransmitter.cpp
|
||||
Server.cpp
|
||||
)
|
||||
|
||||
END()
|
@ -1,32 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
PROGRAM(clickhouse)
|
||||
|
||||
CFLAGS(
|
||||
-DENABLE_CLICKHOUSE_CLIENT
|
||||
-DENABLE_CLICKHOUSE_EXTRACT_FROM_CONFIG
|
||||
-DENABLE_CLICKHOUSE_SERVER
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/base/daemon
|
||||
clickhouse/base/loggers
|
||||
clickhouse/src
|
||||
)
|
||||
|
||||
CFLAGS(-g0)
|
||||
|
||||
SRCS(
|
||||
main.cpp
|
||||
|
||||
client/Client.cpp
|
||||
client/QueryFuzzer.cpp
|
||||
client/ConnectionParameters.cpp
|
||||
client/Suggest.cpp
|
||||
client/TestHint.cpp
|
||||
extract-from-config/ExtractFromConfig.cpp
|
||||
server/Server.cpp
|
||||
server/MetricsTransmitter.cpp
|
||||
)
|
||||
|
||||
END()
|
@ -1,54 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
AccessControlManager.cpp
|
||||
AccessEntityIO.cpp
|
||||
AccessRights.cpp
|
||||
AccessRightsElement.cpp
|
||||
AllowedClientHosts.cpp
|
||||
Authentication.cpp
|
||||
ContextAccess.cpp
|
||||
Credentials.cpp
|
||||
DiskAccessStorage.cpp
|
||||
EnabledQuota.cpp
|
||||
EnabledRoles.cpp
|
||||
EnabledRolesInfo.cpp
|
||||
EnabledRowPolicies.cpp
|
||||
EnabledSettings.cpp
|
||||
ExternalAuthenticators.cpp
|
||||
GSSAcceptor.cpp
|
||||
GrantedRoles.cpp
|
||||
IAccessEntity.cpp
|
||||
IAccessStorage.cpp
|
||||
LDAPAccessStorage.cpp
|
||||
LDAPClient.cpp
|
||||
MemoryAccessStorage.cpp
|
||||
MultipleAccessStorage.cpp
|
||||
Quota.cpp
|
||||
QuotaCache.cpp
|
||||
QuotaUsage.cpp
|
||||
ReplicatedAccessStorage.cpp
|
||||
Role.cpp
|
||||
RoleCache.cpp
|
||||
RolesOrUsersSet.cpp
|
||||
RowPolicy.cpp
|
||||
RowPolicyCache.cpp
|
||||
SettingsConstraints.cpp
|
||||
SettingsProfile.cpp
|
||||
SettingsProfileElement.cpp
|
||||
SettingsProfilesCache.cpp
|
||||
SettingsProfilesInfo.cpp
|
||||
User.cpp
|
||||
UsersConfigAccessStorage.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,14 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,74 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
AggregateFunctionAggThrow.cpp
|
||||
AggregateFunctionAny.cpp
|
||||
AggregateFunctionArray.cpp
|
||||
AggregateFunctionAvg.cpp
|
||||
AggregateFunctionAvgWeighted.cpp
|
||||
AggregateFunctionBitwise.cpp
|
||||
AggregateFunctionBoundingRatio.cpp
|
||||
AggregateFunctionCategoricalInformationValue.cpp
|
||||
AggregateFunctionCombinatorFactory.cpp
|
||||
AggregateFunctionCount.cpp
|
||||
AggregateFunctionDeltaSum.cpp
|
||||
AggregateFunctionDeltaSumTimestamp.cpp
|
||||
AggregateFunctionDistinct.cpp
|
||||
AggregateFunctionEntropy.cpp
|
||||
AggregateFunctionFactory.cpp
|
||||
AggregateFunctionForEach.cpp
|
||||
AggregateFunctionGroupArray.cpp
|
||||
AggregateFunctionGroupArrayInsertAt.cpp
|
||||
AggregateFunctionGroupArrayMoving.cpp
|
||||
AggregateFunctionGroupUniqArray.cpp
|
||||
AggregateFunctionHistogram.cpp
|
||||
AggregateFunctionIf.cpp
|
||||
AggregateFunctionIntervalLengthSum.cpp
|
||||
AggregateFunctionMLMethod.cpp
|
||||
AggregateFunctionMannWhitney.cpp
|
||||
AggregateFunctionMax.cpp
|
||||
AggregateFunctionMaxIntersections.cpp
|
||||
AggregateFunctionMerge.cpp
|
||||
AggregateFunctionMin.cpp
|
||||
AggregateFunctionNull.cpp
|
||||
AggregateFunctionOrFill.cpp
|
||||
AggregateFunctionQuantile.cpp
|
||||
AggregateFunctionRankCorrelation.cpp
|
||||
AggregateFunctionResample.cpp
|
||||
AggregateFunctionRetention.cpp
|
||||
AggregateFunctionSequenceMatch.cpp
|
||||
AggregateFunctionSequenceNextNode.cpp
|
||||
AggregateFunctionSimpleLinearRegression.cpp
|
||||
AggregateFunctionSimpleState.cpp
|
||||
AggregateFunctionSingleValueOrNull.cpp
|
||||
AggregateFunctionSparkbar.cpp
|
||||
AggregateFunctionState.cpp
|
||||
AggregateFunctionStatistics.cpp
|
||||
AggregateFunctionStatisticsSimple.cpp
|
||||
AggregateFunctionStudentTTest.cpp
|
||||
AggregateFunctionSum.cpp
|
||||
AggregateFunctionSumCount.cpp
|
||||
AggregateFunctionSumMap.cpp
|
||||
AggregateFunctionTopK.cpp
|
||||
AggregateFunctionUniq.cpp
|
||||
AggregateFunctionUniqCombined.cpp
|
||||
AggregateFunctionUniqUpTo.cpp
|
||||
AggregateFunctionWelchTTest.cpp
|
||||
AggregateFunctionWindowFunnel.cpp
|
||||
IAggregateFunction.cpp
|
||||
UniqCombinedBiasData.cpp
|
||||
UniqVariadicHash.cpp
|
||||
parseAggregateFunctionParameters.cpp
|
||||
registerAggregateFunctions.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,14 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | grep -v -F GroupBitmap | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,27 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
BackupEntryConcat.cpp
|
||||
BackupEntryFromAppendOnlyFile.cpp
|
||||
BackupEntryFromImmutableFile.cpp
|
||||
BackupEntryFromMemory.cpp
|
||||
BackupEntryFromSmallFile.cpp
|
||||
BackupFactory.cpp
|
||||
BackupInDirectory.cpp
|
||||
BackupRenamingConfig.cpp
|
||||
BackupSettings.cpp
|
||||
BackupUtils.cpp
|
||||
hasCompatibleDataToRestoreTable.cpp
|
||||
renameInCreateQuery.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,14 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,17 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
IBridgeHelper.cpp
|
||||
LibraryBridgeHelper.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,14 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,24 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/poco/NetSSL_OpenSSL
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
Connection.cpp
|
||||
ConnectionEstablisher.cpp
|
||||
ConnectionPool.cpp
|
||||
ConnectionPoolWithFailover.cpp
|
||||
HedgedConnections.cpp
|
||||
HedgedConnectionsFactory.cpp
|
||||
IConnections.cpp
|
||||
MultiplexedConnections.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,15 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/poco/NetSSL_OpenSSL
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,43 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL(
|
||||
contrib/libs/icu/common
|
||||
contrib/libs/icu/i18n
|
||||
contrib/libs/pdqsort
|
||||
contrib/libs/lz4
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/icu
|
||||
contrib/libs/pdqsort
|
||||
contrib/libs/lz4
|
||||
)
|
||||
|
||||
SRCS(
|
||||
Collator.cpp
|
||||
ColumnAggregateFunction.cpp
|
||||
ColumnArray.cpp
|
||||
ColumnCompressed.cpp
|
||||
ColumnConst.cpp
|
||||
ColumnDecimal.cpp
|
||||
ColumnFixedString.cpp
|
||||
ColumnFunction.cpp
|
||||
ColumnLowCardinality.cpp
|
||||
ColumnMap.cpp
|
||||
ColumnNullable.cpp
|
||||
ColumnString.cpp
|
||||
ColumnTuple.cpp
|
||||
ColumnVector.cpp
|
||||
ColumnsCommon.cpp
|
||||
FilterDescription.cpp
|
||||
IColumn.cpp
|
||||
MaskOperations.cpp
|
||||
getLeastSuperColumn.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,23 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL(
|
||||
contrib/libs/icu/common
|
||||
contrib/libs/icu/i18n
|
||||
contrib/libs/pdqsort
|
||||
contrib/libs/lz4
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/icu
|
||||
contrib/libs/pdqsort
|
||||
contrib/libs/lz4
|
||||
)
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,133 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL (
|
||||
GLOBAL clickhouse/src
|
||||
contrib/libs/libcpuid
|
||||
contrib/libs/libunwind/include
|
||||
GLOBAL contrib/restricted/dragonbox
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/base/common
|
||||
clickhouse/base/pcg-random
|
||||
clickhouse/base/widechar_width
|
||||
contrib/libs/libcpuid
|
||||
contrib/libs/openssl
|
||||
contrib/libs/poco/NetSSL_OpenSSL
|
||||
contrib/libs/re2
|
||||
contrib/restricted/dragonbox
|
||||
)
|
||||
|
||||
INCLUDE(${ARCADIA_ROOT}/clickhouse/cmake/yandex/ya.make.versions.inc)
|
||||
|
||||
|
||||
SRCS(
|
||||
ActionLock.cpp
|
||||
AlignedBuffer.cpp
|
||||
Allocator.cpp
|
||||
ClickHouseRevision.cpp
|
||||
Config/AbstractConfigurationComparison.cpp
|
||||
Config/ConfigProcessor.cpp
|
||||
Config/ConfigReloader.cpp
|
||||
Config/YAMLParser.cpp
|
||||
Config/configReadClient.cpp
|
||||
CurrentMemoryTracker.cpp
|
||||
CurrentMetrics.cpp
|
||||
CurrentThread.cpp
|
||||
DNSResolver.cpp
|
||||
Dwarf.cpp
|
||||
Elf.cpp
|
||||
Epoll.cpp
|
||||
ErrorCodes.cpp
|
||||
Exception.cpp
|
||||
FieldVisitorDump.cpp
|
||||
FieldVisitorHash.cpp
|
||||
FieldVisitorSum.cpp
|
||||
FieldVisitorToString.cpp
|
||||
FieldVisitorWriteBinary.cpp
|
||||
FileChecker.cpp
|
||||
IO.cpp
|
||||
IPv6ToBinary.cpp
|
||||
IntervalKind.cpp
|
||||
JSONBuilder.cpp
|
||||
Macros.cpp
|
||||
MemoryStatisticsOS.cpp
|
||||
MemoryTracker.cpp
|
||||
OpenSSLHelpers.cpp
|
||||
OptimizedRegularExpression.cpp
|
||||
PODArray.cpp
|
||||
PipeFDs.cpp
|
||||
ProcfsMetricsProvider.cpp
|
||||
ProfileEvents.cpp
|
||||
ProgressIndication.cpp
|
||||
QueryProfiler.cpp
|
||||
RWLock.cpp
|
||||
RemoteHostFilter.cpp
|
||||
SensitiveDataMasker.cpp
|
||||
SettingsChanges.cpp
|
||||
SharedLibrary.cpp
|
||||
ShellCommand.cpp
|
||||
StackTrace.cpp
|
||||
StatusFile.cpp
|
||||
StatusInfo.cpp
|
||||
Stopwatch.cpp
|
||||
StringUtils/StringUtils.cpp
|
||||
StudentTTest.cpp
|
||||
SymbolIndex.cpp
|
||||
TLDListsHolder.cpp
|
||||
TaskStatsInfoGetter.cpp
|
||||
TerminalSize.cpp
|
||||
ThreadFuzzer.cpp
|
||||
ThreadPool.cpp
|
||||
ThreadProfileEvents.cpp
|
||||
ThreadStatus.cpp
|
||||
Throttler.cpp
|
||||
TimerDescriptor.cpp
|
||||
TraceCollector.cpp
|
||||
UTF8Helpers.cpp
|
||||
UnicodeBar.cpp
|
||||
VersionNumber.cpp
|
||||
WeakHash.cpp
|
||||
ZooKeeper/IKeeper.cpp
|
||||
ZooKeeper/TestKeeper.cpp
|
||||
ZooKeeper/ZooKeeper.cpp
|
||||
ZooKeeper/ZooKeeperCommon.cpp
|
||||
ZooKeeper/ZooKeeperConstants.cpp
|
||||
ZooKeeper/ZooKeeperIO.cpp
|
||||
ZooKeeper/ZooKeeperImpl.cpp
|
||||
ZooKeeper/ZooKeeperNodeCache.cpp
|
||||
checkStackSize.cpp
|
||||
clearPasswordFromCommandLine.cpp
|
||||
clickhouse_malloc.cpp
|
||||
createHardLink.cpp
|
||||
escapeForFileName.cpp
|
||||
filesystemHelpers.cpp
|
||||
formatIPv6.cpp
|
||||
formatReadable.cpp
|
||||
getExecutablePath.cpp
|
||||
getHashOfLoadedBinary.cpp
|
||||
getMappedArea.cpp
|
||||
getMultipleKeysFromConfig.cpp
|
||||
getNumberOfPhysicalCPUCores.cpp
|
||||
hasLinuxCapability.cpp
|
||||
hex.cpp
|
||||
isLocalAddress.cpp
|
||||
isValidUTF8.cpp
|
||||
malloc.cpp
|
||||
new_delete.cpp
|
||||
parseAddress.cpp
|
||||
parseGlobs.cpp
|
||||
parseRemoteDescription.cpp
|
||||
quoteString.cpp
|
||||
randomSeed.cpp
|
||||
remapExecutable.cpp
|
||||
renameat2.cpp
|
||||
setThreadName.cpp
|
||||
thread_local_rng.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,30 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL (
|
||||
GLOBAL clickhouse/src
|
||||
contrib/libs/libcpuid
|
||||
contrib/libs/libunwind/include
|
||||
GLOBAL contrib/restricted/dragonbox
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/base/common
|
||||
clickhouse/base/pcg-random
|
||||
clickhouse/base/widechar_width
|
||||
contrib/libs/libcpuid
|
||||
contrib/libs/openssl
|
||||
contrib/libs/poco/NetSSL_OpenSSL
|
||||
contrib/libs/re2
|
||||
contrib/restricted/dragonbox
|
||||
)
|
||||
|
||||
INCLUDE(${ARCADIA_ROOT}/clickhouse/cmake/yandex/ya.make.versions.inc)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,42 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL(
|
||||
contrib/libs/lz4
|
||||
contrib/libs/zstd/include
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/lz4
|
||||
contrib/libs/zstd
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
CachedCompressedReadBuffer.cpp
|
||||
CheckingCompressedReadBuffer.cpp
|
||||
CompressedReadBuffer.cpp
|
||||
CompressedReadBufferBase.cpp
|
||||
CompressedReadBufferFromFile.cpp
|
||||
CompressedWriteBuffer.cpp
|
||||
CompressionCodecDelta.cpp
|
||||
CompressionCodecDoubleDelta.cpp
|
||||
CompressionCodecEncrypted.cpp
|
||||
CompressionCodecGorilla.cpp
|
||||
CompressionCodecLZ4.cpp
|
||||
CompressionCodecMultiple.cpp
|
||||
CompressionCodecNone.cpp
|
||||
CompressionCodecT64.cpp
|
||||
CompressionCodecZSTD.cpp
|
||||
CompressionFactory.cpp
|
||||
CompressionFactoryAdditions.cpp
|
||||
ICompressionCodec.cpp
|
||||
LZ4_decompress_faster.cpp
|
||||
getCompressionCodecForFile.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,21 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL(
|
||||
contrib/libs/lz4
|
||||
contrib/libs/zstd/include
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/lz4
|
||||
contrib/libs/zstd
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,13 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
SRCS(
|
||||
)
|
||||
|
||||
END()
|
@ -1,12 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
SRCS(
|
||||
)
|
||||
|
||||
END()
|
@ -1,51 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/sparsehash
|
||||
contrib/restricted/boost/libs
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
BackgroundSchedulePool.cpp
|
||||
BaseSettings.cpp
|
||||
Block.cpp
|
||||
BlockInfo.cpp
|
||||
ColumnWithTypeAndName.cpp
|
||||
ExternalResultDescription.cpp
|
||||
ExternalTable.cpp
|
||||
Field.cpp
|
||||
MySQL/Authentication.cpp
|
||||
MySQL/IMySQLReadPacket.cpp
|
||||
MySQL/IMySQLWritePacket.cpp
|
||||
MySQL/MySQLClient.cpp
|
||||
MySQL/MySQLGtid.cpp
|
||||
MySQL/MySQLReplication.cpp
|
||||
MySQL/PacketEndpoint.cpp
|
||||
MySQL/PacketsConnection.cpp
|
||||
MySQL/PacketsGeneric.cpp
|
||||
MySQL/PacketsProtocolText.cpp
|
||||
MySQL/PacketsReplication.cpp
|
||||
NamesAndTypes.cpp
|
||||
PostgreSQL/Connection.cpp
|
||||
PostgreSQL/PoolWithFailover.cpp
|
||||
PostgreSQL/Utils.cpp
|
||||
PostgreSQL/insertPostgreSQLValue.cpp
|
||||
PostgreSQLProtocol.cpp
|
||||
QueryProcessingStage.cpp
|
||||
ServerUUID.cpp
|
||||
Settings.cpp
|
||||
SettingsEnums.cpp
|
||||
SettingsFields.cpp
|
||||
SettingsQuirks.cpp
|
||||
SortDescription.cpp
|
||||
UUID.cpp
|
||||
iostream_debug_helpers.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,16 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/sparsehash
|
||||
contrib/restricted/boost/libs
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,59 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/poco/MongoDB
|
||||
contrib/restricted/boost/libs
|
||||
)
|
||||
|
||||
NO_COMPILER_WARNINGS()
|
||||
|
||||
|
||||
SRCS(
|
||||
AddingDefaultBlockOutputStream.cpp
|
||||
AsynchronousBlockInputStream.cpp
|
||||
BlockIO.cpp
|
||||
BlockStreamProfileInfo.cpp
|
||||
CheckConstraintsBlockOutputStream.cpp
|
||||
ColumnGathererStream.cpp
|
||||
ConnectionCollector.cpp
|
||||
ConvertingBlockInputStream.cpp
|
||||
CountingBlockOutputStream.cpp
|
||||
DistinctSortedBlockInputStream.cpp
|
||||
ExecutionSpeedLimits.cpp
|
||||
ExpressionBlockInputStream.cpp
|
||||
IBlockInputStream.cpp
|
||||
ITTLAlgorithm.cpp
|
||||
InternalTextLogsRowOutputStream.cpp
|
||||
MaterializingBlockInputStream.cpp
|
||||
MongoDBSource.cpp
|
||||
NativeBlockInputStream.cpp
|
||||
NativeBlockOutputStream.cpp
|
||||
PushingToViewsBlockOutputStream.cpp
|
||||
RemoteBlockInputStream.cpp
|
||||
RemoteBlockOutputStream.cpp
|
||||
RemoteQueryExecutor.cpp
|
||||
RemoteQueryExecutorReadContext.cpp
|
||||
SQLiteSource.cpp
|
||||
SizeLimits.cpp
|
||||
SquashingBlockInputStream.cpp
|
||||
SquashingBlockOutputStream.cpp
|
||||
SquashingTransform.cpp
|
||||
TTLAggregationAlgorithm.cpp
|
||||
TTLBlockInputStream.cpp
|
||||
TTLCalcInputStream.cpp
|
||||
TTLColumnAlgorithm.cpp
|
||||
TTLDeleteAlgorithm.cpp
|
||||
TTLUpdateInfoAlgorithm.cpp
|
||||
copyData.cpp
|
||||
finalizeBlock.cpp
|
||||
formatBlock.cpp
|
||||
materializeBlock.cpp
|
||||
narrowBlockInputStreams.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,18 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/poco/MongoDB
|
||||
contrib/restricted/boost/libs
|
||||
)
|
||||
|
||||
NO_COMPILER_WARNINGS()
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -P 'tests|PostgreSQL' | grep -v -F examples | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,74 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
clickhouse/src/Formats
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
DataTypeAggregateFunction.cpp
|
||||
DataTypeArray.cpp
|
||||
DataTypeCustomGeo.cpp
|
||||
DataTypeCustomIPv4AndIPv6.cpp
|
||||
DataTypeCustomSimpleAggregateFunction.cpp
|
||||
DataTypeDate.cpp
|
||||
DataTypeDate32.cpp
|
||||
DataTypeDateTime.cpp
|
||||
DataTypeDateTime64.cpp
|
||||
DataTypeDecimalBase.cpp
|
||||
DataTypeEnum.cpp
|
||||
DataTypeFactory.cpp
|
||||
DataTypeFixedString.cpp
|
||||
DataTypeFunction.cpp
|
||||
DataTypeInterval.cpp
|
||||
DataTypeLowCardinality.cpp
|
||||
DataTypeLowCardinalityHelpers.cpp
|
||||
DataTypeMap.cpp
|
||||
DataTypeNested.cpp
|
||||
DataTypeNothing.cpp
|
||||
DataTypeNullable.cpp
|
||||
DataTypeNumberBase.cpp
|
||||
DataTypeString.cpp
|
||||
DataTypeTuple.cpp
|
||||
DataTypeUUID.cpp
|
||||
DataTypesDecimal.cpp
|
||||
DataTypesNumber.cpp
|
||||
EnumValues.cpp
|
||||
FieldToDataType.cpp
|
||||
IDataType.cpp
|
||||
NestedUtils.cpp
|
||||
Serializations/ISerialization.cpp
|
||||
Serializations/SerializationAggregateFunction.cpp
|
||||
Serializations/SerializationArray.cpp
|
||||
Serializations/SerializationCustomSimpleText.cpp
|
||||
Serializations/SerializationDate.cpp
|
||||
Serializations/SerializationDate32.cpp
|
||||
Serializations/SerializationDateTime.cpp
|
||||
Serializations/SerializationDateTime64.cpp
|
||||
Serializations/SerializationDecimal.cpp
|
||||
Serializations/SerializationDecimalBase.cpp
|
||||
Serializations/SerializationEnum.cpp
|
||||
Serializations/SerializationFixedString.cpp
|
||||
Serializations/SerializationIP.cpp
|
||||
Serializations/SerializationLowCardinality.cpp
|
||||
Serializations/SerializationMap.cpp
|
||||
Serializations/SerializationNothing.cpp
|
||||
Serializations/SerializationNullable.cpp
|
||||
Serializations/SerializationNumber.cpp
|
||||
Serializations/SerializationString.cpp
|
||||
Serializations/SerializationTuple.cpp
|
||||
Serializations/SerializationTupleElement.cpp
|
||||
Serializations/SerializationUUID.cpp
|
||||
Serializations/SerializationWrapper.cpp
|
||||
convertMySQLDataType.cpp
|
||||
getLeastSupertype.cpp
|
||||
getMostSubtype.cpp
|
||||
registerDataTypeDateTime.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,15 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
clickhouse/src/Formats
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,38 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
DDLDependencyVisitor.cpp
|
||||
DatabaseAtomic.cpp
|
||||
DatabaseDictionary.cpp
|
||||
DatabaseFactory.cpp
|
||||
DatabaseLazy.cpp
|
||||
DatabaseMemory.cpp
|
||||
DatabaseOnDisk.cpp
|
||||
DatabaseOrdinary.cpp
|
||||
DatabaseReplicated.cpp
|
||||
DatabaseReplicatedSettings.cpp
|
||||
DatabaseReplicatedWorker.cpp
|
||||
DatabasesCommon.cpp
|
||||
MySQL/ConnectionMySQLSettings.cpp
|
||||
MySQL/DatabaseMaterializedMySQL.cpp
|
||||
MySQL/DatabaseMySQL.cpp
|
||||
MySQL/FetchTablesColumnsList.cpp
|
||||
MySQL/MaterializeMetadata.cpp
|
||||
MySQL/MaterializedMySQLSettings.cpp
|
||||
MySQL/MaterializedMySQLSyncThread.cpp
|
||||
SQLite/DatabaseSQLite.cpp
|
||||
SQLite/SQLiteUtils.cpp
|
||||
SQLite/fetchSQLiteTableStructure.cpp
|
||||
TablesLoader.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,14 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F examples | grep -v -F 'PostgreSQL' | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,22 +1,17 @@
|
||||
#pragma once
|
||||
|
||||
|
||||
#include <Core/Names.h>
|
||||
#include <DataStreams/IBlockStream_fwd.h>
|
||||
#include <Interpreters/IExternalLoadable.h>
|
||||
#include <Interpreters/StorageID.h>
|
||||
#include <Poco/Util/XMLConfiguration.h>
|
||||
#include <Common/PODArray.h>
|
||||
#include <common/StringRef.h>
|
||||
#include "IDictionarySource.h"
|
||||
#include <Columns/ColumnsNumber.h>
|
||||
#include <Dictionaries/IDictionarySource.h>
|
||||
#include <Dictionaries/DictionaryStructure.h>
|
||||
#include <DataTypes/IDataType.h>
|
||||
#include <Columns/ColumnsNumber.h>
|
||||
|
||||
#include <chrono>
|
||||
#include <memory>
|
||||
#include <mutex>
|
||||
|
||||
|
||||
namespace DB
|
||||
{
|
||||
namespace ErrorCodes
|
||||
|
@ -28,12 +28,14 @@ namespace ErrorCodes
|
||||
extern const int INCORRECT_DICTIONARY_DEFINITION;
|
||||
}
|
||||
|
||||
|
||||
/// There are a lot of code, but it's very simple and straightforward
|
||||
/// We just convert
|
||||
/// We just perform conversion.
|
||||
namespace
|
||||
{
|
||||
|
||||
using NamesToTypeNames = std::unordered_map<std::string, std::string>;
|
||||
|
||||
/// Get value from field and convert it to string.
|
||||
/// Also remove quotes from strings.
|
||||
String getFieldAsString(const Field & field)
|
||||
@ -46,8 +48,8 @@ String getFieldAsString(const Field & field)
|
||||
|
||||
using namespace Poco;
|
||||
using namespace Poco::XML;
|
||||
/*
|
||||
* Transforms next definition
|
||||
|
||||
/* Transforms next definition
|
||||
* LIFETIME(MIN 10, MAX 100)
|
||||
* to the next configuration
|
||||
* <lifetime>
|
||||
@ -76,8 +78,7 @@ void buildLifetimeConfiguration(
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* Transforms next definition
|
||||
/* Transforms next definition
|
||||
* LAYOUT(FLAT())
|
||||
* to the next configuration
|
||||
* <layout>
|
||||
@ -104,6 +105,7 @@ void buildLayoutConfiguration(
|
||||
layout_element->appendChild(layout_type_element);
|
||||
|
||||
if (layout->parameters)
|
||||
{
|
||||
for (const auto & param : layout->parameters->children)
|
||||
{
|
||||
const ASTPair * pair = param->as<ASTPair>();
|
||||
@ -136,10 +138,11 @@ void buildLayoutConfiguration(
|
||||
layout_type_parameter_element->appendChild(value_to_append);
|
||||
layout_type_element->appendChild(layout_type_parameter_element);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* Transforms next definition
|
||||
|
||||
/* Transforms next definition
|
||||
* RANGE(MIN StartDate, MAX EndDate)
|
||||
* to the next configuration
|
||||
* <range_min><name>StartDate</name></range_min>
|
||||
@ -216,8 +219,7 @@ void buildAttributeExpressionIfNeeded(
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Transofrms single dictionary attribute to configuration
|
||||
/** Transofrms single dictionary attribute to configuration
|
||||
* third_column UInt8 DEFAULT 2 EXPRESSION rand() % 100 * 77
|
||||
* to
|
||||
* <attribute>
|
||||
@ -281,8 +283,7 @@ void buildSingleAttribute(
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Transforms
|
||||
/** Transforms
|
||||
* PRIMARY KEY Attr1 ,..., AttrN
|
||||
* to the next configuration
|
||||
* <id><name>Attr1</name></id>
|
||||
@ -369,8 +370,7 @@ void buildPrimaryKeyConfiguration(
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Transforms list of ASTDictionaryAttributeDeclarations to list of dictionary attributes
|
||||
/** Transforms list of ASTDictionaryAttributeDeclarations to list of dictionary attributes
|
||||
*/
|
||||
NamesToTypeNames buildDictionaryAttributesConfiguration(
|
||||
AutoPtr<Document> doc,
|
||||
|
@ -1,72 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/poco/Data
|
||||
contrib/libs/poco/MongoDB
|
||||
contrib/libs/poco/Redis
|
||||
contrib/libs/sparsehash
|
||||
contrib/restricted/abseil-cpp
|
||||
)
|
||||
|
||||
IF (USE_ODBC)
|
||||
PEERDIR(contrib/libs/poco/Data/ODBC)
|
||||
ENDIF ()
|
||||
|
||||
NO_COMPILER_WARNINGS()
|
||||
|
||||
|
||||
SRCS(
|
||||
CacheDictionary.cpp
|
||||
CacheDictionaryUpdateQueue.cpp
|
||||
CassandraDictionarySource.cpp
|
||||
CassandraHelpers.cpp
|
||||
CassandraSource.cpp
|
||||
ClickHouseDictionarySource.cpp
|
||||
DictionaryFactory.cpp
|
||||
DictionaryHelpers.cpp
|
||||
DictionarySource.cpp
|
||||
DictionarySourceBase.cpp
|
||||
DictionarySourceFactory.cpp
|
||||
DictionarySourceHelpers.cpp
|
||||
DictionaryStructure.cpp
|
||||
DirectDictionary.cpp
|
||||
Embedded/GeoDictionariesLoader.cpp
|
||||
Embedded/GeodataProviders/HierarchiesProvider.cpp
|
||||
Embedded/GeodataProviders/HierarchyFormatReader.cpp
|
||||
Embedded/GeodataProviders/NamesFormatReader.cpp
|
||||
Embedded/GeodataProviders/NamesProvider.cpp
|
||||
Embedded/RegionsHierarchies.cpp
|
||||
Embedded/RegionsHierarchy.cpp
|
||||
Embedded/RegionsNames.cpp
|
||||
ExecutableDictionarySource.cpp
|
||||
ExecutablePoolDictionarySource.cpp
|
||||
ExternalQueryBuilder.cpp
|
||||
FileDictionarySource.cpp
|
||||
FlatDictionary.cpp
|
||||
HTTPDictionarySource.cpp
|
||||
HashedDictionary.cpp
|
||||
HierarchyDictionariesUtils.cpp
|
||||
IPAddressDictionary.cpp
|
||||
LibraryDictionarySource.cpp
|
||||
MongoDBDictionarySource.cpp
|
||||
MySQLDictionarySource.cpp
|
||||
PolygonDictionary.cpp
|
||||
PolygonDictionaryImplementations.cpp
|
||||
PolygonDictionaryUtils.cpp
|
||||
RangeHashedDictionary.cpp
|
||||
RedisDictionarySource.cpp
|
||||
RedisSource.cpp
|
||||
XDBCDictionarySource.cpp
|
||||
getDictionaryConfigurationFromAST.cpp
|
||||
readInvalidateQuery.cpp
|
||||
registerCacheDictionaries.cpp
|
||||
registerDictionaries.cpp
|
||||
writeParenthesisedString.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,25 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/poco/Data
|
||||
contrib/libs/poco/MongoDB
|
||||
contrib/libs/poco/Redis
|
||||
contrib/libs/sparsehash
|
||||
contrib/restricted/abseil-cpp
|
||||
)
|
||||
|
||||
IF (USE_ODBC)
|
||||
PEERDIR(contrib/libs/poco/Data/ODBC)
|
||||
ENDIF ()
|
||||
|
||||
NO_COMPILER_WARNINGS()
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -P 'tests|PostgreSQL' | grep -v -F examples | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -185,7 +185,7 @@ private:
|
||||
|
||||
struct FileData
|
||||
{
|
||||
FileType type;
|
||||
FileType type{};
|
||||
size_t size = 0;
|
||||
};
|
||||
|
||||
|
@ -1,17 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
DiskS3.cpp
|
||||
registerDiskS3.cpp
|
||||
ProxyListConfiguration.cpp
|
||||
ProxyResolverConfiguration.cpp
|
||||
)
|
||||
|
||||
END()
|
@ -1,37 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
SRCS(
|
||||
DiskCacheWrapper.cpp
|
||||
DiskDecorator.cpp
|
||||
DiskEncrypted.cpp
|
||||
DiskFactory.cpp
|
||||
DiskLocal.cpp
|
||||
DiskMemory.cpp
|
||||
DiskRestartProxy.cpp
|
||||
DiskSelector.cpp
|
||||
DiskWebServer.cpp
|
||||
IDisk.cpp
|
||||
IDiskRemote.cpp
|
||||
IVolume.cpp
|
||||
LocalDirectorySyncGuard.cpp
|
||||
ReadIndirectBufferFromRemoteFS.cpp
|
||||
ReadIndirectBufferFromWebServer.cpp
|
||||
SingleDiskVolume.cpp
|
||||
StoragePolicy.cpp
|
||||
TemporaryFileOnDisk.cpp
|
||||
VolumeJBOD.cpp
|
||||
VolumeRAID1.cpp
|
||||
WriteIndirectBufferFromRemoteFS.cpp
|
||||
createVolume.cpp
|
||||
registerDisks.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,13 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | grep -v -P 'S3|HDFS' | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,30 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/protobuf
|
||||
contrib/libs/protoc
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
FormatFactory.cpp
|
||||
FormatSchemaInfo.cpp
|
||||
JSONEachRowUtils.cpp
|
||||
MySQLSource.cpp
|
||||
NativeFormat.cpp
|
||||
NullFormat.cpp
|
||||
ParsedTemplateFormatString.cpp
|
||||
ProtobufReader.cpp
|
||||
ProtobufSchemas.cpp
|
||||
ProtobufSerializer.cpp
|
||||
ProtobufWriter.cpp
|
||||
registerFormats.cpp
|
||||
verbosePrintString.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,16 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/protobuf
|
||||
contrib/libs/protoc
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,591 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
CFLAGS(
|
||||
-DUSE_SSL -DUSE_XXHASH
|
||||
)
|
||||
|
||||
ADDINCL(
|
||||
library/cpp/consistent_hashing
|
||||
contrib/libs/farmhash
|
||||
contrib/libs/h3/h3lib/include
|
||||
contrib/libs/hyperscan/src
|
||||
contrib/libs/libdivide
|
||||
contrib/libs/rapidjson/include
|
||||
contrib/libs/xxhash
|
||||
GLOBAL contrib/restricted/murmurhash
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
clickhouse/src/Parsers
|
||||
clickhouse/src/Dictionaries
|
||||
contrib/libs/farmhash
|
||||
contrib/libs/fastops/fastops
|
||||
contrib/libs/h3
|
||||
contrib/libs/hyperscan
|
||||
contrib/libs/icu
|
||||
contrib/libs/libdivide
|
||||
contrib/libs/metrohash
|
||||
contrib/libs/rapidjson
|
||||
contrib/libs/xxhash
|
||||
contrib/restricted/murmurhash
|
||||
library/cpp/consistent_hashing
|
||||
)
|
||||
|
||||
# "Arcadia" build is slightly deficient. It lacks many libraries that we need.
|
||||
|
||||
SRCS(
|
||||
CRC.cpp
|
||||
CastOverloadResolver.cpp
|
||||
DateOrDateTimeFunctionsConvertion.cpp
|
||||
FunctionChar.cpp
|
||||
FunctionFQDN.cpp
|
||||
FunctionFactory.cpp
|
||||
FunctionFile.cpp
|
||||
FunctionHelpers.cpp
|
||||
FunctionJoinGet.cpp
|
||||
FunctionSQLJSON.cpp
|
||||
FunctionsAES.cpp
|
||||
FunctionsBinaryRepr.cpp
|
||||
FunctionsBitToArray.cpp
|
||||
FunctionsCodingIP.cpp
|
||||
FunctionsCodingUUID.cpp
|
||||
FunctionsConversion.cpp
|
||||
FunctionsEmbeddedDictionaries.cpp
|
||||
FunctionsExternalDictionaries.cpp
|
||||
FunctionsExternalModels.cpp
|
||||
FunctionsHashing.cpp
|
||||
FunctionsJSON.cpp
|
||||
FunctionsLogical.cpp
|
||||
FunctionsRandom.cpp
|
||||
FunctionsRound.cpp
|
||||
FunctionsStringArray.cpp
|
||||
FunctionsStringHash.cpp
|
||||
FunctionsStringSimilarity.cpp
|
||||
GatherUtils/concat.cpp
|
||||
GatherUtils/createArraySink.cpp
|
||||
GatherUtils/createArraySource.cpp
|
||||
GatherUtils/createValueSource.cpp
|
||||
GatherUtils/has_all.cpp
|
||||
GatherUtils/has_any.cpp
|
||||
GatherUtils/has_substr.cpp
|
||||
GatherUtils/push.cpp
|
||||
GatherUtils/resizeConstantSize.cpp
|
||||
GatherUtils/resizeDynamicSize.cpp
|
||||
GatherUtils/sliceDynamicOffsetBounded.cpp
|
||||
GatherUtils/sliceDynamicOffsetUnbounded.cpp
|
||||
GatherUtils/sliceFromLeftConstantOffsetBounded.cpp
|
||||
GatherUtils/sliceFromLeftConstantOffsetUnbounded.cpp
|
||||
GatherUtils/sliceFromRightConstantOffsetBounded.cpp
|
||||
GatherUtils/sliceFromRightConstantOffsetUnbounded.cpp
|
||||
GeoHash.cpp
|
||||
IFunction.cpp
|
||||
JSONPath/Parsers/ParserJSONPath.cpp
|
||||
JSONPath/Parsers/ParserJSONPathMemberAccess.cpp
|
||||
JSONPath/Parsers/ParserJSONPathQuery.cpp
|
||||
JSONPath/Parsers/ParserJSONPathRange.cpp
|
||||
JSONPath/Parsers/ParserJSONPathRoot.cpp
|
||||
JSONPath/Parsers/ParserJSONPathStar.cpp
|
||||
TargetSpecific.cpp
|
||||
URL/URLHierarchy.cpp
|
||||
URL/URLPathHierarchy.cpp
|
||||
URL/basename.cpp
|
||||
URL/cutFragment.cpp
|
||||
URL/cutQueryString.cpp
|
||||
URL/cutQueryStringAndFragment.cpp
|
||||
URL/cutToFirstSignificantSubdomain.cpp
|
||||
URL/cutToFirstSignificantSubdomainCustom.cpp
|
||||
URL/cutURLParameter.cpp
|
||||
URL/cutWWW.cpp
|
||||
URL/decodeURLComponent.cpp
|
||||
URL/domain.cpp
|
||||
URL/domainWithoutWWW.cpp
|
||||
URL/extractURLParameter.cpp
|
||||
URL/extractURLParameterNames.cpp
|
||||
URL/extractURLParameters.cpp
|
||||
URL/firstSignificantSubdomain.cpp
|
||||
URL/firstSignificantSubdomainCustom.cpp
|
||||
URL/fragment.cpp
|
||||
URL/netloc.cpp
|
||||
URL/path.cpp
|
||||
URL/pathFull.cpp
|
||||
URL/port.cpp
|
||||
URL/protocol.cpp
|
||||
URL/queryString.cpp
|
||||
URL/queryStringAndFragment.cpp
|
||||
URL/registerFunctionsURL.cpp
|
||||
URL/tldLookup.generated.cpp
|
||||
URL/topLevelDomain.cpp
|
||||
abs.cpp
|
||||
acos.cpp
|
||||
acosh.cpp
|
||||
addDays.cpp
|
||||
addHours.cpp
|
||||
addMinutes.cpp
|
||||
addMonths.cpp
|
||||
addQuarters.cpp
|
||||
addSeconds.cpp
|
||||
addWeeks.cpp
|
||||
addYears.cpp
|
||||
addressToLine.cpp
|
||||
addressToSymbol.cpp
|
||||
aes_decrypt_mysql.cpp
|
||||
aes_encrypt_mysql.cpp
|
||||
appendTrailingCharIfAbsent.cpp
|
||||
array/array.cpp
|
||||
array/arrayAUC.cpp
|
||||
array/arrayAggregation.cpp
|
||||
array/arrayAll.cpp
|
||||
array/arrayCompact.cpp
|
||||
array/arrayConcat.cpp
|
||||
array/arrayCount.cpp
|
||||
array/arrayCumSum.cpp
|
||||
array/arrayCumSumNonNegative.cpp
|
||||
array/arrayDifference.cpp
|
||||
array/arrayDistinct.cpp
|
||||
array/arrayElement.cpp
|
||||
array/arrayEnumerate.cpp
|
||||
array/arrayEnumerateDense.cpp
|
||||
array/arrayEnumerateDenseRanked.cpp
|
||||
array/arrayEnumerateRanked.cpp
|
||||
array/arrayEnumerateUniq.cpp
|
||||
array/arrayEnumerateUniqRanked.cpp
|
||||
array/arrayExists.cpp
|
||||
array/arrayFill.cpp
|
||||
array/arrayFilter.cpp
|
||||
array/arrayFirst.cpp
|
||||
array/arrayFirstIndex.cpp
|
||||
array/arrayFlatten.cpp
|
||||
array/arrayIntersect.cpp
|
||||
array/arrayJoin.cpp
|
||||
array/arrayMap.cpp
|
||||
array/arrayPopBack.cpp
|
||||
array/arrayPopFront.cpp
|
||||
array/arrayPushBack.cpp
|
||||
array/arrayPushFront.cpp
|
||||
array/arrayReduce.cpp
|
||||
array/arrayReduceInRanges.cpp
|
||||
array/arrayResize.cpp
|
||||
array/arrayReverse.cpp
|
||||
array/arraySlice.cpp
|
||||
array/arraySort.cpp
|
||||
array/arraySplit.cpp
|
||||
array/arrayUniq.cpp
|
||||
array/arrayWithConstant.cpp
|
||||
array/arrayZip.cpp
|
||||
array/countEqual.cpp
|
||||
array/emptyArray.cpp
|
||||
array/emptyArrayToSingle.cpp
|
||||
array/has.cpp
|
||||
array/hasAll.cpp
|
||||
array/hasAny.cpp
|
||||
array/hasSubstr.cpp
|
||||
array/indexOf.cpp
|
||||
array/length.cpp
|
||||
array/mapOp.cpp
|
||||
array/mapPopulateSeries.cpp
|
||||
array/range.cpp
|
||||
array/registerFunctionsArray.cpp
|
||||
asin.cpp
|
||||
asinh.cpp
|
||||
assumeNotNull.cpp
|
||||
atan.cpp
|
||||
atan2.cpp
|
||||
atanh.cpp
|
||||
bar.cpp
|
||||
base64Decode.cpp
|
||||
base64Encode.cpp
|
||||
bitAnd.cpp
|
||||
bitBoolMaskAnd.cpp
|
||||
bitBoolMaskOr.cpp
|
||||
bitCount.cpp
|
||||
bitHammingDistance.cpp
|
||||
bitNot.cpp
|
||||
bitOr.cpp
|
||||
bitRotateLeft.cpp
|
||||
bitRotateRight.cpp
|
||||
bitShiftLeft.cpp
|
||||
bitShiftRight.cpp
|
||||
bitSwapLastTwo.cpp
|
||||
bitTest.cpp
|
||||
bitTestAll.cpp
|
||||
bitTestAny.cpp
|
||||
bitWrapperFunc.cpp
|
||||
bitXor.cpp
|
||||
blockNumber.cpp
|
||||
blockSerializedSize.cpp
|
||||
blockSize.cpp
|
||||
byteSize.cpp
|
||||
caseWithExpression.cpp
|
||||
cbrt.cpp
|
||||
coalesce.cpp
|
||||
concat.cpp
|
||||
connectionId.cpp
|
||||
convertCharset.cpp
|
||||
cos.cpp
|
||||
cosh.cpp
|
||||
countDigits.cpp
|
||||
countMatches.cpp
|
||||
countSubstrings.cpp
|
||||
countSubstringsCaseInsensitive.cpp
|
||||
countSubstringsCaseInsensitiveUTF8.cpp
|
||||
currentDatabase.cpp
|
||||
currentProfiles.cpp
|
||||
currentRoles.cpp
|
||||
currentUser.cpp
|
||||
dateDiff.cpp
|
||||
dateName.cpp
|
||||
date_trunc.cpp
|
||||
decodeXMLComponent.cpp
|
||||
decrypt.cpp
|
||||
defaultValueOfArgumentType.cpp
|
||||
defaultValueOfTypeName.cpp
|
||||
demange.cpp
|
||||
divide.cpp
|
||||
divide/divide.cpp
|
||||
divide/divideImpl.cpp
|
||||
dumpColumnStructure.cpp
|
||||
empty.cpp
|
||||
encodeXMLComponent.cpp
|
||||
encrypt.cpp
|
||||
endsWith.cpp
|
||||
equals.cpp
|
||||
erf.cpp
|
||||
erfc.cpp
|
||||
errorCodeToName.cpp
|
||||
evalMLMethod.cpp
|
||||
exp.cpp
|
||||
exp10.cpp
|
||||
exp2.cpp
|
||||
extract.cpp
|
||||
extractAllGroupsHorizontal.cpp
|
||||
extractAllGroupsVertical.cpp
|
||||
extractGroups.cpp
|
||||
extractTextFromHTML.cpp
|
||||
extractTimeZoneFromFunctionArguments.cpp
|
||||
filesystem.cpp
|
||||
finalizeAggregation.cpp
|
||||
formatDateTime.cpp
|
||||
formatReadableQuantity.cpp
|
||||
formatReadableSize.cpp
|
||||
formatReadableTimeDelta.cpp
|
||||
formatRow.cpp
|
||||
formatString.cpp
|
||||
fromModifiedJulianDay.cpp
|
||||
fromUnixTimestamp64Micro.cpp
|
||||
fromUnixTimestamp64Milli.cpp
|
||||
fromUnixTimestamp64Nano.cpp
|
||||
fuzzBits.cpp
|
||||
gcd.cpp
|
||||
generateUUIDv4.cpp
|
||||
geoToH3.cpp
|
||||
geoToS2.cpp
|
||||
geohashDecode.cpp
|
||||
geohashEncode.cpp
|
||||
geohashesInBox.cpp
|
||||
getMacro.cpp
|
||||
getScalar.cpp
|
||||
getServerPort.cpp
|
||||
getSetting.cpp
|
||||
getSizeOfEnumType.cpp
|
||||
globalVariable.cpp
|
||||
greatCircleDistance.cpp
|
||||
greater.cpp
|
||||
greaterOrEquals.cpp
|
||||
greatest.cpp
|
||||
h3EdgeAngle.cpp
|
||||
h3EdgeLengthM.cpp
|
||||
h3GetBaseCell.cpp
|
||||
h3GetFaces.cpp
|
||||
h3GetResolution.cpp
|
||||
h3HexAreaM2.cpp
|
||||
h3IndexesAreNeighbors.cpp
|
||||
h3IsPentagon.cpp
|
||||
h3IsValid.cpp
|
||||
h3ResIsClassIII.cpp
|
||||
h3ToChildren.cpp
|
||||
h3ToGeoBoundary.cpp
|
||||
h3ToParent.cpp
|
||||
h3ToString.cpp
|
||||
h3kRing.cpp
|
||||
h3toGeo.cpp
|
||||
hasColumnInTable.cpp
|
||||
hasThreadFuzzer.cpp
|
||||
hasToken.cpp
|
||||
hasTokenCaseInsensitive.cpp
|
||||
hyperscanRegexpChecker.cpp
|
||||
hypot.cpp
|
||||
identity.cpp
|
||||
if.cpp
|
||||
ifNotFinite.cpp
|
||||
ifNull.cpp
|
||||
ignore.cpp
|
||||
ilike.cpp
|
||||
in.cpp
|
||||
indexHint.cpp
|
||||
initialQueryID.cpp
|
||||
initializeAggregation.cpp
|
||||
intDiv.cpp
|
||||
intDivOrZero.cpp
|
||||
intExp10.cpp
|
||||
intExp2.cpp
|
||||
isConstant.cpp
|
||||
isDecimalOverflow.cpp
|
||||
isFinite.cpp
|
||||
isIPAddressContainedIn.cpp
|
||||
isInfinite.cpp
|
||||
isNaN.cpp
|
||||
isNotNull.cpp
|
||||
isNull.cpp
|
||||
isValidUTF8.cpp
|
||||
isZeroOrNull.cpp
|
||||
jumpConsistentHash.cpp
|
||||
lcm.cpp
|
||||
least.cpp
|
||||
lemmatize.cpp
|
||||
lengthUTF8.cpp
|
||||
less.cpp
|
||||
lessOrEquals.cpp
|
||||
lgamma.cpp
|
||||
like.cpp
|
||||
log.cpp
|
||||
log10.cpp
|
||||
log1p.cpp
|
||||
log2.cpp
|
||||
logTrace.cpp
|
||||
lowCardinalityIndices.cpp
|
||||
lowCardinalityKeys.cpp
|
||||
lower.cpp
|
||||
lowerUTF8.cpp
|
||||
map.cpp
|
||||
match.cpp
|
||||
materialize.cpp
|
||||
mathConstants.cpp
|
||||
minus.cpp
|
||||
modulo.cpp
|
||||
moduloOrZero.cpp
|
||||
multiFuzzyMatchAllIndices.cpp
|
||||
multiFuzzyMatchAny.cpp
|
||||
multiFuzzyMatchAnyIndex.cpp
|
||||
multiIf.cpp
|
||||
multiMatchAllIndices.cpp
|
||||
multiMatchAny.cpp
|
||||
multiMatchAnyIndex.cpp
|
||||
multiSearchAllPositions.cpp
|
||||
multiSearchAllPositionsCaseInsensitive.cpp
|
||||
multiSearchAllPositionsCaseInsensitiveUTF8.cpp
|
||||
multiSearchAllPositionsUTF8.cpp
|
||||
multiSearchAny.cpp
|
||||
multiSearchAnyCaseInsensitive.cpp
|
||||
multiSearchAnyCaseInsensitiveUTF8.cpp
|
||||
multiSearchAnyUTF8.cpp
|
||||
multiSearchFirstIndex.cpp
|
||||
multiSearchFirstIndexCaseInsensitive.cpp
|
||||
multiSearchFirstIndexCaseInsensitiveUTF8.cpp
|
||||
multiSearchFirstIndexUTF8.cpp
|
||||
multiSearchFirstPosition.cpp
|
||||
multiSearchFirstPositionCaseInsensitive.cpp
|
||||
multiSearchFirstPositionCaseInsensitiveUTF8.cpp
|
||||
multiSearchFirstPositionUTF8.cpp
|
||||
multiply.cpp
|
||||
negate.cpp
|
||||
neighbor.cpp
|
||||
normalizeQuery.cpp
|
||||
normalizedQueryHash.cpp
|
||||
notEmpty.cpp
|
||||
notEquals.cpp
|
||||
notILike.cpp
|
||||
notLike.cpp
|
||||
now.cpp
|
||||
now64.cpp
|
||||
nullIf.cpp
|
||||
padString.cpp
|
||||
partitionId.cpp
|
||||
plus.cpp
|
||||
pointInEllipses.cpp
|
||||
pointInPolygon.cpp
|
||||
polygonArea.cpp
|
||||
polygonConvexHull.cpp
|
||||
polygonPerimeter.cpp
|
||||
polygonsDistance.cpp
|
||||
polygonsEquals.cpp
|
||||
polygonsIntersection.cpp
|
||||
polygonsSymDifference.cpp
|
||||
polygonsUnion.cpp
|
||||
polygonsWithin.cpp
|
||||
position.cpp
|
||||
positionCaseInsensitive.cpp
|
||||
positionCaseInsensitiveUTF8.cpp
|
||||
positionUTF8.cpp
|
||||
pow.cpp
|
||||
queryID.cpp
|
||||
rand.cpp
|
||||
rand64.cpp
|
||||
randConstant.cpp
|
||||
randomFixedString.cpp
|
||||
randomPrintableASCII.cpp
|
||||
randomString.cpp
|
||||
randomStringUTF8.cpp
|
||||
readWkt.cpp
|
||||
regexpQuoteMeta.cpp
|
||||
registerFunctions.cpp
|
||||
registerFunctionsArithmetic.cpp
|
||||
registerFunctionsComparison.cpp
|
||||
registerFunctionsConditional.cpp
|
||||
registerFunctionsConsistentHashing.cpp
|
||||
registerFunctionsDateTime.cpp
|
||||
registerFunctionsFormatting.cpp
|
||||
registerFunctionsGeo.cpp
|
||||
registerFunctionsHigherOrder.cpp
|
||||
registerFunctionsIntrospection.cpp
|
||||
registerFunctionsMath.cpp
|
||||
registerFunctionsMiscellaneous.cpp
|
||||
registerFunctionsNull.cpp
|
||||
registerFunctionsRandom.cpp
|
||||
registerFunctionsReinterpret.cpp
|
||||
registerFunctionsSnowflake.cpp
|
||||
registerFunctionsString.cpp
|
||||
registerFunctionsStringRegexp.cpp
|
||||
registerFunctionsStringSearch.cpp
|
||||
registerFunctionsTuple.cpp
|
||||
registerFunctionsUnixTimestamp64.cpp
|
||||
registerFunctionsVisitParam.cpp
|
||||
reinterpretAs.cpp
|
||||
repeat.cpp
|
||||
replaceAll.cpp
|
||||
replaceOne.cpp
|
||||
replaceRegexpAll.cpp
|
||||
replaceRegexpOne.cpp
|
||||
replicate.cpp
|
||||
reverse.cpp
|
||||
reverseUTF8.cpp
|
||||
roundAge.cpp
|
||||
roundDuration.cpp
|
||||
roundToExp2.cpp
|
||||
rowNumberInAllBlocks.cpp
|
||||
rowNumberInBlock.cpp
|
||||
runningAccumulate.cpp
|
||||
runningConcurrency.cpp
|
||||
runningDifference.cpp
|
||||
runningDifferenceStartingWithFirstValue.cpp
|
||||
s2CapContains.cpp
|
||||
s2CapUnion.cpp
|
||||
s2CellsIntersect.cpp
|
||||
s2GetNeighbors.cpp
|
||||
s2RectAdd.cpp
|
||||
s2RectContains.cpp
|
||||
s2RectIntersection.cpp
|
||||
s2RectUnion.cpp
|
||||
s2ToGeo.cpp
|
||||
serverConstants.cpp
|
||||
sigmoid.cpp
|
||||
sign.cpp
|
||||
sin.cpp
|
||||
sinh.cpp
|
||||
sleep.cpp
|
||||
sleepEachRow.cpp
|
||||
snowflake.cpp
|
||||
sqrt.cpp
|
||||
startsWith.cpp
|
||||
stem.cpp
|
||||
stringCutToZero.cpp
|
||||
stringToH3.cpp
|
||||
substring.cpp
|
||||
subtractDays.cpp
|
||||
subtractHours.cpp
|
||||
subtractMinutes.cpp
|
||||
subtractMonths.cpp
|
||||
subtractQuarters.cpp
|
||||
subtractSeconds.cpp
|
||||
subtractWeeks.cpp
|
||||
subtractYears.cpp
|
||||
svg.cpp
|
||||
synonyms.cpp
|
||||
tan.cpp
|
||||
tanh.cpp
|
||||
tgamma.cpp
|
||||
throwIf.cpp
|
||||
tid.cpp
|
||||
timeSlot.cpp
|
||||
timeSlots.cpp
|
||||
timezoneOf.cpp
|
||||
timezoneOffset.cpp
|
||||
toColumnTypeName.cpp
|
||||
toCustomWeek.cpp
|
||||
toDayOfMonth.cpp
|
||||
toDayOfWeek.cpp
|
||||
toDayOfYear.cpp
|
||||
toFixedString.cpp
|
||||
toHour.cpp
|
||||
toISOWeek.cpp
|
||||
toISOYear.cpp
|
||||
toJSONString.cpp
|
||||
toLowCardinality.cpp
|
||||
toMinute.cpp
|
||||
toModifiedJulianDay.cpp
|
||||
toMonday.cpp
|
||||
toMonth.cpp
|
||||
toNullable.cpp
|
||||
toQuarter.cpp
|
||||
toRelativeDayNum.cpp
|
||||
toRelativeHourNum.cpp
|
||||
toRelativeMinuteNum.cpp
|
||||
toRelativeMonthNum.cpp
|
||||
toRelativeQuarterNum.cpp
|
||||
toRelativeSecondNum.cpp
|
||||
toRelativeWeekNum.cpp
|
||||
toRelativeYearNum.cpp
|
||||
toSecond.cpp
|
||||
toStartOfDay.cpp
|
||||
toStartOfFifteenMinutes.cpp
|
||||
toStartOfFiveMinute.cpp
|
||||
toStartOfHour.cpp
|
||||
toStartOfISOYear.cpp
|
||||
toStartOfInterval.cpp
|
||||
toStartOfMinute.cpp
|
||||
toStartOfMonth.cpp
|
||||
toStartOfQuarter.cpp
|
||||
toStartOfSecond.cpp
|
||||
toStartOfTenMinutes.cpp
|
||||
toStartOfYear.cpp
|
||||
toTime.cpp
|
||||
toTimezone.cpp
|
||||
toTypeName.cpp
|
||||
toUnixTimestamp64Micro.cpp
|
||||
toUnixTimestamp64Milli.cpp
|
||||
toUnixTimestamp64Nano.cpp
|
||||
toValidUTF8.cpp
|
||||
toYYYYMM.cpp
|
||||
toYYYYMMDD.cpp
|
||||
toYYYYMMDDhhmmss.cpp
|
||||
toYear.cpp
|
||||
today.cpp
|
||||
transform.cpp
|
||||
trap.cpp
|
||||
trim.cpp
|
||||
tryBase64Decode.cpp
|
||||
tuple.cpp
|
||||
tupleElement.cpp
|
||||
tupleHammingDistance.cpp
|
||||
tupleToNameValuePairs.cpp
|
||||
upper.cpp
|
||||
upperUTF8.cpp
|
||||
validateNestedArraySizes.cpp
|
||||
visibleWidth.cpp
|
||||
visitParamExtractBool.cpp
|
||||
visitParamExtractFloat.cpp
|
||||
visitParamExtractInt.cpp
|
||||
visitParamExtractRaw.cpp
|
||||
visitParamExtractString.cpp
|
||||
visitParamExtractUInt.cpp
|
||||
visitParamHas.cpp
|
||||
wkt.cpp
|
||||
yandexConsistentHash.cpp
|
||||
yesterday.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,43 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
CFLAGS(
|
||||
-DUSE_SSL -DUSE_XXHASH
|
||||
)
|
||||
|
||||
ADDINCL(
|
||||
library/cpp/consistent_hashing
|
||||
contrib/libs/farmhash
|
||||
contrib/libs/h3/h3lib/include
|
||||
contrib/libs/hyperscan/src
|
||||
contrib/libs/libdivide
|
||||
contrib/libs/rapidjson/include
|
||||
contrib/libs/xxhash
|
||||
GLOBAL contrib/restricted/murmurhash
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
clickhouse/src/Parsers
|
||||
clickhouse/src/Dictionaries
|
||||
contrib/libs/farmhash
|
||||
contrib/libs/fastops/fastops
|
||||
contrib/libs/h3
|
||||
contrib/libs/hyperscan
|
||||
contrib/libs/icu
|
||||
contrib/libs/libdivide
|
||||
contrib/libs/metrohash
|
||||
contrib/libs/rapidjson
|
||||
contrib/libs/xxhash
|
||||
contrib/restricted/murmurhash
|
||||
library/cpp/consistent_hashing
|
||||
)
|
||||
|
||||
# "Arcadia" build is slightly deficient. It lacks many libraries that we need.
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -i -v -P 'tests|Bitmap|abtesting' | grep -v -F examples | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,92 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL(
|
||||
contrib/libs/zstd/include
|
||||
contrib/libs/lz4
|
||||
contrib/restricted/fast_float/include
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/brotli/dec
|
||||
contrib/libs/brotli/enc
|
||||
contrib/libs/poco/NetSSL_OpenSSL
|
||||
contrib/libs/zstd
|
||||
contrib/libs/lz4
|
||||
contrib/restricted/fast_float
|
||||
)
|
||||
|
||||
SRCS(
|
||||
AIO.cpp
|
||||
AsynchronousReadBufferFromFile.cpp
|
||||
AsynchronousReadBufferFromFileDescriptor.cpp
|
||||
BrotliReadBuffer.cpp
|
||||
BrotliWriteBuffer.cpp
|
||||
Bzip2ReadBuffer.cpp
|
||||
Bzip2WriteBuffer.cpp
|
||||
CascadeWriteBuffer.cpp
|
||||
CompressionMethod.cpp
|
||||
DoubleConverter.cpp
|
||||
FileEncryptionCommon.cpp
|
||||
HTTPChunkedReadBuffer.cpp
|
||||
HTTPCommon.cpp
|
||||
HashingWriteBuffer.cpp
|
||||
LZMADeflatingWriteBuffer.cpp
|
||||
LZMAInflatingReadBuffer.cpp
|
||||
LimitReadBuffer.cpp
|
||||
Lz4DeflatingWriteBuffer.cpp
|
||||
Lz4InflatingReadBuffer.cpp
|
||||
MMapReadBufferFromFile.cpp
|
||||
MMapReadBufferFromFileDescriptor.cpp
|
||||
MMapReadBufferFromFileWithCache.cpp
|
||||
MMappedFile.cpp
|
||||
MMappedFileDescriptor.cpp
|
||||
MemoryReadWriteBuffer.cpp
|
||||
MySQLBinlogEventReadBuffer.cpp
|
||||
MySQLPacketPayloadReadBuffer.cpp
|
||||
MySQLPacketPayloadWriteBuffer.cpp
|
||||
NullWriteBuffer.cpp
|
||||
OpenedFile.cpp
|
||||
PeekableReadBuffer.cpp
|
||||
Progress.cpp
|
||||
ReadBufferFromEncryptedFile.cpp
|
||||
ReadBufferFromFile.cpp
|
||||
ReadBufferFromFileBase.cpp
|
||||
ReadBufferFromFileDecorator.cpp
|
||||
ReadBufferFromFileDescriptor.cpp
|
||||
ReadBufferFromIStream.cpp
|
||||
ReadBufferFromMemory.cpp
|
||||
ReadBufferFromPocoSocket.cpp
|
||||
ReadHelpers.cpp
|
||||
SeekAvoidingReadBuffer.cpp
|
||||
SynchronousReader.cpp
|
||||
ThreadPoolReader.cpp
|
||||
TimeoutSetter.cpp
|
||||
UseSSL.cpp
|
||||
WriteBufferFromEncryptedFile.cpp
|
||||
WriteBufferFromFile.cpp
|
||||
WriteBufferFromFileBase.cpp
|
||||
WriteBufferFromFileDecorator.cpp
|
||||
WriteBufferFromFileDescriptor.cpp
|
||||
WriteBufferFromFileDescriptorDiscardOnFailure.cpp
|
||||
WriteBufferFromHTTP.cpp
|
||||
WriteBufferFromOStream.cpp
|
||||
WriteBufferFromPocoSocket.cpp
|
||||
WriteBufferFromTemporaryFile.cpp
|
||||
WriteBufferValidUTF8.cpp
|
||||
WriteHelpers.cpp
|
||||
ZlibDeflatingWriteBuffer.cpp
|
||||
ZlibInflatingReadBuffer.cpp
|
||||
ZstdDeflatingWriteBuffer.cpp
|
||||
ZstdInflatingReadBuffer.cpp
|
||||
copyData.cpp
|
||||
createReadBufferFromFileBase.cpp
|
||||
parseDateTimeBestEffort.cpp
|
||||
readFloatText.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,25 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL(
|
||||
contrib/libs/zstd/include
|
||||
contrib/libs/lz4
|
||||
contrib/restricted/fast_float/include
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/brotli/dec
|
||||
contrib/libs/brotli/enc
|
||||
contrib/libs/poco/NetSSL_OpenSSL
|
||||
contrib/libs/zstd
|
||||
contrib/libs/lz4
|
||||
contrib/restricted/fast_float
|
||||
)
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | grep -v -P 'S3|HDFS' | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -283,7 +283,7 @@ private:
|
||||
/// XXX: move this stuff to shared part instead.
|
||||
ContextMutablePtr buffer_context; /// Buffer context. Could be equal to this.
|
||||
|
||||
/// A flag, used to distinguish between user query and internal query to a database engine (MaterializePostgreSQL).
|
||||
/// A flag, used to distinguish between user query and internal query to a database engine (MaterializedPostgreSQL).
|
||||
bool is_internal_query = false;
|
||||
|
||||
|
||||
|
@ -154,7 +154,9 @@ BlockIO InterpreterCreateQuery::createDatabase(ASTCreateQuery & create)
|
||||
throw Exception(ErrorCodes::UNKNOWN_DATABASE_ENGINE, "Unknown database engine: {}", serializeAST(*create.storage));
|
||||
}
|
||||
|
||||
if (create.storage->engine->name == "Atomic" || create.storage->engine->name == "Replicated" || create.storage->engine->name == "MaterializedPostgreSQL")
|
||||
if (create.storage->engine->name == "Atomic"
|
||||
|| create.storage->engine->name == "Replicated"
|
||||
|| create.storage->engine->name == "MaterializedPostgreSQL")
|
||||
{
|
||||
if (create.attach && create.uuid == UUIDHelpers::Nil)
|
||||
throw Exception(ErrorCodes::INCORRECT_QUERY, "UUID must be specified for ATTACH. "
|
||||
@ -167,7 +169,8 @@ BlockIO InterpreterCreateQuery::createDatabase(ASTCreateQuery & create)
|
||||
if (!create.attach && fs::exists(metadata_path))
|
||||
throw Exception(ErrorCodes::DATABASE_ALREADY_EXISTS, "Metadata directory {} already exists", metadata_path.string());
|
||||
}
|
||||
else if (create.storage->engine->name == "MaterializeMySQL" || create.storage->engine->name == "MaterializedMySQL")
|
||||
else if (create.storage->engine->name == "MaterializeMySQL"
|
||||
|| create.storage->engine->name == "MaterializedMySQL")
|
||||
{
|
||||
/// It creates nested database with Ordinary or Atomic engine depending on UUID in query and default engine setting.
|
||||
/// Do nothing if it's an internal ATTACH on server startup or short-syntax ATTACH query from user,
|
||||
@ -215,13 +218,17 @@ BlockIO InterpreterCreateQuery::createDatabase(ASTCreateQuery & create)
|
||||
"Enable allow_experimental_database_materialized_mysql to use it.", ErrorCodes::UNKNOWN_DATABASE_ENGINE);
|
||||
}
|
||||
|
||||
if (create.storage->engine->name == "Replicated" && !getContext()->getSettingsRef().allow_experimental_database_replicated && !internal)
|
||||
if (create.storage->engine->name == "Replicated"
|
||||
&& !getContext()->getSettingsRef().allow_experimental_database_replicated
|
||||
&& !internal)
|
||||
{
|
||||
throw Exception("Replicated is an experimental database engine. "
|
||||
"Enable allow_experimental_database_replicated to use it.", ErrorCodes::UNKNOWN_DATABASE_ENGINE);
|
||||
}
|
||||
|
||||
if (create.storage->engine->name == "MaterializedPostgreSQL" && !getContext()->getSettingsRef().allow_experimental_database_materialized_postgresql && !internal)
|
||||
if (create.storage->engine->name == "MaterializedPostgreSQL"
|
||||
&& !getContext()->getSettingsRef().allow_experimental_database_materialized_postgresql
|
||||
&& !internal)
|
||||
{
|
||||
throw Exception("MaterializedPostgreSQL is an experimental database engine. "
|
||||
"Enable allow_experimental_database_materialized_postgresql to use it.", ErrorCodes::UNKNOWN_DATABASE_ENGINE);
|
||||
@ -624,7 +631,6 @@ InterpreterCreateQuery::TableProperties InterpreterCreateQuery::getTableProperti
|
||||
else
|
||||
throw Exception("Incorrect CREATE query: required list of column descriptions or AS section or SELECT.", ErrorCodes::INCORRECT_QUERY);
|
||||
|
||||
|
||||
/// Even if query has list of columns, canonicalize it (unfold Nested columns).
|
||||
if (!create.columns_list)
|
||||
create.set(create.columns_list, std::make_shared<ASTColumns>());
|
||||
|
@ -1,199 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL(
|
||||
contrib/libs/libdivide
|
||||
contrib/libs/pdqsort
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Core
|
||||
contrib/libs/libdivide
|
||||
contrib/libs/pdqsort
|
||||
)
|
||||
|
||||
NO_COMPILER_WARNINGS()
|
||||
|
||||
|
||||
SRCS(
|
||||
ActionLocksManager.cpp
|
||||
ActionsDAG.cpp
|
||||
ActionsVisitor.cpp
|
||||
AggregateDescription.cpp
|
||||
Aggregator.cpp
|
||||
ApplyWithAliasVisitor.cpp
|
||||
ApplyWithGlobalVisitor.cpp
|
||||
ApplyWithSubqueryVisitor.cpp
|
||||
ArithmeticOperationsInAgrFuncOptimize.cpp
|
||||
ArrayJoinAction.cpp
|
||||
AsynchronousInsertQueue.cpp
|
||||
AsynchronousMetricLog.cpp
|
||||
AsynchronousMetrics.cpp
|
||||
BloomFilter.cpp
|
||||
CatBoostModel.cpp
|
||||
ClientInfo.cpp
|
||||
Cluster.cpp
|
||||
ClusterProxy/SelectStreamFactory.cpp
|
||||
ClusterProxy/executeQuery.cpp
|
||||
CollectJoinOnKeysVisitor.cpp
|
||||
ColumnAliasesVisitor.cpp
|
||||
Context.cpp
|
||||
ConvertStringsToEnumVisitor.cpp
|
||||
CrashLog.cpp
|
||||
CrossToInnerJoinVisitor.cpp
|
||||
DDLTask.cpp
|
||||
DDLWorker.cpp
|
||||
DNSCacheUpdater.cpp
|
||||
DatabaseAndTableWithAlias.cpp
|
||||
DatabaseCatalog.cpp
|
||||
DictionaryReader.cpp
|
||||
DuplicateOrderByVisitor.cpp
|
||||
EmbeddedDictionaries.cpp
|
||||
ExecuteScalarSubqueriesVisitor.cpp
|
||||
ExpressionActions.cpp
|
||||
ExpressionActionsSettings.cpp
|
||||
ExpressionAnalyzer.cpp
|
||||
ExternalDictionariesLoader.cpp
|
||||
ExternalLoader.cpp
|
||||
ExternalLoaderDictionaryStorageConfigRepository.cpp
|
||||
ExternalLoaderTempConfigRepository.cpp
|
||||
ExternalLoaderXMLConfigRepository.cpp
|
||||
ExternalModelsLoader.cpp
|
||||
ExternalUserDefinedExecutableFunctionsLoader.cpp
|
||||
ExtractExpressionInfoVisitor.cpp
|
||||
FillingRow.cpp
|
||||
FunctionNameNormalizer.cpp
|
||||
GatherFunctionQuantileVisitor.cpp
|
||||
HashJoin.cpp
|
||||
IExternalLoadable.cpp
|
||||
IInterpreter.cpp
|
||||
IInterpreterUnionOrSelectQuery.cpp
|
||||
IdentifierSemantic.cpp
|
||||
InJoinSubqueriesPreprocessor.cpp
|
||||
InternalTextLogsQueue.cpp
|
||||
InterpreterAlterQuery.cpp
|
||||
InterpreterBackupQuery.cpp
|
||||
InterpreterCheckQuery.cpp
|
||||
InterpreterCreateFunctionQuery.cpp
|
||||
InterpreterCreateQuery.cpp
|
||||
InterpreterCreateQuotaQuery.cpp
|
||||
InterpreterCreateRoleQuery.cpp
|
||||
InterpreterCreateRowPolicyQuery.cpp
|
||||
InterpreterCreateSettingsProfileQuery.cpp
|
||||
InterpreterCreateUserQuery.cpp
|
||||
InterpreterDescribeQuery.cpp
|
||||
InterpreterDropAccessEntityQuery.cpp
|
||||
InterpreterDropFunctionQuery.cpp
|
||||
InterpreterDropQuery.cpp
|
||||
InterpreterExistsQuery.cpp
|
||||
InterpreterExplainQuery.cpp
|
||||
InterpreterExternalDDLQuery.cpp
|
||||
InterpreterFactory.cpp
|
||||
InterpreterGrantQuery.cpp
|
||||
InterpreterInsertQuery.cpp
|
||||
InterpreterKillQueryQuery.cpp
|
||||
InterpreterOptimizeQuery.cpp
|
||||
InterpreterRenameQuery.cpp
|
||||
InterpreterSelectIntersectExceptQuery.cpp
|
||||
InterpreterSelectQuery.cpp
|
||||
InterpreterSelectWithUnionQuery.cpp
|
||||
InterpreterSetQuery.cpp
|
||||
InterpreterSetRoleQuery.cpp
|
||||
InterpreterShowAccessEntitiesQuery.cpp
|
||||
InterpreterShowAccessQuery.cpp
|
||||
InterpreterShowCreateAccessEntityQuery.cpp
|
||||
InterpreterShowCreateQuery.cpp
|
||||
InterpreterShowGrantsQuery.cpp
|
||||
InterpreterShowPrivilegesQuery.cpp
|
||||
InterpreterShowProcesslistQuery.cpp
|
||||
InterpreterShowTablesQuery.cpp
|
||||
InterpreterSystemQuery.cpp
|
||||
InterpreterUseQuery.cpp
|
||||
InterpreterWatchQuery.cpp
|
||||
InterserverCredentials.cpp
|
||||
JoinSwitcher.cpp
|
||||
JoinToSubqueryTransformVisitor.cpp
|
||||
JoinedTables.cpp
|
||||
Lemmatizers.cpp
|
||||
LogicalExpressionsOptimizer.cpp
|
||||
MarkTableIdentifiersVisitor.cpp
|
||||
MergeJoin.cpp
|
||||
MetricLog.cpp
|
||||
MutationsInterpreter.cpp
|
||||
MySQL/InterpretersMySQLDDLQuery.cpp
|
||||
NormalizeSelectWithUnionQueryVisitor.cpp
|
||||
NullableUtils.cpp
|
||||
OpenTelemetrySpanLog.cpp
|
||||
OptimizeIfChains.cpp
|
||||
OptimizeIfWithConstantConditionVisitor.cpp
|
||||
OptimizeShardingKeyRewriteInVisitor.cpp
|
||||
PartLog.cpp
|
||||
PredicateExpressionsOptimizer.cpp
|
||||
PredicateRewriteVisitor.cpp
|
||||
ProcessList.cpp
|
||||
ProfileEventsExt.cpp
|
||||
QueryAliasesVisitor.cpp
|
||||
QueryLog.cpp
|
||||
QueryNormalizer.cpp
|
||||
QueryParameterVisitor.cpp
|
||||
QueryThreadLog.cpp
|
||||
QueryViewsLog.cpp
|
||||
RemoveInjectiveFunctionsVisitor.cpp
|
||||
RenameColumnVisitor.cpp
|
||||
ReplaceQueryParameterVisitor.cpp
|
||||
RequiredSourceColumnsData.cpp
|
||||
RequiredSourceColumnsVisitor.cpp
|
||||
RewriteAnyFunctionVisitor.cpp
|
||||
RewriteCountVariantsVisitor.cpp
|
||||
RewriteFunctionToSubcolumnVisitor.cpp
|
||||
RewriteSumIfFunctionVisitor.cpp
|
||||
RowRefs.cpp
|
||||
SelectIntersectExceptQueryVisitor.cpp
|
||||
Session.cpp
|
||||
SessionLog.cpp
|
||||
Set.cpp
|
||||
SetVariants.cpp
|
||||
SortedBlocksWriter.cpp
|
||||
StorageID.cpp
|
||||
SubqueryForSet.cpp
|
||||
SynonymsExtensions.cpp
|
||||
SystemLog.cpp
|
||||
TableJoin.cpp
|
||||
TablesStatus.cpp
|
||||
TextLog.cpp
|
||||
ThreadStatusExt.cpp
|
||||
TraceLog.cpp
|
||||
TranslateQualifiedNamesVisitor.cpp
|
||||
TreeOptimizer.cpp
|
||||
TreeRewriter.cpp
|
||||
UserDefinedExecutableFunction.cpp
|
||||
UserDefinedExecutableFunctionFactory.cpp
|
||||
UserDefinedSQLFunctionFactory.cpp
|
||||
UserDefinedSQLFunctionVisitor.cpp
|
||||
UserDefinedSQLObjectsLoader.cpp
|
||||
WindowDescription.cpp
|
||||
ZooKeeperLog.cpp
|
||||
addMissingDefaults.cpp
|
||||
addTypeConversionToAST.cpp
|
||||
castColumn.cpp
|
||||
convertFieldToType.cpp
|
||||
createBlockSelector.cpp
|
||||
evaluateConstantExpression.cpp
|
||||
executeDDLQueryOnCluster.cpp
|
||||
executeQuery.cpp
|
||||
getClusterName.cpp
|
||||
getHeaderForProcessingStage.cpp
|
||||
getTableExpressions.cpp
|
||||
inplaceBlockConversions.cpp
|
||||
interpretSubquery.cpp
|
||||
join_common.cpp
|
||||
loadMetadata.cpp
|
||||
processColumnTransformers.cpp
|
||||
replaceAliasColumnsInQuery.cpp
|
||||
sortBlock.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,23 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
ADDINCL(
|
||||
contrib/libs/libdivide
|
||||
contrib/libs/pdqsort
|
||||
)
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Core
|
||||
contrib/libs/libdivide
|
||||
contrib/libs/pdqsort
|
||||
)
|
||||
|
||||
NO_COMPILER_WARNINGS()
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F JIT | grep -v -F examples | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,161 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
ASTAlterQuery.cpp
|
||||
ASTAsterisk.cpp
|
||||
ASTBackupQuery.cpp
|
||||
ASTColumnDeclaration.cpp
|
||||
ASTColumnsMatcher.cpp
|
||||
ASTColumnsTransformers.cpp
|
||||
ASTConstraintDeclaration.cpp
|
||||
ASTCreateFunctionQuery.cpp
|
||||
ASTCreateQuery.cpp
|
||||
ASTCreateQuotaQuery.cpp
|
||||
ASTCreateRoleQuery.cpp
|
||||
ASTCreateRowPolicyQuery.cpp
|
||||
ASTCreateSettingsProfileQuery.cpp
|
||||
ASTCreateUserQuery.cpp
|
||||
ASTDatabaseOrNone.cpp
|
||||
ASTDictionary.cpp
|
||||
ASTDictionaryAttributeDeclaration.cpp
|
||||
ASTDropAccessEntityQuery.cpp
|
||||
ASTDropFunctionQuery.cpp
|
||||
ASTDropQuery.cpp
|
||||
ASTExpressionList.cpp
|
||||
ASTFunction.cpp
|
||||
ASTFunctionWithKeyValueArguments.cpp
|
||||
ASTGrantQuery.cpp
|
||||
ASTIdentifier.cpp
|
||||
ASTIndexDeclaration.cpp
|
||||
ASTInsertQuery.cpp
|
||||
ASTKillQueryQuery.cpp
|
||||
ASTLiteral.cpp
|
||||
ASTNameTypePair.cpp
|
||||
ASTOptimizeQuery.cpp
|
||||
ASTOrderByElement.cpp
|
||||
ASTPartition.cpp
|
||||
ASTProjectionDeclaration.cpp
|
||||
ASTProjectionSelectQuery.cpp
|
||||
ASTQualifiedAsterisk.cpp
|
||||
ASTQueryParameter.cpp
|
||||
ASTQueryWithOnCluster.cpp
|
||||
ASTQueryWithOutput.cpp
|
||||
ASTQueryWithTableAndOutput.cpp
|
||||
ASTRolesOrUsersSet.cpp
|
||||
ASTRowPolicyName.cpp
|
||||
ASTSampleRatio.cpp
|
||||
ASTSelectIntersectExceptQuery.cpp
|
||||
ASTSelectQuery.cpp
|
||||
ASTSelectWithUnionQuery.cpp
|
||||
ASTSetQuery.cpp
|
||||
ASTSetRoleQuery.cpp
|
||||
ASTSettingsProfileElement.cpp
|
||||
ASTShowAccessEntitiesQuery.cpp
|
||||
ASTShowCreateAccessEntityQuery.cpp
|
||||
ASTShowGrantsQuery.cpp
|
||||
ASTShowTablesQuery.cpp
|
||||
ASTSubquery.cpp
|
||||
ASTSystemQuery.cpp
|
||||
ASTTTLElement.cpp
|
||||
ASTTablesInSelectQuery.cpp
|
||||
ASTUserNameWithHost.cpp
|
||||
ASTWindowDefinition.cpp
|
||||
ASTWithAlias.cpp
|
||||
ASTWithElement.cpp
|
||||
CommonParsers.cpp
|
||||
ExpressionElementParsers.cpp
|
||||
ExpressionListParsers.cpp
|
||||
IAST.cpp
|
||||
IParserBase.cpp
|
||||
InsertQuerySettingsPushDownVisitor.cpp
|
||||
Lexer.cpp
|
||||
MySQL/ASTAlterCommand.cpp
|
||||
MySQL/ASTAlterQuery.cpp
|
||||
MySQL/ASTCreateDefines.cpp
|
||||
MySQL/ASTCreateQuery.cpp
|
||||
MySQL/ASTDeclareColumn.cpp
|
||||
MySQL/ASTDeclareConstraint.cpp
|
||||
MySQL/ASTDeclareIndex.cpp
|
||||
MySQL/ASTDeclareOption.cpp
|
||||
MySQL/ASTDeclarePartition.cpp
|
||||
MySQL/ASTDeclarePartitionOptions.cpp
|
||||
MySQL/ASTDeclareReference.cpp
|
||||
MySQL/ASTDeclareSubPartition.cpp
|
||||
MySQL/ASTDeclareTableOptions.cpp
|
||||
ParserAlterQuery.cpp
|
||||
ParserBackupQuery.cpp
|
||||
ParserCase.cpp
|
||||
ParserCheckQuery.cpp
|
||||
ParserCreateFunctionQuery.cpp
|
||||
ParserCreateQuery.cpp
|
||||
ParserCreateQuotaQuery.cpp
|
||||
ParserCreateRoleQuery.cpp
|
||||
ParserCreateRowPolicyQuery.cpp
|
||||
ParserCreateSettingsProfileQuery.cpp
|
||||
ParserCreateUserQuery.cpp
|
||||
ParserDataType.cpp
|
||||
ParserDatabaseOrNone.cpp
|
||||
ParserDescribeTableQuery.cpp
|
||||
ParserDictionary.cpp
|
||||
ParserDictionaryAttributeDeclaration.cpp
|
||||
ParserDropAccessEntityQuery.cpp
|
||||
ParserDropFunctionQuery.cpp
|
||||
ParserDropQuery.cpp
|
||||
ParserExplainQuery.cpp
|
||||
ParserExternalDDLQuery.cpp
|
||||
ParserGrantQuery.cpp
|
||||
ParserInsertQuery.cpp
|
||||
ParserKillQueryQuery.cpp
|
||||
ParserOptimizeQuery.cpp
|
||||
ParserPartition.cpp
|
||||
ParserProjectionSelectQuery.cpp
|
||||
ParserQuery.cpp
|
||||
ParserQueryWithOutput.cpp
|
||||
ParserRenameQuery.cpp
|
||||
ParserRolesOrUsersSet.cpp
|
||||
ParserRowPolicyName.cpp
|
||||
ParserSampleRatio.cpp
|
||||
ParserSelectQuery.cpp
|
||||
ParserSelectWithUnionQuery.cpp
|
||||
ParserSetQuery.cpp
|
||||
ParserSetRoleQuery.cpp
|
||||
ParserSettingsProfileElement.cpp
|
||||
ParserShowAccessEntitiesQuery.cpp
|
||||
ParserShowCreateAccessEntityQuery.cpp
|
||||
ParserShowGrantsQuery.cpp
|
||||
ParserShowPrivilegesQuery.cpp
|
||||
ParserShowTablesQuery.cpp
|
||||
ParserSystemQuery.cpp
|
||||
ParserTablePropertiesQuery.cpp
|
||||
ParserTablesInSelectQuery.cpp
|
||||
ParserUnionQueryElement.cpp
|
||||
ParserUseQuery.cpp
|
||||
ParserUserNameWithHost.cpp
|
||||
ParserWatchQuery.cpp
|
||||
ParserWithElement.cpp
|
||||
QueryWithOutputSettingsPushDownVisitor.cpp
|
||||
TokenIterator.cpp
|
||||
formatAST.cpp
|
||||
formatSettingName.cpp
|
||||
getInsertQuery.cpp
|
||||
iostream_debug_helpers.cpp
|
||||
makeASTForLogicalFunction.cpp
|
||||
obfuscateQueries.cpp
|
||||
parseDatabaseAndTableName.cpp
|
||||
parseIdentifierOrStringLiteral.cpp
|
||||
parseIntervalKind.cpp
|
||||
parseQuery.cpp
|
||||
parseUserName.cpp
|
||||
queryToString.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,14 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F New | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1658,68 +1658,6 @@ struct WindowFunctionLagLeadInFrame final : public WindowFunction
|
||||
}
|
||||
};
|
||||
|
||||
struct WindowFunctionNthValue final : public WindowFunction
|
||||
{
|
||||
WindowFunctionNthValue(const std::string & name_,
|
||||
const DataTypes & argument_types_, const Array & parameters_)
|
||||
: WindowFunction(name_, argument_types_, parameters_)
|
||||
{
|
||||
if (!parameters.empty())
|
||||
{
|
||||
throw Exception(ErrorCodes::BAD_ARGUMENTS,
|
||||
"Function {} cannot be parameterized", name_);
|
||||
}
|
||||
|
||||
if (argument_types.size() != 2)
|
||||
{
|
||||
throw Exception(ErrorCodes::BAD_ARGUMENTS,
|
||||
"Function '{}' accepts 2 arguments, {} given",
|
||||
name_, argument_types.size());
|
||||
}
|
||||
}
|
||||
|
||||
DataTypePtr getReturnType() const override
|
||||
{ return argument_types[0]; }
|
||||
|
||||
bool allocatesMemoryInArena() const override { return false; }
|
||||
|
||||
void windowInsertResultInto(const WindowTransform * transform,
|
||||
size_t function_index) override
|
||||
{
|
||||
const auto & current_block = transform->blockAt(transform->current_row);
|
||||
IColumn & to = *(current_block.output_columns[function_index]);
|
||||
const auto & workspace = transform->workspaces[function_index];
|
||||
|
||||
int64_t offset = (*current_block.input_columns[
|
||||
workspace.argument_column_indices[1]])[
|
||||
transform->current_row.row].get<Int64>();
|
||||
|
||||
/// Either overflow or really negative value, both is not acceptable.
|
||||
if (offset <= 0)
|
||||
{
|
||||
throw Exception(ErrorCodes::BAD_ARGUMENTS,
|
||||
"The offset for function {} must be in (0, {}], {} given",
|
||||
getName(), INT64_MAX, offset);
|
||||
}
|
||||
|
||||
--offset;
|
||||
const auto [target_row, offset_left] = transform->moveRowNumber(transform->frame_start, offset);
|
||||
if (offset_left != 0
|
||||
|| target_row < transform->frame_start
|
||||
|| transform->frame_end <= target_row)
|
||||
{
|
||||
// Offset is outside the frame.
|
||||
to.insertDefault();
|
||||
}
|
||||
else
|
||||
{
|
||||
// Offset is inside the frame.
|
||||
to.insertFrom(*transform->blockAt(target_row).input_columns[
|
||||
workspace.argument_column_indices[0]],
|
||||
target_row.row);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
void registerWindowFunctions(AggregateFunctionFactory & factory)
|
||||
{
|
||||
@ -1784,13 +1722,6 @@ void registerWindowFunctions(AggregateFunctionFactory & factory)
|
||||
return std::make_shared<WindowFunctionLagLeadInFrame<true>>(
|
||||
name, argument_types, parameters);
|
||||
}, properties});
|
||||
|
||||
factory.registerFunction("nth_value", {[](const std::string & name,
|
||||
const DataTypes & argument_types, const Array & parameters, const Settings *)
|
||||
{
|
||||
return std::make_shared<WindowFunctionNthValue>(
|
||||
name, argument_types, parameters);
|
||||
}, properties}, AggregateFunctionFactory::CaseInsensitive);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -1,192 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/msgpack
|
||||
contrib/libs/protobuf
|
||||
contrib/libs/apache/arrow
|
||||
contrib/libs/apache/orc
|
||||
)
|
||||
|
||||
ADDINCL(
|
||||
contrib/libs/apache/arrow/src
|
||||
contrib/libs/apache/orc/c++/include
|
||||
)
|
||||
|
||||
CFLAGS(-DUSE_ARROW=1 -DUSE_PARQUET=1 -DUSE_ORC=1)
|
||||
|
||||
SRCS(
|
||||
Chunk.cpp
|
||||
ConcatProcessor.cpp
|
||||
DelayedPortsProcessor.cpp
|
||||
Executors/ExecutingGraph.cpp
|
||||
Executors/PipelineExecutingBlockInputStream.cpp
|
||||
Executors/PipelineExecutor.cpp
|
||||
Executors/PollingQueue.cpp
|
||||
Executors/PullingAsyncPipelineExecutor.cpp
|
||||
Executors/PullingPipelineExecutor.cpp
|
||||
Executors/StreamingFormatExecutor.cpp
|
||||
ForkProcessor.cpp
|
||||
Formats/IInputFormat.cpp
|
||||
Formats/IOutputFormat.cpp
|
||||
Formats/IRowInputFormat.cpp
|
||||
Formats/IRowOutputFormat.cpp
|
||||
Formats/Impl/ArrowBlockInputFormat.cpp
|
||||
Formats/Impl/ArrowBlockOutputFormat.cpp
|
||||
Formats/Impl/ArrowBufferedStreams.cpp
|
||||
Formats/Impl/ArrowColumnToCHColumn.cpp
|
||||
Formats/Impl/BinaryRowInputFormat.cpp
|
||||
Formats/Impl/BinaryRowOutputFormat.cpp
|
||||
Formats/Impl/CHColumnToArrowColumn.cpp
|
||||
Formats/Impl/CSVRowInputFormat.cpp
|
||||
Formats/Impl/CSVRowOutputFormat.cpp
|
||||
Formats/Impl/ConstantExpressionTemplate.cpp
|
||||
Formats/Impl/JSONAsStringRowInputFormat.cpp
|
||||
Formats/Impl/JSONCompactEachRowRowInputFormat.cpp
|
||||
Formats/Impl/JSONCompactEachRowRowOutputFormat.cpp
|
||||
Formats/Impl/JSONCompactRowOutputFormat.cpp
|
||||
Formats/Impl/JSONEachRowRowInputFormat.cpp
|
||||
Formats/Impl/JSONEachRowRowOutputFormat.cpp
|
||||
Formats/Impl/JSONEachRowWithProgressRowOutputFormat.cpp
|
||||
Formats/Impl/JSONRowOutputFormat.cpp
|
||||
Formats/Impl/LineAsStringRowInputFormat.cpp
|
||||
Formats/Impl/MarkdownRowOutputFormat.cpp
|
||||
Formats/Impl/MsgPackRowInputFormat.cpp
|
||||
Formats/Impl/MsgPackRowOutputFormat.cpp
|
||||
Formats/Impl/MySQLOutputFormat.cpp
|
||||
Formats/Impl/NullFormat.cpp
|
||||
Formats/Impl/ODBCDriver2BlockOutputFormat.cpp
|
||||
Formats/Impl/ParallelFormattingOutputFormat.cpp
|
||||
Formats/Impl/ParallelParsingInputFormat.cpp
|
||||
Formats/Impl/PostgreSQLOutputFormat.cpp
|
||||
Formats/Impl/PrettyBlockOutputFormat.cpp
|
||||
Formats/Impl/PrettyCompactBlockOutputFormat.cpp
|
||||
Formats/Impl/PrettySpaceBlockOutputFormat.cpp
|
||||
Formats/Impl/ProtobufRowInputFormat.cpp
|
||||
Formats/Impl/ProtobufRowOutputFormat.cpp
|
||||
Formats/Impl/RawBLOBRowInputFormat.cpp
|
||||
Formats/Impl/RawBLOBRowOutputFormat.cpp
|
||||
Formats/Impl/RegexpRowInputFormat.cpp
|
||||
Formats/Impl/TSKVRowInputFormat.cpp
|
||||
Formats/Impl/TSKVRowOutputFormat.cpp
|
||||
Formats/Impl/TabSeparatedRowInputFormat.cpp
|
||||
Formats/Impl/TabSeparatedRowOutputFormat.cpp
|
||||
Formats/Impl/TemplateBlockOutputFormat.cpp
|
||||
Formats/Impl/TemplateRowInputFormat.cpp
|
||||
Formats/Impl/ValuesBlockInputFormat.cpp
|
||||
Formats/Impl/ValuesRowOutputFormat.cpp
|
||||
Formats/Impl/VerticalRowOutputFormat.cpp
|
||||
Formats/Impl/XMLRowOutputFormat.cpp
|
||||
Formats/LazyOutputFormat.cpp
|
||||
Formats/OutputStreamToOutputFormat.cpp
|
||||
Formats/PullingOutputFormat.cpp
|
||||
Formats/RowInputFormatWithDiagnosticInfo.cpp
|
||||
IAccumulatingTransform.cpp
|
||||
IInflatingTransform.cpp
|
||||
IProcessor.cpp
|
||||
ISimpleTransform.cpp
|
||||
ISink.cpp
|
||||
ISource.cpp
|
||||
LimitTransform.cpp
|
||||
Merges/Algorithms/AggregatingSortedAlgorithm.cpp
|
||||
Merges/Algorithms/CollapsingSortedAlgorithm.cpp
|
||||
Merges/Algorithms/FinishAggregatingInOrderAlgorithm.cpp
|
||||
Merges/Algorithms/GraphiteRollupSortedAlgorithm.cpp
|
||||
Merges/Algorithms/IMergingAlgorithmWithDelayedChunk.cpp
|
||||
Merges/Algorithms/IMergingAlgorithmWithSharedChunks.cpp
|
||||
Merges/Algorithms/MergingSortedAlgorithm.cpp
|
||||
Merges/Algorithms/ReplacingSortedAlgorithm.cpp
|
||||
Merges/Algorithms/SummingSortedAlgorithm.cpp
|
||||
Merges/Algorithms/VersionedCollapsingAlgorithm.cpp
|
||||
Merges/IMergingTransform.cpp
|
||||
Merges/MergingSortedTransform.cpp
|
||||
OffsetTransform.cpp
|
||||
Pipe.cpp
|
||||
Port.cpp
|
||||
QueryPipeline.cpp
|
||||
QueryPlan/AggregatingStep.cpp
|
||||
QueryPlan/ArrayJoinStep.cpp
|
||||
QueryPlan/BuildQueryPipelineSettings.cpp
|
||||
QueryPlan/CreatingSetsStep.cpp
|
||||
QueryPlan/CubeStep.cpp
|
||||
QueryPlan/DistinctStep.cpp
|
||||
QueryPlan/ExpressionStep.cpp
|
||||
QueryPlan/ExtremesStep.cpp
|
||||
QueryPlan/FillingStep.cpp
|
||||
QueryPlan/FilterStep.cpp
|
||||
QueryPlan/FinishSortingStep.cpp
|
||||
QueryPlan/IQueryPlanStep.cpp
|
||||
QueryPlan/ISourceStep.cpp
|
||||
QueryPlan/ITransformingStep.cpp
|
||||
QueryPlan/IntersectOrExceptStep.cpp
|
||||
QueryPlan/JoinStep.cpp
|
||||
QueryPlan/LimitByStep.cpp
|
||||
QueryPlan/LimitStep.cpp
|
||||
QueryPlan/MergeSortingStep.cpp
|
||||
QueryPlan/MergingAggregatedStep.cpp
|
||||
QueryPlan/MergingSortedStep.cpp
|
||||
QueryPlan/OffsetStep.cpp
|
||||
QueryPlan/Optimizations/QueryPlanOptimizationSettings.cpp
|
||||
QueryPlan/Optimizations/filterPushDown.cpp
|
||||
QueryPlan/Optimizations/liftUpArrayJoin.cpp
|
||||
QueryPlan/Optimizations/limitPushDown.cpp
|
||||
QueryPlan/Optimizations/mergeExpressions.cpp
|
||||
QueryPlan/Optimizations/optimizeTree.cpp
|
||||
QueryPlan/Optimizations/splitFilter.cpp
|
||||
QueryPlan/PartialSortingStep.cpp
|
||||
QueryPlan/QueryIdHolder.cpp
|
||||
QueryPlan/QueryPlan.cpp
|
||||
QueryPlan/ReadFromMergeTree.cpp
|
||||
QueryPlan/ReadFromPreparedSource.cpp
|
||||
QueryPlan/ReadFromRemote.cpp
|
||||
QueryPlan/ReadNothingStep.cpp
|
||||
QueryPlan/RollupStep.cpp
|
||||
QueryPlan/SettingQuotaAndLimitsStep.cpp
|
||||
QueryPlan/TotalsHavingStep.cpp
|
||||
QueryPlan/UnionStep.cpp
|
||||
QueryPlan/WindowStep.cpp
|
||||
ResizeProcessor.cpp
|
||||
Sources/DelayedSource.cpp
|
||||
Sources/RemoteSource.cpp
|
||||
Sources/SinkToOutputStream.cpp
|
||||
Sources/SourceFromInputStream.cpp
|
||||
Sources/SourceWithProgress.cpp
|
||||
Transforms/AddingDefaultsTransform.cpp
|
||||
Transforms/AddingSelectorTransform.cpp
|
||||
Transforms/AggregatingInOrderTransform.cpp
|
||||
Transforms/AggregatingTransform.cpp
|
||||
Transforms/ArrayJoinTransform.cpp
|
||||
Transforms/CheckSortedTransform.cpp
|
||||
Transforms/CopyTransform.cpp
|
||||
Transforms/CreatingSetsTransform.cpp
|
||||
Transforms/CubeTransform.cpp
|
||||
Transforms/DistinctTransform.cpp
|
||||
Transforms/ExpressionTransform.cpp
|
||||
Transforms/ExtremesTransform.cpp
|
||||
Transforms/FillingTransform.cpp
|
||||
Transforms/FilterTransform.cpp
|
||||
Transforms/FinishSortingTransform.cpp
|
||||
Transforms/IntersectOrExceptTransform.cpp
|
||||
Transforms/JoiningTransform.cpp
|
||||
Transforms/LimitByTransform.cpp
|
||||
Transforms/LimitsCheckingTransform.cpp
|
||||
Transforms/MaterializingTransform.cpp
|
||||
Transforms/MergeSortingTransform.cpp
|
||||
Transforms/MergingAggregatedMemoryEfficientTransform.cpp
|
||||
Transforms/MergingAggregatedTransform.cpp
|
||||
Transforms/PartialSortingTransform.cpp
|
||||
Transforms/ReverseTransform.cpp
|
||||
Transforms/RollupTransform.cpp
|
||||
Transforms/SortingTransform.cpp
|
||||
Transforms/SquashingChunksTransform.cpp
|
||||
Transforms/TotalsHavingTransform.cpp
|
||||
Transforms/WindowTransform.cpp
|
||||
Transforms/getSourceFromASTInsertQuery.cpp
|
||||
printPipeline.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,24 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/msgpack
|
||||
contrib/libs/protobuf
|
||||
contrib/libs/apache/arrow
|
||||
contrib/libs/apache/orc
|
||||
)
|
||||
|
||||
ADDINCL(
|
||||
contrib/libs/apache/arrow/src
|
||||
contrib/libs/apache/orc/c++/include
|
||||
)
|
||||
|
||||
CFLAGS(-DUSE_ARROW=1 -DUSE_PARQUET=1 -DUSE_ORC=1)
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | grep -v -P 'Avro|ORC|Parquet|CapnProto' | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,41 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/poco/Util
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
GRPCServer.cpp
|
||||
HTTP/HTMLForm.cpp
|
||||
HTTP/HTTPServer.cpp
|
||||
HTTP/HTTPServerConnection.cpp
|
||||
HTTP/HTTPServerConnectionFactory.cpp
|
||||
HTTP/HTTPServerRequest.cpp
|
||||
HTTP/HTTPServerResponse.cpp
|
||||
HTTP/ReadHeaders.cpp
|
||||
HTTP/WriteBufferFromHTTPServerResponse.cpp
|
||||
HTTPHandler.cpp
|
||||
HTTPHandlerFactory.cpp
|
||||
InterserverIOHTTPHandler.cpp
|
||||
KeeperTCPHandler.cpp
|
||||
MySQLHandler.cpp
|
||||
MySQLHandlerFactory.cpp
|
||||
NotFoundHandler.cpp
|
||||
PostgreSQLHandler.cpp
|
||||
PostgreSQLHandlerFactory.cpp
|
||||
PrometheusMetricsWriter.cpp
|
||||
PrometheusRequestHandler.cpp
|
||||
ProtocolServerAdapter.cpp
|
||||
ReplicasStatusHandler.cpp
|
||||
StaticRequestHandler.cpp
|
||||
TCPHandler.cpp
|
||||
WebUIRequestHandler.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,15 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/poco/Util
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F examples | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,241 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/sparsehash
|
||||
contrib/libs/poco/MongoDB
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
AlterCommands.cpp
|
||||
ColumnDefault.cpp
|
||||
ColumnsDescription.cpp
|
||||
ConstraintsDescription.cpp
|
||||
Distributed/DirectoryMonitor.cpp
|
||||
Distributed/DistributedSettings.cpp
|
||||
Distributed/DistributedSink.cpp
|
||||
ExecutableSettings.cpp
|
||||
IStorage.cpp
|
||||
IndicesDescription.cpp
|
||||
JoinSettings.cpp
|
||||
KeyDescription.cpp
|
||||
LiveView/StorageLiveView.cpp
|
||||
LiveView/TemporaryLiveViewCleaner.cpp
|
||||
MemorySettings.cpp
|
||||
MergeTree/ActiveDataPartSet.cpp
|
||||
MergeTree/AllMergeSelector.cpp
|
||||
MergeTree/BackgroundJobsAssignee.cpp
|
||||
MergeTree/BoolMask.cpp
|
||||
MergeTree/DataPartsExchange.cpp
|
||||
MergeTree/DropPartsRanges.cpp
|
||||
MergeTree/EphemeralLockInZooKeeper.cpp
|
||||
MergeTree/FutureMergedMutatedPart.cpp
|
||||
MergeTree/IMergeTreeDataPart.cpp
|
||||
MergeTree/IMergeTreeDataPartWriter.cpp
|
||||
MergeTree/IMergeTreeReader.cpp
|
||||
MergeTree/IMergedBlockOutputStream.cpp
|
||||
MergeTree/KeyCondition.cpp
|
||||
MergeTree/LevelMergeSelector.cpp
|
||||
MergeTree/MergeAlgorithm.cpp
|
||||
MergeTree/MergeFromLogEntryTask.cpp
|
||||
MergeTree/MergeList.cpp
|
||||
MergeTree/MergePlainMergeTreeTask.cpp
|
||||
MergeTree/MergeTask.cpp
|
||||
MergeTree/MergeTreeBackgroundExecutor.cpp
|
||||
MergeTree/MergeTreeBaseSelectProcessor.cpp
|
||||
MergeTree/MergeTreeBlockReadUtils.cpp
|
||||
MergeTree/MergeTreeData.cpp
|
||||
MergeTree/MergeTreeDataMergerMutator.cpp
|
||||
MergeTree/MergeTreeDataPartChecksum.cpp
|
||||
MergeTree/MergeTreeDataPartCompact.cpp
|
||||
MergeTree/MergeTreeDataPartInMemory.cpp
|
||||
MergeTree/MergeTreeDataPartTTLInfo.cpp
|
||||
MergeTree/MergeTreeDataPartType.cpp
|
||||
MergeTree/MergeTreeDataPartUUID.cpp
|
||||
MergeTree/MergeTreeDataPartWide.cpp
|
||||
MergeTree/MergeTreeDataPartWriterCompact.cpp
|
||||
MergeTree/MergeTreeDataPartWriterInMemory.cpp
|
||||
MergeTree/MergeTreeDataPartWriterOnDisk.cpp
|
||||
MergeTree/MergeTreeDataPartWriterWide.cpp
|
||||
MergeTree/MergeTreeDataSelectExecutor.cpp
|
||||
MergeTree/MergeTreeDataWriter.cpp
|
||||
MergeTree/MergeTreeDeduplicationLog.cpp
|
||||
MergeTree/MergeTreeInOrderSelectProcessor.cpp
|
||||
MergeTree/MergeTreeIndexAggregatorBloomFilter.cpp
|
||||
MergeTree/MergeTreeIndexBloomFilter.cpp
|
||||
MergeTree/MergeTreeIndexConditionBloomFilter.cpp
|
||||
MergeTree/MergeTreeIndexFullText.cpp
|
||||
MergeTree/MergeTreeIndexGranularity.cpp
|
||||
MergeTree/MergeTreeIndexGranularityInfo.cpp
|
||||
MergeTree/MergeTreeIndexGranuleBloomFilter.cpp
|
||||
MergeTree/MergeTreeIndexMinMax.cpp
|
||||
MergeTree/MergeTreeIndexReader.cpp
|
||||
MergeTree/MergeTreeIndexSet.cpp
|
||||
MergeTree/MergeTreeIndices.cpp
|
||||
MergeTree/MergeTreeMarksLoader.cpp
|
||||
MergeTree/MergeTreeMutationEntry.cpp
|
||||
MergeTree/MergeTreeMutationStatus.cpp
|
||||
MergeTree/MergeTreePartInfo.cpp
|
||||
MergeTree/MergeTreePartition.cpp
|
||||
MergeTree/MergeTreePartsMover.cpp
|
||||
MergeTree/MergeTreeRangeReader.cpp
|
||||
MergeTree/MergeTreeReadPool.cpp
|
||||
MergeTree/MergeTreeReaderCompact.cpp
|
||||
MergeTree/MergeTreeReaderInMemory.cpp
|
||||
MergeTree/MergeTreeReaderStream.cpp
|
||||
MergeTree/MergeTreeReaderWide.cpp
|
||||
MergeTree/MergeTreeReverseSelectProcessor.cpp
|
||||
MergeTree/MergeTreeSelectProcessor.cpp
|
||||
MergeTree/MergeTreeSequentialSource.cpp
|
||||
MergeTree/MergeTreeSettings.cpp
|
||||
MergeTree/MergeTreeSink.cpp
|
||||
MergeTree/MergeTreeThreadSelectProcessor.cpp
|
||||
MergeTree/MergeTreeWhereOptimizer.cpp
|
||||
MergeTree/MergeTreeWriteAheadLog.cpp
|
||||
MergeTree/MergeType.cpp
|
||||
MergeTree/MergedBlockOutputStream.cpp
|
||||
MergeTree/MergedColumnOnlyOutputStream.cpp
|
||||
MergeTree/MutateFromLogEntryTask.cpp
|
||||
MergeTree/MutatePlainMergeTreeTask.cpp
|
||||
MergeTree/MutateTask.cpp
|
||||
MergeTree/PartMovesBetweenShardsOrchestrator.cpp
|
||||
MergeTree/PartitionPruner.cpp
|
||||
MergeTree/PinnedPartUUIDs.cpp
|
||||
MergeTree/ReplicatedFetchList.cpp
|
||||
MergeTree/ReplicatedMergeMutateTaskBase.cpp
|
||||
MergeTree/ReplicatedMergeTreeAddress.cpp
|
||||
MergeTree/ReplicatedMergeTreeAltersSequence.cpp
|
||||
MergeTree/ReplicatedMergeTreeCleanupThread.cpp
|
||||
MergeTree/ReplicatedMergeTreeLogEntry.cpp
|
||||
MergeTree/ReplicatedMergeTreeMergeStrategyPicker.cpp
|
||||
MergeTree/ReplicatedMergeTreeMutationEntry.cpp
|
||||
MergeTree/ReplicatedMergeTreePartCheckThread.cpp
|
||||
MergeTree/ReplicatedMergeTreePartHeader.cpp
|
||||
MergeTree/ReplicatedMergeTreeQueue.cpp
|
||||
MergeTree/ReplicatedMergeTreeRestartingThread.cpp
|
||||
MergeTree/ReplicatedMergeTreeSink.cpp
|
||||
MergeTree/ReplicatedMergeTreeTableMetadata.cpp
|
||||
MergeTree/SimpleMergeSelector.cpp
|
||||
MergeTree/TTLMergeSelector.cpp
|
||||
MergeTree/checkDataPart.cpp
|
||||
MergeTree/localBackup.cpp
|
||||
MergeTree/registerStorageMergeTree.cpp
|
||||
MutationCommands.cpp
|
||||
MySQL/MySQLSettings.cpp
|
||||
PartitionCommands.cpp
|
||||
ProjectionsDescription.cpp
|
||||
ReadFinalForExternalReplicaStorage.cpp
|
||||
ReadInOrderOptimizer.cpp
|
||||
SelectQueryDescription.cpp
|
||||
SetSettings.cpp
|
||||
StorageBuffer.cpp
|
||||
StorageDictionary.cpp
|
||||
StorageDistributed.cpp
|
||||
StorageExecutable.cpp
|
||||
StorageExternalDistributed.cpp
|
||||
StorageFactory.cpp
|
||||
StorageFile.cpp
|
||||
StorageGenerateRandom.cpp
|
||||
StorageInMemoryMetadata.cpp
|
||||
StorageInput.cpp
|
||||
StorageJoin.cpp
|
||||
StorageLog.cpp
|
||||
StorageLogSettings.cpp
|
||||
StorageMaterializedMySQL.cpp
|
||||
StorageMaterializedView.cpp
|
||||
StorageMemory.cpp
|
||||
StorageMerge.cpp
|
||||
StorageMergeTree.cpp
|
||||
StorageMongoDB.cpp
|
||||
StorageMongoDBSocketFactory.cpp
|
||||
StorageMySQL.cpp
|
||||
StorageNull.cpp
|
||||
StorageReplicatedMergeTree.cpp
|
||||
StorageSQLite.cpp
|
||||
StorageSet.cpp
|
||||
StorageStripeLog.cpp
|
||||
StorageTinyLog.cpp
|
||||
StorageURL.cpp
|
||||
StorageValues.cpp
|
||||
StorageView.cpp
|
||||
StorageXDBC.cpp
|
||||
System/StorageSystemAggregateFunctionCombinators.cpp
|
||||
System/StorageSystemAsynchronousInserts.cpp
|
||||
System/StorageSystemAsynchronousMetrics.cpp
|
||||
System/StorageSystemBuildOptions.cpp
|
||||
System/StorageSystemClusters.cpp
|
||||
System/StorageSystemCollations.cpp
|
||||
System/StorageSystemColumns.cpp
|
||||
System/StorageSystemContributors.cpp
|
||||
System/StorageSystemContributors.generated.cpp
|
||||
System/StorageSystemCurrentRoles.cpp
|
||||
System/StorageSystemDDLWorkerQueue.cpp
|
||||
System/StorageSystemDataSkippingIndices.cpp
|
||||
System/StorageSystemDataTypeFamilies.cpp
|
||||
System/StorageSystemDatabases.cpp
|
||||
System/StorageSystemDetachedParts.cpp
|
||||
System/StorageSystemDictionaries.cpp
|
||||
System/StorageSystemDisks.cpp
|
||||
System/StorageSystemDistributionQueue.cpp
|
||||
System/StorageSystemEnabledRoles.cpp
|
||||
System/StorageSystemErrors.cpp
|
||||
System/StorageSystemEvents.cpp
|
||||
System/StorageSystemFormats.cpp
|
||||
System/StorageSystemFunctions.cpp
|
||||
System/StorageSystemGrants.cpp
|
||||
System/StorageSystemGraphite.cpp
|
||||
System/StorageSystemMacros.cpp
|
||||
System/StorageSystemMergeTreeSettings.cpp
|
||||
System/StorageSystemMerges.cpp
|
||||
System/StorageSystemMetrics.cpp
|
||||
System/StorageSystemModels.cpp
|
||||
System/StorageSystemMutations.cpp
|
||||
System/StorageSystemNumbers.cpp
|
||||
System/StorageSystemOne.cpp
|
||||
System/StorageSystemPartMovesBetweenShards.cpp
|
||||
System/StorageSystemParts.cpp
|
||||
System/StorageSystemPartsBase.cpp
|
||||
System/StorageSystemPartsColumns.cpp
|
||||
System/StorageSystemPrivileges.cpp
|
||||
System/StorageSystemProcesses.cpp
|
||||
System/StorageSystemProjectionParts.cpp
|
||||
System/StorageSystemProjectionPartsColumns.cpp
|
||||
System/StorageSystemQuotaLimits.cpp
|
||||
System/StorageSystemQuotaUsage.cpp
|
||||
System/StorageSystemQuotas.cpp
|
||||
System/StorageSystemQuotasUsage.cpp
|
||||
System/StorageSystemReplicas.cpp
|
||||
System/StorageSystemReplicatedFetches.cpp
|
||||
System/StorageSystemReplicationQueue.cpp
|
||||
System/StorageSystemRoleGrants.cpp
|
||||
System/StorageSystemRoles.cpp
|
||||
System/StorageSystemRowPolicies.cpp
|
||||
System/StorageSystemSettings.cpp
|
||||
System/StorageSystemSettingsProfileElements.cpp
|
||||
System/StorageSystemSettingsProfiles.cpp
|
||||
System/StorageSystemStackTrace.cpp
|
||||
System/StorageSystemStoragePolicies.cpp
|
||||
System/StorageSystemTableEngines.cpp
|
||||
System/StorageSystemTableFunctions.cpp
|
||||
System/StorageSystemTables.cpp
|
||||
System/StorageSystemUserDirectories.cpp
|
||||
System/StorageSystemUsers.cpp
|
||||
System/StorageSystemWarnings.cpp
|
||||
System/StorageSystemZeros.cpp
|
||||
System/StorageSystemZooKeeper.cpp
|
||||
System/attachInformationSchemaTables.cpp
|
||||
System/attachSystemTables.cpp
|
||||
TTLDescription.cpp
|
||||
VirtualColumnUtils.cpp
|
||||
extractKeyExpressionList.cpp
|
||||
getStructureOfRemoteTable.cpp
|
||||
registerStorages.cpp
|
||||
transformQueryForExternalDatabase.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,16 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
contrib/libs/sparsehash
|
||||
contrib/libs/poco/MongoDB
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -F tests | grep -v -F examples | grep -v -F fuzzers | grep -v -P 'Kafka|RabbitMQ|S3|HDFS|Licenses|TimeZones|RocksDB|PostgreSQL' | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
@ -1,36 +0,0 @@
|
||||
# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it.
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
ITableFunction.cpp
|
||||
ITableFunctionFileLike.cpp
|
||||
ITableFunctionXDBC.cpp
|
||||
TableFunctionDictionary.cpp
|
||||
TableFunctionExecutable.cpp
|
||||
TableFunctionFactory.cpp
|
||||
TableFunctionFile.cpp
|
||||
TableFunctionGenerateRandom.cpp
|
||||
TableFunctionInput.cpp
|
||||
TableFunctionMerge.cpp
|
||||
TableFunctionMySQL.cpp
|
||||
TableFunctionNull.cpp
|
||||
TableFunctionNumbers.cpp
|
||||
TableFunctionRemote.cpp
|
||||
TableFunctionSQLite.cpp
|
||||
TableFunctionURL.cpp
|
||||
TableFunctionValues.cpp
|
||||
TableFunctionView.cpp
|
||||
TableFunctionZeros.cpp
|
||||
parseColumnsListForTableFunction.cpp
|
||||
registerTableFunctions.cpp
|
||||
|
||||
)
|
||||
|
||||
END()
|
@ -1,14 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Common
|
||||
)
|
||||
|
||||
|
||||
SRCS(
|
||||
<? find . -name '*.cpp' | grep -v -P 'S3|HDFS|PostgreSQL' | grep -v -F examples | sed 's/^\.\// /' | sort ?>
|
||||
)
|
||||
|
||||
END()
|
32
src/ya.make
32
src/ya.make
@ -1,32 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
LIBRARY()
|
||||
|
||||
PEERDIR(
|
||||
clickhouse/src/Access
|
||||
clickhouse/src/AggregateFunctions
|
||||
clickhouse/src/Backups
|
||||
clickhouse/src/Bridge
|
||||
clickhouse/src/Client
|
||||
clickhouse/src/Columns
|
||||
clickhouse/src/Common
|
||||
clickhouse/src/Compression
|
||||
clickhouse/src/Coordination
|
||||
clickhouse/src/Core
|
||||
clickhouse/src/Databases
|
||||
clickhouse/src/DataStreams
|
||||
clickhouse/src/DataTypes
|
||||
clickhouse/src/Formats
|
||||
clickhouse/src/Dictionaries
|
||||
clickhouse/src/Disks
|
||||
clickhouse/src/Functions
|
||||
clickhouse/src/Interpreters
|
||||
clickhouse/src/IO
|
||||
clickhouse/src/Parsers
|
||||
clickhouse/src/Processors
|
||||
clickhouse/src/Server
|
||||
clickhouse/src/Storages
|
||||
clickhouse/src/TableFunctions
|
||||
)
|
||||
|
||||
END()
|
@ -1,17 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
|
||||
cd $DIR
|
||||
git clone https://github.com/catboost/catboost.git
|
||||
|
||||
|
||||
cd "${DIR}/catboost/catboost/libs/model_interface"
|
||||
../../../ya make -r -o "${DIR}/build/lib" -j4
|
||||
cd $DIR
|
||||
ln -sf "${DIR}/build/lib/catboost/libs/model_interface/libcatboostmodel.so" libcatboostmodel.so
|
||||
|
||||
cd "${DIR}/catboost/catboost/python-package/catboost"
|
||||
../../../ya make -r -DUSE_ARCADIA_PYTHON=no -DOS_SDK=local -DPYTHON_CONFIG=python2-config -j4
|
||||
cd $DIR
|
||||
ln -sf "${DIR}/catboost/catboost/python-package" python-package
|
@ -1,42 +0,0 @@
|
||||
import subprocess
|
||||
import threading
|
||||
import os
|
||||
|
||||
|
||||
class ClickHouseClient:
|
||||
def __init__(self, binary_path, port):
|
||||
self.binary_path = binary_path
|
||||
self.port = port
|
||||
|
||||
def query(self, query, timeout=10, pipe=None):
|
||||
|
||||
result = []
|
||||
process = []
|
||||
|
||||
def run(path, port, text, result, in_pipe, process):
|
||||
|
||||
if in_pipe is None:
|
||||
in_pipe = subprocess.PIPE
|
||||
|
||||
pipe = subprocess.Popen([path, 'client', '--port', str(port), '-q', text],
|
||||
stdin=in_pipe, stdout=subprocess.PIPE, stderr=subprocess.PIPE, close_fds=True)
|
||||
process.append(pipe)
|
||||
stdout_data, stderr_data = pipe.communicate()
|
||||
|
||||
if stderr_data:
|
||||
raise Exception('Error while executing query: {}\nstdout:\n{}\nstderr:\n{}'
|
||||
.format(text, stdout_data, stderr_data))
|
||||
|
||||
result.append(stdout_data)
|
||||
|
||||
thread = threading.Thread(target=run, args=(self.binary_path, self.port, query, result, pipe, process))
|
||||
thread.start()
|
||||
thread.join(timeout)
|
||||
if thread.isAlive():
|
||||
if len(process):
|
||||
process[0].kill()
|
||||
thread.join()
|
||||
raise Exception('timeout exceed for query: ' + query)
|
||||
|
||||
if len(result):
|
||||
return result[0]
|
@ -1,15 +0,0 @@
|
||||
import numpy as np
|
||||
|
||||
|
||||
def generate_uniform_int_column(size, low, high, seed=0):
|
||||
np.random.seed(seed)
|
||||
return np.random.randint(low, high, size)
|
||||
|
||||
|
||||
def generate_uniform_float_column(size, low, high, seed=0):
|
||||
np.random.seed(seed)
|
||||
return np.random.random(size) * (high - low) + low
|
||||
|
||||
|
||||
def generate_uniform_string_column(size, samples, seed):
|
||||
return np.array(samples)[generate_uniform_int_column(size, 0, len(samples), seed)]
|
@ -1,67 +0,0 @@
|
||||
import subprocess
|
||||
import threading
|
||||
import socket
|
||||
import time
|
||||
|
||||
|
||||
class ClickHouseServer:
|
||||
def __init__(self, binary_path, config_path, stdout_file=None, stderr_file=None, shutdown_timeout=10):
|
||||
self.binary_path = binary_path
|
||||
self.config_path = config_path
|
||||
self.pipe = None
|
||||
self.stdout_file = stdout_file
|
||||
self.stderr_file = stderr_file
|
||||
self.shutdown_timeout = shutdown_timeout
|
||||
|
||||
def start(self):
|
||||
cmd = [self.binary_path, 'server', '--config', self.config_path]
|
||||
out_pipe = None
|
||||
err_pipe = None
|
||||
if self.stdout_file is not None:
|
||||
out_pipe = open(self.stdout_file, 'w')
|
||||
if self.stderr_file is not None:
|
||||
err_pipe = open(self.stderr_file, 'w')
|
||||
self.pipe = subprocess.Popen(cmd, stdout=out_pipe, stderr=err_pipe)
|
||||
|
||||
def wait_for_request(self, port, timeout=1):
|
||||
try:
|
||||
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
|
||||
# is not working
|
||||
# s.settimeout(timeout)
|
||||
|
||||
step = 0.01
|
||||
for iter in range(int(timeout / step)):
|
||||
if s.connect_ex(('localhost', port)) == 0:
|
||||
return
|
||||
time.sleep(step)
|
||||
|
||||
s.connect(('localhost', port))
|
||||
except socket.error as socketerror:
|
||||
print("Error: ", socketerror)
|
||||
raise
|
||||
|
||||
def shutdown(self, timeout=10):
|
||||
|
||||
def wait(pipe):
|
||||
pipe.wait()
|
||||
|
||||
if self.pipe is not None:
|
||||
self.pipe.terminate()
|
||||
thread = threading.Thread(target=wait, args=(self.pipe,))
|
||||
thread.start()
|
||||
thread.join(timeout)
|
||||
if thread.isAlive():
|
||||
self.pipe.kill()
|
||||
thread.join()
|
||||
|
||||
if self.pipe.stdout is not None:
|
||||
self.pipe.stdout.close()
|
||||
if self.pipe.stderr is not None:
|
||||
self.pipe.stderr.close()
|
||||
|
||||
def __enter__(self):
|
||||
self.start()
|
||||
return self
|
||||
|
||||
def __exit__(self, type, value, traceback):
|
||||
self.shutdown(self.shutdown_timeout)
|
@ -1,168 +0,0 @@
|
||||
from .server import ClickHouseServer
|
||||
from .client import ClickHouseClient
|
||||
from .table import ClickHouseTable
|
||||
import os
|
||||
import errno
|
||||
from shutil import rmtree
|
||||
|
||||
SCRIPT_DIR = os.path.dirname(os.path.realpath(__file__))
|
||||
CATBOOST_ROOT = os.path.dirname(SCRIPT_DIR)
|
||||
|
||||
CLICKHOUSE_CONFIG = \
|
||||
'''
|
||||
<yandex>
|
||||
<timezone>Europe/Moscow</timezone>
|
||||
<listen_host>::</listen_host>
|
||||
<path>{path}</path>
|
||||
<tmp_path>{tmp_path}</tmp_path>
|
||||
<models_config>{models_config}</models_config>
|
||||
<mark_cache_size>5368709120</mark_cache_size>
|
||||
<users_config>users.xml</users_config>
|
||||
<tcp_port>{tcp_port}</tcp_port>
|
||||
<catboost_dynamic_library_path>{catboost_dynamic_library_path}</catboost_dynamic_library_path>
|
||||
<logger>
|
||||
<level>trace</level>
|
||||
<log>{path}/clickhouse-server.log</log>
|
||||
<errorlog>{path}/clickhouse-server.err.log</errorlog>
|
||||
<size>never</size>
|
||||
<count>50</count>
|
||||
</logger>
|
||||
</yandex>
|
||||
'''
|
||||
|
||||
CLICKHOUSE_USERS = \
|
||||
'''
|
||||
<yandex>
|
||||
<profiles>
|
||||
<default>
|
||||
</default>
|
||||
<readonly>
|
||||
<readonly>1</readonly>
|
||||
</readonly>
|
||||
</profiles>
|
||||
|
||||
<users>
|
||||
<readonly>
|
||||
<password></password>
|
||||
<profile>readonly</profile>
|
||||
<quota>default</quota>
|
||||
</readonly>
|
||||
|
||||
<default>
|
||||
<password></password>
|
||||
<profile>default</profile>
|
||||
<quota>default</quota>
|
||||
<networks incl="networks" replace="replace">
|
||||
<ip>::1</ip>
|
||||
<ip>127.0.0.1</ip>
|
||||
</networks>
|
||||
|
||||
</default>
|
||||
</users>
|
||||
|
||||
<quotas>
|
||||
<default>
|
||||
</default>
|
||||
</quotas>
|
||||
</yandex>
|
||||
'''
|
||||
|
||||
CATBOOST_MODEL_CONFIG = \
|
||||
'''
|
||||
<models>
|
||||
<model>
|
||||
<type>catboost</type>
|
||||
<name>{name}</name>
|
||||
<path>{path}</path>
|
||||
<lifetime>0</lifetime>
|
||||
</model>
|
||||
</models>
|
||||
'''
|
||||
|
||||
|
||||
class ClickHouseServerWithCatboostModels:
|
||||
def __init__(self, name, binary_path, port, shutdown_timeout=10, clean_folder=False):
|
||||
self.models = {}
|
||||
self.name = name
|
||||
self.binary_path = binary_path
|
||||
self.port = port
|
||||
self.shutdown_timeout = shutdown_timeout
|
||||
self.clean_folder = clean_folder
|
||||
self.root = os.path.join(CATBOOST_ROOT, 'data', 'servers')
|
||||
self.config_path = os.path.join(self.root, 'config.xml')
|
||||
self.users_path = os.path.join(self.root, 'users.xml')
|
||||
self.models_dir = os.path.join(self.root, 'models')
|
||||
self.server = None
|
||||
|
||||
def _get_server(self):
|
||||
stdout_file = os.path.join(self.root, 'server_stdout.txt')
|
||||
stderr_file = os.path.join(self.root, 'server_stderr.txt')
|
||||
return ClickHouseServer(self.binary_path, self.config_path, stdout_file, stderr_file, self.shutdown_timeout)
|
||||
|
||||
def add_model(self, model_name, model):
|
||||
self.models[model_name] = model
|
||||
|
||||
def apply_model(self, name, df, cat_feature_names):
|
||||
names = list(df)
|
||||
float_feature_names = tuple(name for name in names if name not in cat_feature_names)
|
||||
with ClickHouseTable(self.server, self.port, name, df) as table:
|
||||
return table.apply_model(name, cat_feature_names, float_feature_names)
|
||||
|
||||
def _create_root(self):
|
||||
try:
|
||||
os.makedirs(self.root)
|
||||
except OSError as exc: # Python >2.5
|
||||
if exc.errno == errno.EEXIST and os.path.isdir(self.root):
|
||||
pass
|
||||
else:
|
||||
raise
|
||||
|
||||
def _clean_root(self):
|
||||
rmtree(self.root)
|
||||
|
||||
def _save_config(self):
|
||||
params = {
|
||||
'tcp_port': self.port,
|
||||
'path': os.path.join(self.root, 'clickhouse'),
|
||||
'tmp_path': os.path.join(self.root, 'clickhouse', 'tmp'),
|
||||
'models_config': os.path.join(self.models_dir, '*_model.xml'),
|
||||
'catboost_dynamic_library_path': os.path.join(CATBOOST_ROOT, 'data', 'libcatboostmodel.so')
|
||||
}
|
||||
config = CLICKHOUSE_CONFIG.format(**params)
|
||||
|
||||
with open(self.config_path, 'w') as f:
|
||||
f.write(config)
|
||||
|
||||
with open(self.users_path, 'w') as f:
|
||||
f.write(CLICKHOUSE_USERS)
|
||||
|
||||
def _save_models(self):
|
||||
if not os.path.exists(self.models_dir):
|
||||
os.makedirs(self.models_dir)
|
||||
|
||||
for name, model in list(self.models.items()):
|
||||
model_path = os.path.join(self.models_dir, name + '.cbm')
|
||||
config_path = os.path.join(self.models_dir, name + '_model.xml')
|
||||
params = {
|
||||
'name': name,
|
||||
'path': model_path
|
||||
}
|
||||
config = CATBOOST_MODEL_CONFIG.format(**params)
|
||||
with open(config_path, 'w') as f:
|
||||
f.write(config)
|
||||
|
||||
model.save_model(model_path)
|
||||
|
||||
def __enter__(self):
|
||||
self._create_root()
|
||||
self._save_config()
|
||||
self._save_models()
|
||||
self.server = self._get_server().__enter__()
|
||||
return self
|
||||
|
||||
def __exit__(self, exc_type, exc_val, exc_tb):
|
||||
res = self.server.__exit__(exc_type, exc_val, exc_tb)
|
||||
if self.clean_folder:
|
||||
self._clean_root()
|
||||
return res
|
||||
|
@ -1,74 +0,0 @@
|
||||
from .server import ClickHouseServer
|
||||
from .client import ClickHouseClient
|
||||
from pandas import DataFrame
|
||||
import os
|
||||
import threading
|
||||
import tempfile
|
||||
|
||||
|
||||
class ClickHouseTable:
|
||||
def __init__(self, server, port, table_name, df):
|
||||
self.server = server
|
||||
self.port = port
|
||||
self.table_name = table_name
|
||||
self.df = df
|
||||
|
||||
if not isinstance(self.server, ClickHouseServer):
|
||||
raise Exception('Expected ClickHouseServer, got ' + repr(self.server))
|
||||
if not isinstance(self.df, DataFrame):
|
||||
raise Exception('Expected DataFrame, got ' + repr(self.df))
|
||||
|
||||
self.server.wait_for_request(port)
|
||||
self.client = ClickHouseClient(server.binary_path, port)
|
||||
|
||||
def _convert(self, name):
|
||||
types_map = {
|
||||
'float64': 'Float64',
|
||||
'int64': 'Int64',
|
||||
'float32': 'Float32',
|
||||
'int32': 'Int32'
|
||||
}
|
||||
|
||||
if name in types_map:
|
||||
return types_map[name]
|
||||
return 'String'
|
||||
|
||||
def _create_table_from_df(self):
|
||||
self.client.query('create database if not exists test')
|
||||
self.client.query('drop table if exists test.{}'.format(self.table_name))
|
||||
|
||||
column_types = list(self.df.dtypes)
|
||||
column_names = list(self.df)
|
||||
schema = ', '.join((name + ' ' + self._convert(str(t)) for name, t in zip(column_names, column_types)))
|
||||
print('schema:', schema)
|
||||
|
||||
create_query = 'create table test.{} (date Date DEFAULT today(), {}) engine = MergeTree(date, (date), 8192)'
|
||||
self.client.query(create_query.format(self.table_name, schema))
|
||||
|
||||
insert_query = 'insert into test.{} ({}) format CSV'
|
||||
|
||||
with tempfile.TemporaryFile() as tmp_file:
|
||||
self.df.to_csv(tmp_file, header=False, index=False)
|
||||
tmp_file.seek(0)
|
||||
self.client.query(insert_query.format(self.table_name, ', '.join(column_names)), pipe=tmp_file)
|
||||
|
||||
def apply_model(self, model_name, float_columns, cat_columns):
|
||||
columns = ', '.join(list(float_columns) + list(cat_columns))
|
||||
query = "select modelEvaluate('{}', {}) from test.{} format TSV"
|
||||
result = self.client.query(query.format(model_name, columns, self.table_name))
|
||||
|
||||
def parse_row(row):
|
||||
values = tuple(map(float, list(filter(len, list(map(str.strip, row.replace('(', '').replace(')', '').split(',')))))))
|
||||
return values if len(values) != 1 else values[0]
|
||||
|
||||
return tuple(map(parse_row, list(filter(len, list(map(str.strip, result.split('\n')))))))
|
||||
|
||||
def _drop_table(self):
|
||||
self.client.query('drop table test.{}'.format(self.table_name))
|
||||
|
||||
def __enter__(self):
|
||||
self._create_table_from_df()
|
||||
return self
|
||||
|
||||
def __exit__(self, type, value, traceback):
|
||||
self._drop_table()
|
@ -1,28 +0,0 @@
|
||||
import os
|
||||
import sys
|
||||
from pandas import DataFrame
|
||||
|
||||
SCRIPT_DIR = os.path.dirname(os.path.realpath(__file__))
|
||||
CATBOOST_ROOT = os.path.dirname(SCRIPT_DIR)
|
||||
CATBOOST_PYTHON_DIR = os.path.join(CATBOOST_ROOT, 'data', 'python-package')
|
||||
|
||||
if CATBOOST_PYTHON_DIR not in sys.path:
|
||||
sys.path.append(CATBOOST_PYTHON_DIR)
|
||||
|
||||
|
||||
import catboost
|
||||
from catboost import CatBoostClassifier
|
||||
|
||||
|
||||
def train_catboost_model(df, target, cat_features, params, verbose=True):
|
||||
|
||||
if not isinstance(df, DataFrame):
|
||||
raise Exception('DataFrame object expected, but got ' + repr(df))
|
||||
|
||||
print('features:', df.columns.tolist())
|
||||
|
||||
cat_features_index = list(df.columns.get_loc(feature) for feature in cat_features)
|
||||
print('cat features:', cat_features_index)
|
||||
model = CatBoostClassifier(**params)
|
||||
model.fit(df, target, cat_features=cat_features_index, verbose=verbose)
|
||||
return model
|
@ -1,3 +0,0 @@
|
||||
[pytest]
|
||||
python_files = test.py
|
||||
norecursedirs=data
|
@ -1,294 +0,0 @@
|
||||
from helpers.server_with_models import ClickHouseServerWithCatboostModels
|
||||
from helpers.generate import generate_uniform_string_column, generate_uniform_float_column, generate_uniform_int_column
|
||||
from helpers.train import train_catboost_model
|
||||
import os
|
||||
import numpy as np
|
||||
from pandas import DataFrame
|
||||
|
||||
|
||||
PORT = int(os.environ.get('CLICKHOUSE_TESTS_PORT', '9000'))
|
||||
CLICKHOUSE_TESTS_SERVER_BIN_PATH = os.environ.get('CLICKHOUSE_TESTS_SERVER_BIN_PATH', '/usr/bin/clickhouse')
|
||||
|
||||
|
||||
def add_noise_to_target(target, seed, threshold=0.05):
|
||||
col = generate_uniform_float_column(len(target), 0., 1., seed + 1) < threshold
|
||||
return target * (1 - col) + (1 - target) * col
|
||||
|
||||
|
||||
def check_predictions(test_name, target, pred_python, pred_ch, acc_threshold):
|
||||
ch_class = pred_ch.astype(int)
|
||||
python_class = pred_python.astype(int)
|
||||
if not np.array_equal(ch_class, python_class):
|
||||
raise Exception('Got different results:\npython:\n' + str(python_class) + '\nClickHouse:\n' + str(ch_class))
|
||||
|
||||
acc = 1 - np.sum(np.abs(ch_class - np.array(target))) / (len(target) + .0)
|
||||
assert acc >= acc_threshold
|
||||
print(test_name, 'accuracy: {:.10f}'.format(acc))
|
||||
|
||||
|
||||
def test_apply_float_features_only():
|
||||
|
||||
name = 'test_apply_float_features_only'
|
||||
|
||||
train_size = 10000
|
||||
test_size = 10000
|
||||
|
||||
def gen_data(size, seed):
|
||||
data = {
|
||||
'a': generate_uniform_float_column(size, 0., 1., seed + 1),
|
||||
'b': generate_uniform_float_column(size, 0., 1., seed + 2),
|
||||
'c': generate_uniform_float_column(size, 0., 1., seed + 3)
|
||||
}
|
||||
return DataFrame.from_dict(data)
|
||||
|
||||
def get_target(df):
|
||||
def target_filter(row):
|
||||
return 1 if (row['a'] > .3 and row['b'] > .3) or (row['c'] < .4 and row['a'] * row['b'] > 0.1) else 0
|
||||
return df.apply(target_filter, axis=1).as_matrix()
|
||||
|
||||
train_df = gen_data(train_size, 42)
|
||||
test_df = gen_data(test_size, 43)
|
||||
|
||||
train_target = get_target(train_df)
|
||||
test_target = get_target(test_df)
|
||||
|
||||
print()
|
||||
print('train target', train_target)
|
||||
print('test target', test_target)
|
||||
|
||||
params = {
|
||||
'iterations': 4,
|
||||
'depth': 2,
|
||||
'learning_rate': 1,
|
||||
'loss_function': 'Logloss'
|
||||
}
|
||||
|
||||
model = train_catboost_model(train_df, train_target, [], params)
|
||||
pred_python = model.predict(test_df)
|
||||
|
||||
server = ClickHouseServerWithCatboostModels(name, CLICKHOUSE_TESTS_SERVER_BIN_PATH, PORT)
|
||||
server.add_model(name, model)
|
||||
with server:
|
||||
pred_ch = (np.array(server.apply_model(name, test_df, [])) > 0).astype(int)
|
||||
|
||||
print('python predictions', pred_python)
|
||||
print('clickhouse predictions', pred_ch)
|
||||
|
||||
check_predictions(name, test_target, pred_python, pred_ch, 0.9)
|
||||
|
||||
|
||||
def test_apply_float_features_with_string_cat_features():
|
||||
|
||||
name = 'test_apply_float_features_with_string_cat_features'
|
||||
|
||||
train_size = 10000
|
||||
test_size = 10000
|
||||
|
||||
def gen_data(size, seed):
|
||||
data = {
|
||||
'a': generate_uniform_float_column(size, 0., 1., seed + 1),
|
||||
'b': generate_uniform_float_column(size, 0., 1., seed + 2),
|
||||
'c': generate_uniform_string_column(size, ['a', 'b', 'c'], seed + 3),
|
||||
'd': generate_uniform_string_column(size, ['e', 'f', 'g'], seed + 4)
|
||||
}
|
||||
return DataFrame.from_dict(data)
|
||||
|
||||
def get_target(df):
|
||||
def target_filter(row):
|
||||
return 1 if (row['a'] > .3 and row['b'] > .3 and row['c'] != 'a') \
|
||||
or (row['a'] * row['b'] > 0.1 and row['c'] != 'b' and row['d'] != 'e') else 0
|
||||
return df.apply(target_filter, axis=1).as_matrix()
|
||||
|
||||
train_df = gen_data(train_size, 42)
|
||||
test_df = gen_data(test_size, 43)
|
||||
|
||||
train_target = get_target(train_df)
|
||||
test_target = get_target(test_df)
|
||||
|
||||
print()
|
||||
print('train target', train_target)
|
||||
print('test target', test_target)
|
||||
|
||||
params = {
|
||||
'iterations': 6,
|
||||
'depth': 2,
|
||||
'learning_rate': 1,
|
||||
'loss_function': 'Logloss'
|
||||
}
|
||||
|
||||
model = train_catboost_model(train_df, train_target, ['c', 'd'], params)
|
||||
pred_python = model.predict(test_df)
|
||||
|
||||
server = ClickHouseServerWithCatboostModels(name, CLICKHOUSE_TESTS_SERVER_BIN_PATH, PORT)
|
||||
server.add_model(name, model)
|
||||
with server:
|
||||
pred_ch = (np.array(server.apply_model(name, test_df, [])) > 0).astype(int)
|
||||
|
||||
print('python predictions', pred_python)
|
||||
print('clickhouse predictions', pred_ch)
|
||||
|
||||
check_predictions(name, test_target, pred_python, pred_ch, 0.9)
|
||||
|
||||
|
||||
def test_apply_float_features_with_int_cat_features():
|
||||
|
||||
name = 'test_apply_float_features_with_int_cat_features'
|
||||
|
||||
train_size = 10000
|
||||
test_size = 10000
|
||||
|
||||
def gen_data(size, seed):
|
||||
data = {
|
||||
'a': generate_uniform_float_column(size, 0., 1., seed + 1),
|
||||
'b': generate_uniform_float_column(size, 0., 1., seed + 2),
|
||||
'c': generate_uniform_int_column(size, 1, 4, seed + 3),
|
||||
'd': generate_uniform_int_column(size, 1, 4, seed + 4)
|
||||
}
|
||||
return DataFrame.from_dict(data)
|
||||
|
||||
def get_target(df):
|
||||
def target_filter(row):
|
||||
return 1 if (row['a'] > .3 and row['b'] > .3 and row['c'] != 1) \
|
||||
or (row['a'] * row['b'] > 0.1 and row['c'] != 2 and row['d'] != 3) else 0
|
||||
return df.apply(target_filter, axis=1).as_matrix()
|
||||
|
||||
train_df = gen_data(train_size, 42)
|
||||
test_df = gen_data(test_size, 43)
|
||||
|
||||
train_target = get_target(train_df)
|
||||
test_target = get_target(test_df)
|
||||
|
||||
print()
|
||||
print('train target', train_target)
|
||||
print('test target', test_target)
|
||||
|
||||
params = {
|
||||
'iterations': 6,
|
||||
'depth': 4,
|
||||
'learning_rate': 1,
|
||||
'loss_function': 'Logloss'
|
||||
}
|
||||
|
||||
model = train_catboost_model(train_df, train_target, ['c', 'd'], params)
|
||||
pred_python = model.predict(test_df)
|
||||
|
||||
server = ClickHouseServerWithCatboostModels(name, CLICKHOUSE_TESTS_SERVER_BIN_PATH, PORT)
|
||||
server.add_model(name, model)
|
||||
with server:
|
||||
pred_ch = (np.array(server.apply_model(name, test_df, [])) > 0).astype(int)
|
||||
|
||||
print('python predictions', pred_python)
|
||||
print('clickhouse predictions', pred_ch)
|
||||
|
||||
check_predictions(name, test_target, pred_python, pred_ch, 0.9)
|
||||
|
||||
|
||||
def test_apply_float_features_with_mixed_cat_features():
|
||||
|
||||
name = 'test_apply_float_features_with_mixed_cat_features'
|
||||
|
||||
train_size = 10000
|
||||
test_size = 10000
|
||||
|
||||
def gen_data(size, seed):
|
||||
data = {
|
||||
'a': generate_uniform_float_column(size, 0., 1., seed + 1),
|
||||
'b': generate_uniform_float_column(size, 0., 1., seed + 2),
|
||||
'c': generate_uniform_string_column(size, ['a', 'b', 'c'], seed + 3),
|
||||
'd': generate_uniform_int_column(size, 1, 4, seed + 4)
|
||||
}
|
||||
return DataFrame.from_dict(data)
|
||||
|
||||
def get_target(df):
|
||||
def target_filter(row):
|
||||
return 1 if (row['a'] > .3 and row['b'] > .3 and row['c'] != 'a') \
|
||||
or (row['a'] * row['b'] > 0.1 and row['c'] != 'b' and row['d'] != 2) else 0
|
||||
return df.apply(target_filter, axis=1).as_matrix()
|
||||
|
||||
train_df = gen_data(train_size, 42)
|
||||
test_df = gen_data(test_size, 43)
|
||||
|
||||
train_target = get_target(train_df)
|
||||
test_target = get_target(test_df)
|
||||
|
||||
print()
|
||||
print('train target', train_target)
|
||||
print('test target', test_target)
|
||||
|
||||
params = {
|
||||
'iterations': 6,
|
||||
'depth': 4,
|
||||
'learning_rate': 1,
|
||||
'loss_function': 'Logloss'
|
||||
}
|
||||
|
||||
model = train_catboost_model(train_df, train_target, ['c', 'd'], params)
|
||||
pred_python = model.predict(test_df)
|
||||
|
||||
server = ClickHouseServerWithCatboostModels(name, CLICKHOUSE_TESTS_SERVER_BIN_PATH, PORT)
|
||||
server.add_model(name, model)
|
||||
with server:
|
||||
pred_ch = (np.array(server.apply_model(name, test_df, [])) > 0).astype(int)
|
||||
|
||||
print('python predictions', pred_python)
|
||||
print('clickhouse predictions', pred_ch)
|
||||
|
||||
check_predictions(name, test_target, pred_python, pred_ch, 0.9)
|
||||
|
||||
|
||||
def test_apply_multiclass():
|
||||
|
||||
name = 'test_apply_float_features_with_mixed_cat_features'
|
||||
|
||||
train_size = 10000
|
||||
test_size = 10000
|
||||
|
||||
def gen_data(size, seed):
|
||||
data = {
|
||||
'a': generate_uniform_float_column(size, 0., 1., seed + 1),
|
||||
'b': generate_uniform_float_column(size, 0., 1., seed + 2),
|
||||
'c': generate_uniform_string_column(size, ['a', 'b', 'c'], seed + 3),
|
||||
'd': generate_uniform_int_column(size, 1, 4, seed + 4)
|
||||
}
|
||||
return DataFrame.from_dict(data)
|
||||
|
||||
def get_target(df):
|
||||
def target_filter(row):
|
||||
if row['a'] > .3 and row['b'] > .3 and row['c'] != 'a':
|
||||
return 0
|
||||
elif row['a'] * row['b'] > 0.1 and row['c'] != 'b' and row['d'] != 2:
|
||||
return 1
|
||||
else:
|
||||
return 2
|
||||
|
||||
return df.apply(target_filter, axis=1).as_matrix()
|
||||
|
||||
train_df = gen_data(train_size, 42)
|
||||
test_df = gen_data(test_size, 43)
|
||||
|
||||
train_target = get_target(train_df)
|
||||
test_target = get_target(test_df)
|
||||
|
||||
print()
|
||||
print('train target', train_target)
|
||||
print('test target', test_target)
|
||||
|
||||
params = {
|
||||
'iterations': 10,
|
||||
'depth': 4,
|
||||
'learning_rate': 1,
|
||||
'loss_function': 'MultiClass'
|
||||
}
|
||||
|
||||
model = train_catboost_model(train_df, train_target, ['c', 'd'], params)
|
||||
pred_python = model.predict(test_df)[:,0].astype(int)
|
||||
|
||||
server = ClickHouseServerWithCatboostModels(name, CLICKHOUSE_TESTS_SERVER_BIN_PATH, PORT)
|
||||
server.add_model(name, model)
|
||||
with server:
|
||||
pred_ch = np.argmax(np.array(server.apply_model(name, test_df, [])), axis=1)
|
||||
|
||||
print('python predictions', pred_python)
|
||||
print('clickhouse predictions', pred_ch)
|
||||
|
||||
check_predictions(name, test_target, pred_python, pred_ch, 0.9)
|
@ -1094,70 +1094,6 @@ order by number
|
||||
7 6 8
|
||||
8 7 9
|
||||
9 8 9
|
||||
-- nth_value without specific frame range given
|
||||
select
|
||||
number,
|
||||
nth_value(number, 1) over w as firstValue,
|
||||
nth_value(number, 2) over w as secondValue,
|
||||
nth_value(number, 3) over w as thirdValue,
|
||||
nth_value(number, 4) over w as fourthValue
|
||||
from numbers(10)
|
||||
window w as (order by number)
|
||||
order by number
|
||||
;
|
||||
0 0 0 0 0
|
||||
1 0 1 0 0
|
||||
2 0 1 2 0
|
||||
3 0 1 2 3
|
||||
4 0 1 2 3
|
||||
5 0 1 2 3
|
||||
6 0 1 2 3
|
||||
7 0 1 2 3
|
||||
8 0 1 2 3
|
||||
9 0 1 2 3
|
||||
-- nth_value with frame range specified
|
||||
select
|
||||
number,
|
||||
nth_value(number, 1) over w as firstValue,
|
||||
nth_value(number, 2) over w as secondValue,
|
||||
nth_value(number, 3) over w as thirdValue,
|
||||
nth_value(number, 4) over w as fourthValue
|
||||
from numbers(10)
|
||||
window w as (order by number range between 1 preceding and 1 following)
|
||||
order by number
|
||||
;
|
||||
0 0 1 0 0
|
||||
1 0 1 2 0
|
||||
2 1 2 3 0
|
||||
3 2 3 4 0
|
||||
4 3 4 5 0
|
||||
5 4 5 6 0
|
||||
6 5 6 7 0
|
||||
7 6 7 8 0
|
||||
8 7 8 9 0
|
||||
9 8 9 0 0
|
||||
-- to make nth_value return null for out-of-frame rows, cast the argument to
|
||||
-- Nullable; otherwise, it returns default values.
|
||||
SELECT
|
||||
number,
|
||||
nth_value(toNullable(number), 1) OVER w as firstValue,
|
||||
nth_value(toNullable(number), 3) OVER w as thridValue
|
||||
FROM numbers(5)
|
||||
WINDOW w AS (ORDER BY number ASC)
|
||||
;
|
||||
0 0 \N
|
||||
1 0 \N
|
||||
2 0 2
|
||||
3 0 2
|
||||
4 0 2
|
||||
-- nth_value UBsan
|
||||
SELECT nth_value(1, -1) OVER (); -- { serverError BAD_ARGUMENTS }
|
||||
SELECT nth_value(1, 0) OVER (); -- { serverError BAD_ARGUMENTS }
|
||||
SELECT nth_value(1, /* INT64_MAX+1 */ 0x7fffffffffffffff+1) OVER (); -- { serverError BAD_ARGUMENTS }
|
||||
SELECT nth_value(1, /* INT64_MAX */ 0x7fffffffffffffff) OVER ();
|
||||
0
|
||||
SELECT nth_value(1, 1) OVER ();
|
||||
1
|
||||
-- lagInFrame UBsan
|
||||
SELECT lagInFrame(1, -1) OVER (); -- { serverError BAD_ARGUMENTS }
|
||||
SELECT lagInFrame(1, 0) OVER ();
|
||||
|
@ -401,47 +401,6 @@ window w as (order by number range between 1 preceding and 1 following)
|
||||
order by number
|
||||
;
|
||||
|
||||
-- nth_value without specific frame range given
|
||||
select
|
||||
number,
|
||||
nth_value(number, 1) over w as firstValue,
|
||||
nth_value(number, 2) over w as secondValue,
|
||||
nth_value(number, 3) over w as thirdValue,
|
||||
nth_value(number, 4) over w as fourthValue
|
||||
from numbers(10)
|
||||
window w as (order by number)
|
||||
order by number
|
||||
;
|
||||
|
||||
-- nth_value with frame range specified
|
||||
select
|
||||
number,
|
||||
nth_value(number, 1) over w as firstValue,
|
||||
nth_value(number, 2) over w as secondValue,
|
||||
nth_value(number, 3) over w as thirdValue,
|
||||
nth_value(number, 4) over w as fourthValue
|
||||
from numbers(10)
|
||||
window w as (order by number range between 1 preceding and 1 following)
|
||||
order by number
|
||||
;
|
||||
|
||||
-- to make nth_value return null for out-of-frame rows, cast the argument to
|
||||
-- Nullable; otherwise, it returns default values.
|
||||
SELECT
|
||||
number,
|
||||
nth_value(toNullable(number), 1) OVER w as firstValue,
|
||||
nth_value(toNullable(number), 3) OVER w as thridValue
|
||||
FROM numbers(5)
|
||||
WINDOW w AS (ORDER BY number ASC)
|
||||
;
|
||||
|
||||
-- nth_value UBsan
|
||||
SELECT nth_value(1, -1) OVER (); -- { serverError BAD_ARGUMENTS }
|
||||
SELECT nth_value(1, 0) OVER (); -- { serverError BAD_ARGUMENTS }
|
||||
SELECT nth_value(1, /* INT64_MAX+1 */ 0x7fffffffffffffff+1) OVER (); -- { serverError BAD_ARGUMENTS }
|
||||
SELECT nth_value(1, /* INT64_MAX */ 0x7fffffffffffffff) OVER ();
|
||||
SELECT nth_value(1, 1) OVER ();
|
||||
|
||||
-- lagInFrame UBsan
|
||||
SELECT lagInFrame(1, -1) OVER (); -- { serverError BAD_ARGUMENTS }
|
||||
SELECT lagInFrame(1, 0) OVER ();
|
||||
|
@ -0,0 +1 @@
|
||||
SELECT 1
|
7
tests/queries/0_stateless/02031_format_query_option.sh
Executable file
7
tests/queries/0_stateless/02031_format_query_option.sh
Executable file
@ -0,0 +1,7 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
|
||||
# shellcheck source=../shell_config.sh
|
||||
. "$CURDIR"/../shell_config.sh
|
||||
|
||||
${CLICKHOUSE_FORMAT} --query "SELECT 1"
|
@ -167,26 +167,6 @@ find $ROOT_PATH -not -path $ROOT_PATH'/docker*' -not -path $ROOT_PATH'/contrib*'
|
||||
# There shouldn't be any docker compose files outside docker directory
|
||||
#find $ROOT_PATH -not -path $ROOT_PATH'/tests/testflows*' -not -path $ROOT_PATH'/docker*' -not -path $ROOT_PATH'/contrib*' -name '*compose*.yml' -type f 2>/dev/null | xargs --no-run-if-empty grep -l "version:" | xargs --no-run-if-empty -n1 echo "Please move docker compose to docker directory:"
|
||||
|
||||
# Check that ya.make files are auto-generated
|
||||
"$ROOT_PATH"/utils/generate-ya-make/generate-ya-make.sh
|
||||
# FIXME: apparently sandbox (don't confuse it with docker) cloning sources
|
||||
# using some ancient git version, <2.8, that contains one bug for submodules
|
||||
# initialization [1]:
|
||||
#
|
||||
# " * A partial rewrite of "git submodule" in the 2.7 timeframe changed
|
||||
# the way the gitdir: pointer in the submodules point at the real
|
||||
# repository location to use absolute paths by accident. This has
|
||||
# been corrected."
|
||||
#
|
||||
# [1]: https://github.com/git/git/blob/cf11a67975b057a144618badf16dc4e3d25b9407/Documentation/RelNotes/2.8.3.txt#L33-L36
|
||||
#
|
||||
# Due to which "git status" will report the following error:
|
||||
#
|
||||
# fatal: not a git repository: /place/sandbox-data/tasks/0/2/882869720/ClickHouse/.git/modules/contrib/AMQP-CPP
|
||||
#
|
||||
# Anyway this check does not requires any submodule traverse, so it is fine to ignore those errors.
|
||||
git status -uno 2> >(grep "fatal: not a git repository: /place/sandbox-data/tasks/.*/ClickHouse/\\.git/modules/contrib") | grep ya.make && echo "ya.make files should be generated with utils/generate-ya-make/generate-ya-make.sh"
|
||||
|
||||
# Check that every header file has #pragma once in first line
|
||||
find $ROOT_PATH/{src,programs,utils} -name '*.h' |
|
||||
grep -vP $EXCLUDE_DIRS |
|
||||
|
@ -1,16 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# This script searches for ya.make.in files in repository and generates ya.make files from them.
|
||||
# ya.make.in is a template with substitutions in form of <? command ?>
|
||||
# command is interpreted by bash and output is put in place of substitution
|
||||
|
||||
ROOT_PATH=$(git rev-parse --show-toplevel)
|
||||
EXCLUDE_DIRS='build/|integration/|widechar_width/|glibc-compatibility/|memcpy/|consistent-hashing'
|
||||
|
||||
# Otherwise 'sort' behaves differently on Mac OS and also depends on locale.
|
||||
export LC_ALL=C
|
||||
|
||||
find "${ROOT_PATH}" -name 'ya.make.in' | while read path; do
|
||||
echo "# This file is generated automatically, do not edit. See 'ya.make.in' and use 'utils/generate-ya-make' to regenerate it." > "${path/.in/}"
|
||||
(cd $(dirname "${path}") && perl -pne 's/<\?(.+?)\?>/`$1`/e' < "${path}" >> "${path/.in/}")
|
||||
done
|
@ -1,13 +0,0 @@
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
PY23_LIBRARY()
|
||||
|
||||
PY_SRCS(
|
||||
__init__.py
|
||||
backport.py
|
||||
cherrypick.py
|
||||
local.py
|
||||
query.py
|
||||
)
|
||||
|
||||
END()
|
12
ya.make
12
ya.make
@ -1,12 +0,0 @@
|
||||
# What are "ya.make" files?
|
||||
# "ya.make" file is a configuration file for "ya" - an internal Yandex build system that is used to build internal Yandex monorepository.
|
||||
# We don't use nor "ya" build system neither the Yandex monorepository for development of ClickHouse and you should not pay attention to these files.
|
||||
# But ClickHouse source code is synchronized with internal Yandex monorepository, that's why "ya.make" files exist.
|
||||
|
||||
OWNER(g:clickhouse)
|
||||
|
||||
RECURSE(
|
||||
base
|
||||
programs
|
||||
src
|
||||
)
|
Loading…
Reference in New Issue
Block a user