Big refactor.

This commit is contained in:
Pedro Pinto committed 2017-09-25 20:18:28 +00:00
1 parent 3a519f748b
commit 6157decd62
88 files changed
+123 -3964

No files matched your search

+31 -16
View File
@@ -1,24 +1,42 @@
#include "lib/os/os.h"
#include "lib/logging/logging.h"
#include "lib/config/config.h"
#include "lib/config/protos/logging.pb.h"
#include "lib/config/protos/Executor.pb.h"
#include "lib/utils/init_spark_lib.h"
#include "setup/BootstrapActor.h"
#include "fabric/Domain.h"
#include "testing/catch_test_runner.h"
#include "server/sparkd/order_man/native_orders/NativeOrderHeader.h"
#include "server/sparkd/order_man/native_orders/NativeOrderState.h"
#include "lib/config/config.h"
#include "lib/config/protos/quickbus_cfg.pb.h"
#include "lib/config/protos/Ports.pb.h"
#include "lib/quickbus/quickbus.h"
#include "lib/api/public/ServiceContext.h"
#include "server/sparkd/persistence/PersistenceServiceServer.h"
#include "server/sparkd/user/UserServiceServer.h"
#include "server/sparkd/md/run_md.h"
#include "lib/md/relay/QueryServer.h"
namespace bts {
config::QuickbusNodeCfg make_cfg()
{
config::QuickbusNodeCfg result;
result.set_my_port(config::get<config::Ports>().qbus_port());
return result;
}
void start_services()
{
qbus::Quickbus quickbus;
api::ServiceContext sc(&quickbus);
persistence::PersistenceServiceServer settings_saver(sc,"settings");
user::UserServiceServer login_server(sc);
run_market_datapublishers();
md::QueryServerPtr md_query_server(md::run_query_server(sc));
std::this_thread::sleep_until(std::chrono::time_point<std::chrono::system_clock>::max());
}
}
int main( int argc, char*argv [] )
{
std::cout << sizeof(bts::orderman::NativeOrderState) << std::endl;
std::cout << sizeof(bts::orderman::NativeOrderHeader) << std::endl;
return 1;
using namespace bts;
os::set_thread_name("main");
@@ -26,10 +44,7 @@ int main( int argc, char*argv [] )
bts::run_tests(--argc, ++argv);
else {
utils::init_spark_lib();
auto executor_cfg = config::get<config::ExecutorCfg> ();
fabric::Domain d (executor_cfg,std::make_unique<setup::BootstrapActor>(executor_cfg));
std::this_thread::sleep_until(std::chrono::time_point<std::chrono::system_clock>::max());
start_services();
utils::finit_spark_lib();
}
return 0;