Skip to content

Commit

Permalink
Conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
al13n321 committed Nov 17, 2023
1 parent 46637d8 commit 8909eaf
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions src/Interpreters/Context.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2657,7 +2657,7 @@ void Context::clearMMappedFileCache() const

void Context::setSecondaryIndexCache(const String & cache_policy, size_t max_size_in_bytes, size_t max_count, double size_ratio)
{
auto lock = getLock();
std::lock_guard lock(shared->mutex);

if (shared->secondary_index_cache)
throw Exception(ErrorCodes::LOGICAL_ERROR, "Secondary index cache has been already created.");
Expand All @@ -2667,7 +2667,7 @@ void Context::setSecondaryIndexCache(const String & cache_policy, size_t max_siz

void Context::updateSecondaryIndexCacheConfiguration(const Poco::Util::AbstractConfiguration & config)
{
auto lock = getLock();
std::lock_guard lock(shared->mutex);

if (!shared->secondary_index_cache)
throw Exception(ErrorCodes::LOGICAL_ERROR, "Secondary index cache was not created yet.");
Expand All @@ -2678,13 +2678,13 @@ void Context::updateSecondaryIndexCacheConfiguration(const Poco::Util::AbstractC

SecondaryIndexCachePtr Context::getSecondaryIndexCache() const
{
auto lock = getLock();
SharedLockGuard lock(shared->mutex);
return shared->secondary_index_cache;
}

void Context::clearSecondaryIndexCache() const
{
auto lock = getLock();
std::lock_guard lock(shared->mutex);

if (shared->secondary_index_cache)
shared->secondary_index_cache->clear();
Expand Down
2 changes: 1 addition & 1 deletion utils/check-style/check-large-objects.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Check that there are no new translation units compiled to an object file larger than a certain size.

if find $1 -name '*.o' | xargs wc -c | grep -v total | sort -rn | awk '{ if ($1 > 50000000) print }' \
| grep -v -P 'CastOverloadResolver|AggregateFunctionMax|AggregateFunctionMin|RangeHashedDictionary|Aggregator|AggregateFunctionUniq'
| grep -v -P 'CastOverloadResolver|AggregateFunctionMax|AggregateFunctionMin|HashedDictionary|Aggregator|AggregateFunctionUniq'
then
echo "^ It's not allowed to have so large translation units."
exit 1
Expand Down

0 comments on commit 8909eaf

Please sign in to comment.