Renamed simple_file_sink -> basic_file_sink

This commit is contained in:
gabime
2018-07-07 12:12:45 +03:00
parent 69c11ea7d2
commit cd4dcbab36
14 changed files with 54 additions and 61 deletions

View File

@@ -10,7 +10,7 @@
#include "spdlog/sinks/daily_file_sink.h"
#include "spdlog/sinks/null_sink.h"
#include "spdlog/sinks/rotating_file_sink.h"
#include "spdlog/sinks/simple_file_sink.h"
#include "spdlog/sinks/basic_file_sink.h"
#include "spdlog/spdlog.h"
#include "utils.h"
#include <atomic>
@@ -84,7 +84,7 @@ int main(int argc, char *argv[])
for (int i = 0; i < 3; ++i)
{
spdlog::init_thread_pool(queue_size, 1);
auto as = spdlog::basic_logger_mt<spdlog::create_async>("as", "logs/basic_async.log", true);
auto as = spdlog::basic_logger_mt<spdlog::async_factory>("as", "logs/basic_async.log", true);
bench_mt(howmany, as, threads);
spdlog::drop("as");
}

View File

@@ -11,7 +11,7 @@
#include <vector>
#include "spdlog/async.h"
#include "spdlog/sinks/simple_file_sink.h"
#include "spdlog/sinks/basic_file_sink.h"
using namespace std;
@@ -27,7 +27,7 @@ int main(int argc, char *argv[])
int howmany = 1000000;
spdlog::init_thread_pool(howmany, 1);
auto logger = spdlog::create_async_logger<spdlog::sinks::simple_file_sink_mt>("file_logger", "logs/spdlog-bench-async.log", false);
auto logger = spdlog::create_async_logger<spdlog::sinks::basic_file_sink_mt>("file_logger", "logs/spdlog-bench-async.log", false);
logger->set_pattern("[%Y-%m-%d %T.%F]: %L %t %v");
std::cout << "To stop, press <Enter>" << std::endl;