Revert D36052198: Partially remove dependency on folly async

Differential Revision:
D36052198 (ade685c621)

Original commit changeset: 170d64a324a1

Original Phabricator Diff: D36052198 (ade685c621)

fbshipit-source-id: 69d2b18e70a6267667432d6ed9dc1c5bc545b417
This commit is contained in:
Billy Ng
2022-05-12 18:47:41 -07:00
committed by Facebook GitHub Bot
parent ade685c621
commit 3804ccf898
18 changed files with 116 additions and 132 deletions

View File

@@ -8,7 +8,6 @@
#include "FlipperClient.h"
#include <fstream>
#include <iostream>
#include <sstream>
#include <stdexcept>
#include <vector>
#include "ConnectionContextStore.h"

View File

@@ -8,7 +8,6 @@
#pragma once
#include <map>
#include <memory>
#include <mutex>
#include <vector>
#include "FlipperCertificateProvider.h"

View File

@@ -95,8 +95,8 @@ FlipperConnectionManagerImpl::FlipperConnectionManagerImpl(
securePort(config.securePort),
altInsecurePort(config.altInsecurePort),
altSecurePort(config.altSecurePort),
flipperScheduler_(config.callbackWorker),
connectionScheduler_(config.connectionWorker),
flipperEventBase_(config.callbackWorker),
connectionEventBase_(config.connectionWorker),
contextStore_(contextStore),
implWrapper_(std::make_shared<FlipperConnectionManagerWrapper>(this)) {
CHECK_THROW(config.callbackWorker, std::invalid_argument);
@@ -131,10 +131,13 @@ void FlipperConnectionManagerImpl::start() {
auto step = flipperState_->start("Start connection thread");
flipperScheduler_->schedule([this, step]() {
step->complete();
startSync();
});
folly::makeFuture()
.via(flipperEventBase_->getEventBase())
.delayed(std::chrono::milliseconds(0))
.thenValue([this, step](auto&&) {
step->complete();
startSync();
});
}
void FlipperConnectionManagerImpl::startSync() {
@@ -207,7 +210,7 @@ bool FlipperConnectionManagerImpl::connectAndExchangeCertificate() {
payload->medium = medium;
auto newClient = FlipperSocketProvider::socketCreate(
endpoint, std::move(payload), flipperScheduler_);
endpoint, std::move(payload), connectionEventBase_);
newClient->setEventHandler(ConnectionEvents(implWrapper_));
auto connectingInsecurely = flipperState_->start("Connect insecurely");
@@ -256,7 +259,7 @@ bool FlipperConnectionManagerImpl::connectSecurely() {
payload->csr_path = contextStore_->getCertificateDirectoryPath().c_str();
auto newClient = FlipperSocketProvider::socketCreate(
endpoint, std::move(payload), connectionScheduler_, contextStore_.get());
endpoint, std::move(payload), connectionEventBase_, contextStore_.get());
newClient->setEventHandler(ConnectionEvents(implWrapper_));
newClient->setMessageHandler([this](const std::string& msg) {
std::unique_ptr<FireAndForgetBasedFlipperResponder> responder;
@@ -291,8 +294,10 @@ void FlipperConnectionManagerImpl::reconnect() {
log("Not started");
return;
}
flipperScheduler_->scheduleAfter(
[this]() { startSync(); }, reconnectIntervalSeconds * 1000.0f);
folly::makeFuture()
.via(flipperEventBase_->getEventBase())
.delayed(std::chrono::seconds(reconnectIntervalSeconds))
.thenValue([this](auto&&) { startSync(); });
}
void FlipperConnectionManagerImpl::stop() {
@@ -320,7 +325,7 @@ void FlipperConnectionManagerImpl::setCallbacks(Callbacks* callbacks) {
}
void FlipperConnectionManagerImpl::sendMessage(const folly::dynamic& message) {
flipperScheduler_->schedule([this, message]() {
flipperEventBase_->add([this, message]() {
try {
if (client_) {
client_->send(message, []() {});
@@ -452,11 +457,11 @@ void FlipperConnectionManagerImpl::requestSignedCertificate() {
auto gettingCert = flipperState_->start("Getting cert from desktop");
certificateExchangeCompleted_ = false;
flipperScheduler_->schedule([this, message, gettingCert]() {
flipperEventBase_->add([this, message, gettingCert]() {
client_->sendExpectResponse(
folly::toJson(message),
[this, gettingCert](const std::string& response, bool isError) {
flipperScheduler_->schedule([this, gettingCert, response, isError]() {
flipperEventBase_->add([this, gettingCert, response, isError]() {
this->processSignedCertificateResponse(
gettingCert, response, isError);
});
@@ -466,7 +471,7 @@ void FlipperConnectionManagerImpl::requestSignedCertificate() {
}
bool FlipperConnectionManagerImpl::isRunningInOwnThread() {
return flipperScheduler_->isRunningInOwnThread();
return flipperEventBase_->isInEventBaseThread();
}
} // namespace flipper

View File

@@ -7,10 +7,11 @@
#pragma once
#include <folly/Executor.h>
#include <folly/io/async/EventBase.h>
#include <mutex>
#include "FlipperConnectionManager.h"
#include "FlipperInitConfig.h"
#include "FlipperScheduler.h"
#include "FlipperSocket.h"
#include "FlipperState.h"
@@ -63,8 +64,8 @@ class FlipperConnectionManagerImpl : public FlipperConnectionManager {
int altInsecurePort;
int altSecurePort;
Scheduler* flipperScheduler_;
Scheduler* connectionScheduler_;
folly::EventBase* flipperEventBase_;
folly::EventBase* connectionEventBase_;
std::unique_ptr<FlipperSocket> client_;

View File

@@ -7,8 +7,8 @@
#pragma once
#include <folly/io/async/EventBase.h>
#include <map>
#include "FlipperScheduler.h"
namespace facebook {
namespace flipper {
@@ -30,14 +30,14 @@ struct FlipperInitConfig {
DeviceData deviceData;
/**
Scheduler on which client callbacks should be called.
EventBase on which client callbacks should be called.
*/
Scheduler* callbackWorker;
folly::EventBase* callbackWorker;
/**
Scheduler to be used to maintain the network connection.
EventBase to be used to maintain the network connection.
*/
Scheduler* connectionWorker;
folly::EventBase* connectionWorker;
int insecurePort = 9089;
int securePort = 9088;

View File

@@ -21,19 +21,19 @@ std::unique_ptr<FlipperSocketProvider> FlipperSocketProvider::shelvedProvider_ =
std::unique_ptr<FlipperSocket> FlipperSocketProvider::socketCreate(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler) {
return provider_->create(std::move(endpoint), std::move(payload), scheduler);
folly::EventBase* eventBase) {
return provider_->create(std::move(endpoint), std::move(payload), eventBase);
}
std::unique_ptr<FlipperSocket> FlipperSocketProvider::socketCreate(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler,
folly::EventBase* eventBase,
ConnectionContextStore* connectionContextStore) {
return provider_->create(
std::move(endpoint),
std::move(payload),
scheduler,
eventBase,
connectionContextStore);
}

View File

@@ -7,8 +7,8 @@
#pragma once
#include <folly/io/async/EventBase.h>
#include <memory>
#include "FlipperScheduler.h"
namespace facebook {
namespace flipper {
@@ -32,37 +32,35 @@ class FlipperSocketProvider {
@param endpoint Endpoint to connect to.
@param payload Any configuration payload to establish a connection with
the specified endpoint.
@param scheduler An scheduler used to schedule and execute connection
operations.
@param eventBase A folly event base used to execute connection operations.
*/
virtual std::unique_ptr<FlipperSocket> create(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler) = 0;
folly::EventBase* eventBase) = 0;
/**
Create an instance of FlipperSocket.
@param endpoint Endpoint to connect to.
@param payload Any configuration payload to establish a connection with
the specified endpoint.
@param scheduler An scheduler used to schedule and execute connection
operations.
@param eventBase A folly event base used to execute connection operations.
@param connectionContextStore A connection context store used for obtaining
the certificate used for secure connections.
*/
virtual std::unique_ptr<FlipperSocket> create(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler,
folly::EventBase* eventBase,
ConnectionContextStore* connectionContextStore) = 0;
static std::unique_ptr<FlipperSocket> socketCreate(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler);
folly::EventBase* eventBase);
static std::unique_ptr<FlipperSocket> socketCreate(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler,
folly::EventBase* eventBase,
ConnectionContextStore* connectionContextStore);
static void setDefaultProvider(

View File

@@ -6,11 +6,10 @@
*/
#include <Flipper/FlipperConnectionManagerImpl.h>
#include <Flipper/FlipperFollyScheduler.h>
#include <FlipperTestLib/ConnectionContextStoreMock.h>
#include <folly/Singleton.h>
#include <gtest/gtest.h>
#include <memory>
namespace facebook {
namespace flipper {
@@ -22,16 +21,12 @@ class FlipperConnectionManagerImplTerminationTest : public ::testing::Test {
protected:
std::shared_ptr<FlipperState> state;
std::shared_ptr<ConnectionContextStore> contextStore;
std::unique_ptr<Scheduler> sonarScheduler;
std::unique_ptr<Scheduler> connectionScheduler;
void SetUp() override {
// Folly singletons must be registered before they are used.
// Without this, test fails in phabricator.
folly::SingletonVault::singleton()->registrationComplete();
state = std::make_shared<FlipperState>();
contextStore = std::make_shared<ConnectionContextStoreMock>();
sonarScheduler = std::make_unique<FollyScheduler>(new EventBase());
connectionScheduler = std::make_unique<FollyScheduler>(new EventBase());
}
};
@@ -40,7 +35,7 @@ TEST_F(
testNullEventBaseGetsRejected) {
try {
auto instance = std::make_shared<FlipperConnectionManagerImpl>(
FlipperInitConfig{DeviceData{}, nullptr, connectionScheduler.get()},
FlipperInitConfig{DeviceData{}, nullptr, new EventBase()},
state,
contextStore);
FAIL();
@@ -49,7 +44,7 @@ TEST_F(
}
try {
auto instance = std::make_shared<FlipperConnectionManagerImpl>(
FlipperInitConfig{DeviceData{}, sonarScheduler.get(), nullptr},
FlipperInitConfig{DeviceData{}, new EventBase(), nullptr},
state,
contextStore);
FAIL();
@@ -61,8 +56,8 @@ TEST_F(
TEST_F(
FlipperConnectionManagerImplTerminationTest,
testNonStartedEventBaseDoesntHang) {
auto config = FlipperInitConfig{
DeviceData{}, sonarScheduler.get(), connectionScheduler.get()};
auto config =
FlipperInitConfig{DeviceData{}, new EventBase(), new EventBase()};
auto instance = std::make_shared<FlipperConnectionManagerImpl>(
config, state, contextStore);
instance->start();
@@ -77,11 +72,8 @@ TEST_F(
std::thread([flipperEventBase]() { flipperEventBase->loopForever(); });
auto connectionThread = std::thread(
[connectionEventBase]() { connectionEventBase->loopForever(); });
auto localSonarScheduler = std::make_unique<FollyScheduler>(flipperEventBase);
auto localConnectionScheduler =
std::make_unique<FollyScheduler>(connectionEventBase);
auto config = FlipperInitConfig{
DeviceData{}, localSonarScheduler.get(), localConnectionScheduler.get()};
auto config =
FlipperInitConfig{DeviceData{}, flipperEventBase, connectionEventBase};
auto instance = std::make_shared<FlipperConnectionManagerImpl>(
config, state, contextStore);

View File

@@ -9,11 +9,11 @@
#pragma once
#include <Flipper/FlipperScheduler.h>
#include <Flipper/FlipperSocket.h>
#include <Flipper/FlipperSocketProvider.h>
#include <Flipper/FlipperTransportTypes.h>
#include <folly/dynamic.h>
#include <folly/io/async/EventBase.h>
#include <future>
#include <memory>
#include <mutex>
@@ -37,18 +37,18 @@ class BaseClient {
BaseClient(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler)
folly::EventBase* eventBase)
: endpoint_(std::move(endpoint)),
payload_(std::move(payload)),
scheduler_(scheduler) {}
eventBase_(eventBase) {}
BaseClient(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler,
folly::EventBase* eventBase,
ConnectionContextStore* connectionContextStore)
: endpoint_(std::move(endpoint)),
payload_(std::move(payload)),
scheduler_(scheduler),
eventBase_(eventBase),
connectionContextStore_(connectionContextStore) {}
BaseClient(const BaseClient&) = delete;
@@ -84,7 +84,7 @@ class BaseClient {
protected:
FlipperConnectionEndpoint endpoint_;
std::unique_ptr<FlipperSocketBasePayload> payload_;
Scheduler* scheduler_;
folly::EventBase* eventBase_;
ConnectionContextStore* connectionContextStore_;
SocketEventHandler eventHandler_;

View File

@@ -14,6 +14,8 @@
#include <Flipper/Log.h>
#include <folly/String.h>
#include <folly/futures/Future.h>
#include <folly/io/async/AsyncSocketException.h>
#include <folly/io/async/SSLContext.h>
#include <folly/json.h>
#include <cctype>
#include <iomanip>
@@ -30,24 +32,24 @@ namespace flipper {
FlipperWebSocket::FlipperWebSocket(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler)
folly::EventBase* eventBase)
: FlipperWebSocket(
std::move(endpoint),
std::move(payload),
scheduler,
eventBase,
nullptr) {}
FlipperWebSocket::FlipperWebSocket(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler,
folly::EventBase* eventBase,
ConnectionContextStore* connectionContextStore) {
if (endpoint.secure) {
socket_ = std::make_unique<WebSocketTLSClient>(
endpoint, std::move(payload), scheduler, connectionContextStore);
endpoint, std::move(payload), eventBase, connectionContextStore);
} else {
socket_ = std::make_unique<WebSocketClient>(
endpoint, std::move(payload), scheduler, connectionContextStore);
endpoint, std::move(payload), eventBase, connectionContextStore);
}
}

View File

@@ -9,11 +9,11 @@
#pragma once
#include <Flipper/FlipperScheduler.h>
#include <Flipper/FlipperSocket.h>
#include <Flipper/FlipperSocketProvider.h>
#include <Flipper/FlipperTransportTypes.h>
#include <folly/dynamic.h>
#include <folly/io/async/EventBase.h>
#include <future>
#include <memory>
#include <mutex>
@@ -29,11 +29,11 @@ class FlipperWebSocket : public FlipperSocket {
FlipperWebSocket(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler);
folly::EventBase* eventBase);
FlipperWebSocket(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler,
folly::EventBase* eventBase,
ConnectionContextStore* connectionContextStore);
virtual ~FlipperWebSocket();
@@ -62,19 +62,19 @@ class FlipperWebSocketProvider : public FlipperSocketProvider {
virtual std::unique_ptr<FlipperSocket> create(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler) override {
folly::EventBase* eventBase) override {
return std::make_unique<FlipperWebSocket>(
std::move(endpoint), std::move(payload), scheduler);
std::move(endpoint), std::move(payload), eventBase);
}
virtual std::unique_ptr<FlipperSocket> create(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler,
folly::EventBase* eventBase,
ConnectionContextStore* connectionContextStore) override {
return std::make_unique<FlipperWebSocket>(
std::move(endpoint),
std::move(payload),
scheduler,
eventBase,
connectionContextStore);
}
};

View File

@@ -14,6 +14,7 @@
#include <Flipper/Log.h>
#include <folly/String.h>
#include <folly/futures/Future.h>
#include <folly/io/async/SSLContext.h>
#include <folly/json.h>
#include <websocketpp/common/memory.hpp>
#include <websocketpp/common/thread.hpp>
@@ -30,22 +31,22 @@ namespace flipper {
WebSocketClient::WebSocketClient(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler)
folly::EventBase* eventBase)
: WebSocketClient(
std::move(endpoint),
std::move(payload),
scheduler,
eventBase,
nullptr) {}
WebSocketClient::WebSocketClient(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler,
folly::EventBase* eventBase,
ConnectionContextStore* connectionContextStore)
: BaseClient(
std::move(endpoint),
std::move(payload),
scheduler,
eventBase,
connectionContextStore) {
status_ = Status::Unconnected;
@@ -147,7 +148,7 @@ void WebSocketClient::disconnect() {
thread_->join();
}
thread_ = nullptr;
scheduler_->schedule(
eventBase_->add(
[eventHandler = eventHandler_]() { eventHandler(SocketEvent::CLOSE); });
}
@@ -179,12 +180,12 @@ void WebSocketClient::send(
void WebSocketClient::sendExpectResponse(
const std::string& message,
SocketSendExpectResponseHandler completion) {
connection_->set_message_handler([completion, scheduler = scheduler_](
websocketpp::connection_hdl hdl,
SocketClient::message_ptr msg) {
const std::string& payload = msg->get_payload();
scheduler->schedule([completion, payload] { completion(payload, false); });
});
connection_->set_message_handler(
[completion, eventBase = eventBase_](
websocketpp::connection_hdl hdl, SocketClient::message_ptr msg) {
const std::string& payload = msg->get_payload();
eventBase->add([completion, payload] { completion(payload, false); });
});
websocketpp::lib::error_code ec;
socket_.send(
handle_,
@@ -204,7 +205,7 @@ void WebSocketClient::onOpen(SocketClient* c, websocketpp::connection_hdl hdl) {
}
status_ = Status::Initializing;
scheduler_->schedule(
eventBase_->add(
[eventHandler = eventHandler_]() { eventHandler(SocketEvent::OPEN); });
}
@@ -214,7 +215,7 @@ void WebSocketClient::onMessage(
SocketClient::message_ptr msg) {
const std::string& payload = msg->get_payload();
if (messageHandler_) {
scheduler_->schedule([payload, messageHandler = messageHandler_]() {
eventBase_->add([payload, messageHandler = messageHandler_]() {
messageHandler(payload);
});
}
@@ -229,7 +230,7 @@ void WebSocketClient::onFail(SocketClient* c, websocketpp::connection_hdl hdl) {
connected_.set_value(false);
}
status_ = Status::Failed;
scheduler_->schedule(
eventBase_->add(
[eventHandler = eventHandler_]() { eventHandler(SocketEvent::ERROR); });
}
@@ -237,7 +238,7 @@ void WebSocketClient::onClose(
SocketClient* c,
websocketpp::connection_hdl hdl) {
status_ = Status::Closed;
scheduler_->schedule(
eventBase_->add(
[eventHandler = eventHandler_]() { eventHandler(SocketEvent::CLOSE); });
}

View File

@@ -9,11 +9,11 @@
#pragma once
#include <Flipper/FlipperScheduler.h>
#include <Flipper/FlipperSocket.h>
#include <Flipper/FlipperSocketProvider.h>
#include <Flipper/FlipperTransportTypes.h>
#include <folly/dynamic.h>
#include <folly/io/async/EventBase.h>
#include <future>
#include <memory>
#include <mutex>
@@ -35,11 +35,11 @@ class WebSocketClient : public BaseClient {
WebSocketClient(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler);
folly::EventBase* eventBase);
WebSocketClient(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler,
folly::EventBase* eventBase,
ConnectionContextStore* connectionContextStore);
WebSocketClient(const WebSocketClient&) = delete;

View File

@@ -33,22 +33,22 @@ namespace flipper {
WebSocketTLSClient::WebSocketTLSClient(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler)
folly::EventBase* eventBase)
: WebSocketTLSClient(
std::move(endpoint),
std::move(payload),
scheduler,
eventBase,
nullptr) {}
WebSocketTLSClient::WebSocketTLSClient(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler,
folly::EventBase* eventBase,
ConnectionContextStore* connectionContextStore)
: BaseClient(
std::move(endpoint),
std::move(payload),
scheduler,
eventBase,
connectionContextStore) {
status_ = Status::Unconnected;
@@ -157,7 +157,7 @@ void WebSocketTLSClient::disconnect() {
}
thread_ = nullptr;
scheduler_->schedule(
eventBase_->add(
[eventHandler = eventHandler_]() { eventHandler(SocketEvent::CLOSE); });
}
@@ -189,12 +189,12 @@ void WebSocketTLSClient::send(
void WebSocketTLSClient::sendExpectResponse(
const std::string& message,
SocketSendExpectResponseHandler completion) {
connection_->set_message_handler([completion, scheduler = scheduler_](
websocketpp::connection_hdl hdl,
SocketTLSClient::message_ptr msg) {
const std::string& payload = msg->get_payload();
scheduler->schedule([completion, payload] { completion(payload, false); });
});
connection_->set_message_handler(
[completion, eventBase = eventBase_](
websocketpp::connection_hdl hdl, SocketTLSClient::message_ptr msg) {
const std::string& payload = msg->get_payload();
eventBase->add([completion, payload] { completion(payload, false); });
});
websocketpp::lib::error_code ec;
socket_.send(
handle_,
@@ -216,7 +216,7 @@ void WebSocketTLSClient::onOpen(
}
status_ = Status::Initializing;
scheduler_->schedule(
eventBase_->add(
[eventHandler = eventHandler_]() { eventHandler(SocketEvent::OPEN); });
}
@@ -226,7 +226,7 @@ void WebSocketTLSClient::onMessage(
SocketTLSClient::message_ptr msg) {
const std::string& payload = msg->get_payload();
if (messageHandler_) {
scheduler_->schedule([payload, messageHandler = messageHandler_]() {
eventBase_->add([payload, messageHandler = messageHandler_]() {
messageHandler(payload);
});
}
@@ -257,7 +257,7 @@ void WebSocketTLSClient::onFail(
}
}
status_ = Status::Failed;
scheduler_->schedule([eventHandler = eventHandler_, sslError]() {
eventBase_->add([eventHandler = eventHandler_, sslError]() {
if (sslError) {
eventHandler(SocketEvent::SSL_ERROR);
} else {
@@ -270,7 +270,7 @@ void WebSocketTLSClient::onClose(
SocketTLSClient* c,
websocketpp::connection_hdl hdl) {
status_ = Status::Closed;
scheduler_->schedule(
eventBase_->add(
[eventHandler = eventHandler_]() { eventHandler(SocketEvent::CLOSE); });
}

View File

@@ -13,6 +13,7 @@
#include <Flipper/FlipperSocketProvider.h>
#include <Flipper/FlipperTransportTypes.h>
#include <folly/dynamic.h>
#include <folly/io/async/EventBase.h>
#include <future>
#include <memory>
#include <mutex>
@@ -38,11 +39,11 @@ class WebSocketTLSClient : public BaseClient {
WebSocketTLSClient(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler);
folly::EventBase* eventBase);
WebSocketTLSClient(
FlipperConnectionEndpoint endpoint,
std::unique_ptr<FlipperSocketBasePayload> payload,
Scheduler* scheduler,
folly::EventBase* eventBase,
ConnectionContextStore* connectionContextStore);
WebSocketTLSClient(const WebSocketTLSClient&) = delete;