Commit eda38331 authored by jan.koester's avatar jan.koester
Browse files

test

parent df1c24aa
Loading
Loading
Loading
Loading
Loading
+5 −1
Changes for src/cluster.cpp: 5 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -36,6 +36,8 @@

#include <netplus/exception.h>
#include <crypto/sha.h>
#include <crypto/x509.h>
#include <crypto/rsa.h>

#include <cstring>
#include <iostream>
@@ -201,6 +203,8 @@ namespace authdb {

        server_ = std::make_unique<paritypp::server>(scfg, store_, auth_);

        server_->run();

        // Setup client for talking to peers
        if (!cfg_.peers.empty()) {
            std::vector<paritypp::client::node_info> nodes;
@@ -236,7 +240,7 @@ namespace authdb {

    void Cluster::server_loop() {
        try {
            server_->run();
            server_->runEventloop();
        } catch (const netplus::NetException &e) {
            std::cerr << "Cluster server error: " << e.what() << std::endl;
        } catch (const std::exception &e) {
+3 −0
Changes for src/cluster.h: 3 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -39,6 +39,8 @@
#include <paritypp/client.h>
#include <paritypp/auth.h>

#include <socket.h>

#include "session.h"
#include "backend.h"
#include "authdb.h"
@@ -152,6 +154,7 @@ namespace authdb {

        std::shared_ptr<paritypp::block_store> store_;
        std::shared_ptr<paritypp::auth_store> auth_;
        std::unique_ptr<netplus::quic> quic_socket_;
        std::unique_ptr<paritypp::server> server_;

        std::unique_ptr<paritypp::client> pclient_;