MiniOB 1
MiniOB is one mini database, helping developers to learn how database works.
载入中...
搜索中...
未找到
server_param.h
1/* Copyright (c) 2021 OceanBase and/or its affiliates. All rights reserved.
2miniob is licensed under Mulan PSL v2.
3You can use this software according to the terms and conditions of the Mulan PSL v2.
4You may obtain a copy of Mulan PSL v2 at:
5 http://license.coscl.org.cn/MulanPSL2
6THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
7EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
8MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
9See the Mulan PSL v2 for more details. */
10
11//
12// Created by Longda on 2021/4/13.
13//
14
15#pragma once
16
17#include <string>
18#include "net/communicator.h"
19
25{
26public:
28
29 ServerParam(const ServerParam &other) = default;
30 ~ServerParam() = default;
31
32public:
33 // accpet client's address, default is INADDR_ANY, means accept every address
34 long listen_addr;
35
37
38 int port;
39
40 std::string unix_socket_path;
41
42 bool use_std_io = false;
43
46 bool use_unix_socket = false;
47
49};
服务端启动参数
Definition: server_param.h:25
int port
监听的端口号
Definition: server_param.h:38
std::string unix_socket_path
unix socket的路径
Definition: server_param.h:40
CommunicateProtocol protocol
通讯协议,目前支持文本协议和mysql协议
Definition: server_param.h:48
bool use_std_io
是否使用标准输入输出作为通信条件
Definition: server_param.h:42
int max_connection_num
最大连接数
Definition: server_param.h:36
CommunicateProtocol
当前支持的通讯协议
Definition: communicator.h:104