7#ifndef BOOST_REDIS_LOGGER_HPP
8#define BOOST_REDIS_LOGGER_HPP
10#include <boost/redis/response.hpp>
11#include <boost/asio/ip/tcp.hpp>
14namespace boost::system {
class error_code;}
16namespace boost::redis {
77 void on_resolve(system::error_code
const& ec, asio::ip::tcp::resolver::results_type
const& res);
85 void on_connect(system::error_code
const& ec, asio::ip::tcp::endpoint
const& ep);
100 void on_write(system::error_code
const& ec, std::string
const& payload);
108 void on_read(system::error_code
const& ec, std::size_t n);
128 void trace(std::string_view message);
129 void trace(std::string_view op, system::error_code
const& ec);
134 std::string_view prefix_;
logger(level l=level::debug)
Constructor.
void set_prefix(std::string_view prefix)
Sets a prefix to every log message.
level
Syslog-like log levels.
void on_resolve(system::error_code const &ec, asio::ip::tcp::resolver::results_type const &res)
Called when the resolve operation completes.
void on_ssl_handshake(system::error_code const &ec)
Called when the ssl handshake operation completes.
void on_connect(system::error_code const &ec, asio::ip::tcp::endpoint const &ep)
Called when the connect operation completes.
adapter::result< std::vector< resp3::node > > generic_response
A generic response to a request.
void on_write(system::error_code const &ec, std::string const &payload)
Called when the write operation completes.
void on_hello(system::error_code const &ec, generic_response const &resp)
Called when the HELLO request completes.
void on_read(system::error_code const &ec, std::size_t n)
Called when the read operation completes.