Consolidate transport related parameters into a struct.

Also, replace leftover cast with getMainConf().
This commit is contained in:
Pavel Pautov 2024-11-21 21:46:01 -08:00 committed by Sergey A. Osokin
parent 3b6667c808
commit a23ffa955c
3 changed files with 20 additions and 11 deletions

View file

@ -111,10 +111,10 @@ public:
int attrSize{0};
};
BatchExporter(StrView target, bool ssl, const std::string& trustedCert,
BatchExporter(const Target& target,
size_t batchSize, size_t batchCount,
const std::map<StrView, StrView>& resourceAttrs) :
batchSize(batchSize), client(std::string(target), ssl, trustedCert)
batchSize(batchSize), client(target)
{
free.reserve(batchCount);
while (batchCount-- > 0) {