blob: f8b9f89ab0c3e6c60aca7bcf7a1b6b7c2fe878f8 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include "domainconfig.h"
#include <vespa/vespalib/util/exceptions.h>
namespace search::transactionlog {
DomainConfig::DomainConfig()
: _encoding(Encoding::Crc::xxh64, Encoding::Compression::zstd),
_compressionLevel(9),
_fSyncOnCommit(false),
_partSizeLimit(0x10000000), // 256M
_chunkSizeLimit(0x40000) // 256k
{ }
DomainConfig &
DomainConfig::setEncoding(Encoding v) {
if (v.getCompression() == Encoding::none) {
throw vespalib::IllegalArgumentException("Compression:none is not allowed for the tls", VESPA_STRLOC);
}
_encoding = v;
return *this;
}
}
|