blob: ff8e9cbb89aa0bbb6690b41918e78f4e85e4a1e6 (
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
26
27
28
29
30
31
32
33
34
35
36
|
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
#include <vespa/messagebus/common.h>
#include <vespa/slobrok/cfg.h>
#include <thread>
namespace slobrok {
class SBEnv;
} // namespace slobrok
namespace mbus {
class Slobrok
{
private:
std::unique_ptr<slobrok::SBEnv> _env;
int _port;
std::thread _thread;
Slobrok(const Slobrok &);
Slobrok &operator=(const Slobrok &);
void init();
public:
using UP = std::unique_ptr<Slobrok>;
Slobrok();
Slobrok(int port);
~Slobrok();
int port() const;
config::ConfigUri config() const;
};
} // namespace mbus
|