Unverified Commit 206a03e8 authored by Dominik Charousset's avatar Dominik Charousset Committed by GitHub

Merge pull request #714

Remove ASIO-based multiplexer
parents 2f562cfb 38a661d8
...@@ -389,23 +389,6 @@ to_int_value(CAF_NO_EXCEPTIONS) ...@@ -389,23 +389,6 @@ to_int_value(CAF_NO_EXCEPTIONS)
to_int_value(CAF_NO_MEM_MANAGEMENT) to_int_value(CAF_NO_MEM_MANAGEMENT)
to_int_value(CAF_ENABLE_RUNTIME_CHECKS) to_int_value(CAF_ENABLE_RUNTIME_CHECKS)
# find boost asio if the asio multiplexer should be used for testing
if(CAF_USE_ASIO)
set(Boost_USE_MULTITHREADED ON)
find_package(Boost COMPONENTS system)
if(Boost_FOUND)
include_directories(${Boost_INCLUDE_DIRS})
set(LD_DIRS ${LD_DIRS} ${Boost_LIBRARIES})
list(APPEND LDFLAGS ${Boost_SYSTEM_LIBRARY})
set(CAF_USE_ASIO_INT 1)
else()
set(CAF_USE_ASIO no)
set(CAF_USE_ASIO_INT -1)
endif()
else()
set(CAF_USE_ASIO_INT -1)
endif()
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/cmake/build_config.hpp.in" configure_file("${CMAKE_CURRENT_SOURCE_DIR}/cmake/build_config.hpp.in"
"${CMAKE_CURRENT_SOURCE_DIR}/libcaf_core/caf/detail/build_config.hpp" "${CMAKE_CURRENT_SOURCE_DIR}/libcaf_core/caf/detail/build_config.hpp"
IMMEDIATE @ONLY) IMMEDIATE @ONLY)
...@@ -639,11 +622,6 @@ if(NOT CAF_NO_UNIT_TESTS) ...@@ -639,11 +622,6 @@ if(NOT CAF_NO_UNIT_TESTS)
string(REPLACE " " "_" test_name ${suite}) string(REPLACE " " "_" test_name ${suite})
set(caf_test ${EXECUTABLE_OUTPUT_PATH}/caf-test) set(caf_test ${EXECUTABLE_OUTPUT_PATH}/caf-test)
add_test(${test_name} ${caf_test} -n -v 5 -s "${suite}" ${ARGN}) add_test(${test_name} ${caf_test} -n -v 5 -s "${suite}" ${ARGN})
# add some extra unit testing options when testing ASIO as well
if(CAF_USE_ASIO AND "${suite}" MATCHES "^io_.+$" AND NOT "${suite}" MATCHES ".+_udp$")
add_test(${test_name}_asio ${caf_test} -n -v 5 -s
"${suite}" ${ARGN} -- "--caf#middleman.network-backend=asio")
endif()
endmacro () endmacro ()
list(LENGTH suites num_suites) list(LENGTH suites num_suites)
message(STATUS "Found ${num_suites} test suites") message(STATUS "Found ${num_suites} test suites")
......
...@@ -69,7 +69,6 @@ unixOpts = "-DCAF_NO_PROTOBUF_EXAMPLES:BOOL=yes " + ...@@ -69,7 +69,6 @@ unixOpts = "-DCAF_NO_PROTOBUF_EXAMPLES:BOOL=yes " +
"-DCAF_MORE_WARNINGS:BOOL=yes " + "-DCAF_MORE_WARNINGS:BOOL=yes " +
"-DCAF_ENABLE_ADDRESS_SANITIZER:BOOL=yes " + "-DCAF_ENABLE_ADDRESS_SANITIZER:BOOL=yes " +
"-DCAF_ENABLE_RUNTIME_CHECKS:BOOL=yes " + "-DCAF_ENABLE_RUNTIME_CHECKS:BOOL=yes " +
"-DCAF_USE_ASIO:BOOL=yes " +
"-DCAF_NO_BENCHMARKS:BOOL=yes " + "-DCAF_NO_BENCHMARKS:BOOL=yes " +
"-DOPENSSL_ROOT_DIR=/usr/local/opt/openssl " + "-DOPENSSL_ROOT_DIR=/usr/local/opt/openssl " +
"-DOPENSSL_INCLUDE_DIR=/usr/local/opt/openssl/include" "-DOPENSSL_INCLUDE_DIR=/usr/local/opt/openssl/include"
......
...@@ -33,10 +33,6 @@ ...@@ -33,10 +33,6 @@
#define CAF_ENABLE_RUNTIME_CHECKS #define CAF_ENABLE_RUNTIME_CHECKS
#endif #endif
#if @CAF_USE_ASIO_INT@ != -1
#define CAF_USE_ASIO
#endif
#if @CAF_NO_EXCEPTIONS_INT@ != -1 #if @CAF_NO_EXCEPTIONS_INT@ != -1
#define CAF_NO_EXCEPTIONS #define CAF_NO_EXCEPTIONS
#endif #endif
......
...@@ -76,9 +76,6 @@ Usage: $0 [OPTION]... [VAR=VALUE]... ...@@ -76,9 +76,6 @@ Usage: $0 [OPTION]... [VAR=VALUE]...
--core-only sets no-examples, no-opencl, no-openssl, --core-only sets no-examples, no-opencl, no-openssl,
no-tools, no-python, and no-io no-tools, no-python, and no-io
Testing:
--with-asio use ASIO multiplexer in unit tests
Debugging: Debugging:
--with-runtime-checks build with requirement checks at runtime --with-runtime-checks build with requirement checks at runtime
--with-log-level=LVL build with debugging output, possible values: --with-log-level=LVL build with debugging output, possible values:
...@@ -287,9 +284,6 @@ while [ $# -ne 0 ]; do ...@@ -287,9 +284,6 @@ while [ $# -ne 0 ]; do
append_cache_entry CMAKE_OSX_ARCHITECTURES STRING "\$(ARCHS_STANDARD_32_64_BIT)" append_cache_entry CMAKE_OSX_ARCHITECTURES STRING "\$(ARCHS_STANDARD_32_64_BIT)"
append_cache_entry CAF_IOS_DEPLOYMENT_TARGET STRING "$optarg" append_cache_entry CAF_IOS_DEPLOYMENT_TARGET STRING "$optarg"
;; ;;
--with-asio)
append_cache_entry CAF_USE_ASIO BOOL yes
;;
--with-log-level=*) --with-log-level=*)
level=`echo "$optarg" | tr '[:lower:]' '[:upper:]'` level=`echo "$optarg" | tr '[:lower:]' '[:upper:]'`
case $level in case $level in
......
...@@ -37,8 +37,6 @@ relaxed-sleep-duration=10ms ...@@ -37,8 +37,6 @@ relaxed-sleep-duration=10ms
[middleman] [middleman]
; configures whether MMs try to span a full mesh ; configures whether MMs try to span a full mesh
enable-automatic-connections=false enable-automatic-connections=false
; accepted alternative: 'asio' (only when compiling CAF with ASIO)
network-backend='default'
; application identifier of this node, prevents connection to other CAF ; application identifier of this node, prevents connection to other CAF
; instances with different identifier ; instances with different identifier
app-identifier="" app-identifier=""
......
This diff is collapsed.
This diff is collapsed.
...@@ -57,11 +57,6 @@ ...@@ -57,11 +57,6 @@
#include "caf/detail/get_root_uuid.hpp" #include "caf/detail/get_root_uuid.hpp"
#include "caf/detail/get_mac_addresses.hpp" #include "caf/detail/get_mac_addresses.hpp"
#ifdef CAF_USE_ASIO
#include "caf/io/network/asio_multiplexer.hpp"
#include "caf/io/network/asio_multiplexer_impl.hpp"
#endif // CAF_USE_ASIO
#ifdef CAF_WINDOWS #ifdef CAF_WINDOWS
#include <io.h> #include <io.h>
#include <fcntl.h> #include <fcntl.h>
...@@ -93,10 +88,6 @@ actor_system::module* middleman::make(actor_system& sys, detail::type_list<>) { ...@@ -93,10 +88,6 @@ actor_system::module* middleman::make(actor_system& sys, detail::type_list<>) {
auto atm = get_or(sys.config(), "middleman.network-backend", auto atm = get_or(sys.config(), "middleman.network-backend",
defaults::middleman::network_backend); defaults::middleman::network_backend);
switch (atom_uint(atm)) { switch (atom_uint(atm)) {
# ifdef CAF_USE_ASIO
case atom_uint(atom("asio")):
return new mm_impl<network::asio_multiplexer>(sys);
# endif // CAF_USE_ASIO
case atom_uint(atom("testing")): case atom_uint(atom("testing")):
return new mm_impl<network::test_multiplexer>(sys); return new mm_impl<network::test_multiplexer>(sys);
default: default:
......
...@@ -63,8 +63,8 @@ public: ...@@ -63,8 +63,8 @@ public:
bool authentication_enabled(); bool authentication_enabled();
/// Returns an OpenSSL manager using the default network backend. /// Returns an OpenSSL manager using the default network backend.
/// @warning Creating an OpenSSL manager will fail when using the ASIO /// @warning Creating an OpenSSL manager will fail when using
/// network backend or any other custom implementation. // a custom implementation.
/// @throws `logic_error` if the middleman is not loaded or is not using the /// @throws `logic_error` if the middleman is not loaded or is not using the
/// default network backend. /// default network backend.
static actor_system::module* make(actor_system&, detail::type_list<>); static actor_system::module* make(actor_system&, detail::type_list<>);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment