diff --git a/CHANGELOG.md b/CHANGELOG.md index cea185a385125526bbfad7c025595b17d1d11f9d..f8c67a30f2fffc6fa733ca5550d28ee7d3ddf9a3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,4 @@ -## 20.03 (unreleased) ++## 20.03 (unreleased) FEATURES * introduced substreams for producer/consumer [[JIRA_102](https://agira.desy.de/browse/HIDRA2-102)] @@ -6,6 +6,7 @@ IMPROVEMENTS * switch to MongoDB 4.2 * receiver use ASAP3 directory structure to save files to * API documentation is available at [asapo-docs.desy.de](asapo-docs.desy.de) +* switch to using cmake 3.7+ BUG FIXES * consumer operation timout - take duration of the operation into account \ No newline at end of file diff --git a/CMakeLists.txt b/CMakeLists.txt index 05d3437c60bbd44f973b6469aa5cf79b787bc7a3..6a19e04e8c3ba1fce6cbb406a14999b59b15d5f5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8) +cmake_minimum_required(VERSION 3.7) project(ASAPO) set(CMAKE_CXX_STANDARD 11) IF(WIN32) @@ -35,6 +35,7 @@ option(BUILD_TESTS "Uses googletest to build tests" OFF) option(BUILD_INTEGRATION_TESTS "Include integration tests (CMAKE >3.7 is needed)" OFF) option(BUILD_CPP_DOCS "Uses doxygen to build the C++ documentaion" OFF) option(BUILD_BROKER "Build broker" OFF) +option(BUILD_EVENT_MONITOR_PRODUCER "Build the event monitor producer" OFF) option(BUILD_PYTHON_DOCS "Uses sphinx to build the Python documentaion" OFF) option(BUILD_CONSUMER_TOOLS "Build consumer tools" OFF) @@ -52,6 +53,16 @@ message (STATUS "Found cURL libraries: ${CURL_LIBRARIES}") message (STATUS "cURL include: ${CURL_INCLUDE_DIRS}") +if ("${Python_EXECUTABLE}" STREQUAL "") + find_package (Python COMPONENTS Interpreter Development) + if (NOT Python_FOUND) + message (FATAL "Cannot find Python") + endif() +endif() +message (STATUS "Using Python: ${Python_EXECUTABLE}") + + + # format sources include(astyle) diff --git a/CMakeModules/CodeCoverage.cmake b/CMakeModules/CodeCoverage.cmake index c170c6a0a938e7f73c6b530726b04a558d780893..c170a8a583bbf2ea89338fdfc664ddddfe8afef0 100644 --- a/CMakeModules/CodeCoverage.cmake +++ b/CMakeModules/CodeCoverage.cmake @@ -73,7 +73,6 @@ find_program( GCOV_PATH gcov ) find_program( LCOV_PATH lcov ) find_program( GENHTML_PATH genhtml ) find_program( GCOVR_PATH gcovr PATHS ${CMAKE_SOURCE_DIR}/scripts/test) -find_program( SIMPLE_PYTHON_EXECUTABLE python ) if(NOT GCOV_PATH) message(FATAL_ERROR "gcov not found! Aborting...") @@ -204,10 +203,6 @@ function(SETUP_TARGET_FOR_COVERAGE_COBERTURA) set(multiValueArgs EXECUTABLE EXECUTABLE_ARGS DEPENDENCIES) cmake_parse_arguments(Coverage "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN}) - if(NOT SIMPLE_PYTHON_EXECUTABLE) - message(FATAL_ERROR "python not found! Aborting...") - endif() # NOT SIMPLE_PYTHON_EXECUTABLE - if(NOT GCOVR_PATH) message(FATAL_ERROR "gcovr not found! Aborting...") endif() # NOT GCOVR_PATH diff --git a/common/cpp/src/system_io/system_io_linux.cpp b/common/cpp/src/system_io/system_io_linux.cpp index f1aaec3ac9523eb077f4a400b42d5587bb6a1471..5b8c2e7d9b8aafc6ccc8cb33899412a254e63dd7 100644 --- a/common/cpp/src/system_io/system_io_linux.cpp +++ b/common/cpp/src/system_io/system_io_linux.cpp @@ -105,7 +105,7 @@ ListSocketDescriptors SystemIO::WaitSocketsActivity(SocketDescriptor master_sock } SystemIO::~SystemIO() { - if (epoll_fd_ != -kDisconnectedSocketDescriptor) { + if (epoll_fd_ != kDisconnectedSocketDescriptor) { close(epoll_fd_); } } diff --git a/consumer/api/cpp/src/server_data_broker.cpp b/consumer/api/cpp/src/server_data_broker.cpp index 01696549062e5c4a6b83a239b304ed3b31d103f0..685aafb1010dd9aff22fb265cb8442193b69f241 100644 --- a/consumer/api/cpp/src/server_data_broker.cpp +++ b/consumer/api/cpp/src/server_data_broker.cpp @@ -481,12 +481,12 @@ DataSet ServerDataBroker::GetDatasetById(uint64_t id, std::string group_id, std: return GetDatasetFromServer(GetImageServerOperation::GetID, id, std::move(group_id), std::move(substream), err); } -std::vector<std::string> ParseSubstreamsFromResponse(std::string response,Error* err) { +std::vector<std::string> ParseSubstreamsFromResponse(std::string response, Error* err) { auto parser = JsonStringParser(std::move(response)); std::vector<std::string> substreams; *err = parser.GetArrayString("substreams", &substreams); if (*err) { - return std::vector<std::string>{}; + return std::vector<std::string> {}; } return substreams; } @@ -500,10 +500,10 @@ std::vector<std::string> ServerDataBroker::GetSubstreamList(Error* err) { auto response = BrokerRequestWithTimeout(ri, err); if (*err) { - return std::vector<std::string>{}; + return std::vector<std::string> {}; } - return ParseSubstreamsFromResponse(std::move(response),err); + return ParseSubstreamsFromResponse(std::move(response), err); } } diff --git a/consumer/api/cpp/unittests/test_server_broker.cpp b/consumer/api/cpp/unittests/test_server_broker.cpp index f51aa3700dd6119c1811e123f84771bf63779824..c5c23986860c69b1b449aba34b8fc588f21400f4 100644 --- a/consumer/api/cpp/unittests/test_server_broker.cpp +++ b/consumer/api/cpp/unittests/test_server_broker.cpp @@ -837,6 +837,7 @@ TEST_F(ServerDataBrokerTests, QueryImagesReturnRecords) { auto rec1 = CreateFI(); auto rec2 = CreateFI(); + rec2.name = "ttt"; auto json1 = rec1.Json(); auto json2 = rec2.Json(); auto responce_string = "[" + json1 + "," + json2 + "]"; @@ -855,8 +856,8 @@ TEST_F(ServerDataBrokerTests, QueryImagesReturnRecords) { ASSERT_THAT(err, Eq(nullptr)); ASSERT_THAT(images.size(), Eq(2)); - ASSERT_THAT(images[0], Eq(rec1)); - ASSERT_THAT(images[1], Eq(rec2)); + ASSERT_THAT(images[0].name, Eq(rec1.name)); + ASSERT_THAT(images[1].name, Eq(rec2.name)); } TEST_F(ServerDataBrokerTests, QueryImagesUsesCorrectUriWithSubstream) { @@ -987,17 +988,17 @@ TEST_F(ServerDataBrokerTests, GetSubstreamListUsesCorrectUri) { MockGetBrokerUri(); EXPECT_CALL(mock_http_client, Get_t(expected_broker_uri + "/database/beamtime_id/" + expected_stream + "/0/substreams" - + "?token="+ expected_token, _, + + "?token=" + expected_token, _, _)).WillOnce(DoAll( - SetArgPointee<1>(HttpCode::OK), - SetArgPointee<2>(nullptr), - Return("{\"substreams\":[\"s1\",\"s2\"]}"))); + SetArgPointee<1>(HttpCode::OK), + SetArgPointee<2>(nullptr), + Return("{\"substreams\":[\"s1\",\"s2\"]}"))); asapo::Error err; auto substreams = data_broker->GetSubstreamList(&err); ASSERT_THAT(err, Eq(nullptr)); ASSERT_THAT(substreams.size(), Eq(2)); - ASSERT_THAT(substreams, testing::ElementsAre("s1","s2")); + ASSERT_THAT(substreams, testing::ElementsAre("s1", "s2")); } diff --git a/consumer/api/python/CMakeLists_Linux.cmake b/consumer/api/python/CMakeLists_Linux.cmake index 511ac676aafbdaeee66ac92398eab2a92ecba33b..f29e2096677ddab9cc77b62bdfa6ade15db06c47 100644 --- a/consumer/api/python/CMakeLists_Linux.cmake +++ b/consumer/api/python/CMakeLists_Linux.cmake @@ -9,19 +9,16 @@ else() set (EXTRA_LINK_ARGS "[]") ENDIF() -get_property(ASAPO_CONSUMER_LIB TARGET asapo-consumer PROPERTY LOCATION) +configure_files(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR} @ONLY) +file(GENERATE OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/setup.py INPUT ${CMAKE_CURRENT_BINARY_DIR}/setup.py) set (ASAPO_CONSUMER_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../cpp/include) configure_files(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR} @ONLY) -ADD_CUSTOM_TARGET(python-lib2 ALL - COMMAND python setup.py build_ext --inplace --force) - -ADD_CUSTOM_TARGET(python-lib3 ALL - COMMAND python3 setup.py build_ext --inplace --force) +ADD_CUSTOM_TARGET(python-lib ALL + COMMAND ${Python_EXECUTABLE} setup.py build_ext --inplace --force) -ADD_DEPENDENCIES(python-lib2 asapo-consumer) -ADD_DEPENDENCIES(python-lib3 asapo-consumer) +ADD_DEPENDENCIES(python-lib asapo-consumer) add_subdirectory(source_dist_linux) diff --git a/consumer/api/python/dev-requirements.txt b/consumer/api/python/dev-requirements.txt new file mode 100644 index 0000000000000000000000000000000000000000..6e5e5e427263113b61c154a9241cb72204b14989 --- /dev/null +++ b/consumer/api/python/dev-requirements.txt @@ -0,0 +1,2 @@ +cython +numpy==1.14.6 \ No newline at end of file diff --git a/consumer/api/python/setup.py.in b/consumer/api/python/setup.py.in index b70319b080b519e0a2dd2a4eafc78764ca3be067..0de6e24cd6f79c81acc3a76cfce082e534f522db 100644 --- a/consumer/api/python/setup.py.in +++ b/consumer/api/python/setup.py.in @@ -6,7 +6,7 @@ from Cython.Build import cythonize import numpy module = Extension("asapo_consumer", ["asapo_consumer.pyx"], - extra_objects=['@ASAPO_CONSUMER_LIB@', + extra_objects=['$<TARGET_FILE:asapo-consumer>', '@CURL_LIBRARIES@'], include_dirs=["@ASAPO_CXX_COMMON_INCLUDE_DIR@","@ASAPO_CONSUMER_INCLUDE_DIR@",numpy.get_include()], extra_compile_args=@EXTRA_COMPILE_ARGS@, diff --git a/consumer/api/python/source_dist_linux/CMakeLists.txt b/consumer/api/python/source_dist_linux/CMakeLists.txt index 526146c65aaca82983e6b48cc16f5f1427a9b46a..1fb9c9c47db66105dbee3bdeaf1d98ad1dfdab07 100644 --- a/consumer/api/python/source_dist_linux/CMakeLists.txt +++ b/consumer/api/python/source_dist_linux/CMakeLists.txt @@ -3,7 +3,7 @@ configure_file(MANIFEST.in MANIFEST.in @ONLY) ADD_CUSTOM_TARGET(python-dist ALL - COMMAND python setup.py sdist + COMMAND ${Python_EXECUTABLE} setup.py sdist ) #get_property(ASAPO_CONSUMER_LIB TARGET asapo-consumer PROPERTY LOCATION) @@ -21,6 +21,6 @@ ADD_CUSTOM_TARGET(copy_python_dist ALL ) -ADD_DEPENDENCIES(copy_python_dist python-lib3) +ADD_DEPENDENCIES(copy_python_dist python-lib) ADD_DEPENDENCIES(python-dist copy_python_dist) diff --git a/consumer/api/python/source_dist_linux/setup.py.in b/consumer/api/python/source_dist_linux/setup.py.in index 43c0c9eb44ba6dd1732d83efab96b9f7829cae64..7fc52d9943fafb484f8c082467c709677eca5861 100644 --- a/consumer/api/python/source_dist_linux/setup.py.in +++ b/consumer/api/python/source_dist_linux/setup.py.in @@ -4,8 +4,7 @@ import numpy ext_modules = [ Extension("asapo_consumer", ["asapo_consumer.cpp"], - extra_objects=['lib/libasapo-consumer.a'], - libraries = ['curl'], + extra_objects=['lib/libasapo-consumer.a', 'lib/libcurl.a'], include_dirs=["include/common","include",numpy.get_include()], extra_compile_args=@EXTRA_COMPILE_ARGS@, extra_link_args=@EXTRA_LINK_ARGS@, diff --git a/deploy/build_env/Centos7.7/build.sh b/deploy/build_env/Centos7.7/build.sh index 40318cb213fe0c5090b888e67c2e8a6db996f000..b902e0e679a08c4af1a4ec85aa5e424673654638 100755 --- a/deploy/build_env/Centos7.7/build.sh +++ b/deploy/build_env/Centos7.7/build.sh @@ -1,7 +1,12 @@ #!/usr/bin/env bash cd /asapo/build -cmake -DCMAKE_BUILD_TYPE="Release" -DLIBCURL_DIR=/curl -DBUILD_PYTHON_DOCS=ON .. +cmake \ + -DCMAKE_BUILD_TYPE="Release" \ + -DLIBCURL_DIR=/curl \ + -DBUILD_PYTHON_DOCS=ON \ + -DBUILD_EVENT_MONITOR_PRODUCER=ON \ + .. cd consumer && make cd ../producer && make cd ../sphinx && make diff --git a/deploy/build_env/Ubuntu16.04/Dockerfile b/deploy/build_env/Ubuntu16.04/Dockerfile index 45fe5432d1ac7b1a3ad4a0df0dee6a2010ccbd92..83de5fd69999360bb213ab4c24fd3ff7d49f3e10 100644 --- a/deploy/build_env/Ubuntu16.04/Dockerfile +++ b/deploy/build_env/Ubuntu16.04/Dockerfile @@ -2,14 +2,14 @@ from ubuntu:16.04 ENV GOPATH /tmp -RUN apt update && apt install -y cmake g++ golang zlib1g-dev python cython python-numpy python3 cython3 python3-numpy git wget - - ADD install_curl.sh install_curl.sh -RUN ./install_curl.sh /curl +ADD install_cmake.sh install_cmake.sh -RUN apt install -y python-pip python3-pip && pip install --upgrade cython && pip3 install --upgrade cython -RUN pip3 install sphinx +RUN apt update && apt install -y g++ golang zlib1g-dev python cython python-numpy python3 cython3 python3-numpy \ +git wget python-pip python3-pip && \ +pip --no-cache-dir install --upgrade cython && pip3 --no-cache-dir install --upgrade cython && pip3 --no-cache-dir install sphinx && \ +./install_curl.sh /curl && ./install_cmake.sh && \ +apt-get purge -y --auto-remove ADD build.sh /bin/build.sh diff --git a/deploy/build_env/Ubuntu16.04/build.sh b/deploy/build_env/Ubuntu16.04/build.sh index d399e3811718f0b7223cab83caa9f99b1dbbf02b..4daa3974e7e7b74bddf00b38fdac56b936ff5a75 100755 --- a/deploy/build_env/Ubuntu16.04/build.sh +++ b/deploy/build_env/Ubuntu16.04/build.sh @@ -1,7 +1,14 @@ #!/usr/bin/env bash +set -e + cd /asapo/build -cmake -DCMAKE_BUILD_TYPE="Release" -DLIBCURL_DIR=/curl -DBUILD_PYTHON_DOCS=ON .. +cmake \ + -DCMAKE_BUILD_TYPE="Release" \ + -DLIBCURL_DIR=/curl \ + -DBUILD_PYTHON_DOCS=ON \ + -DBUILD_EVENT_MONITOR_PRODUCER=ON \ + .. cd consumer && make cd ../producer && make cd ../docs/sphinx && make diff --git a/deploy/build_env/Ubuntu16.04/build_image.sh b/deploy/build_env/Ubuntu16.04/build_image.sh index 6c427c9900115a0a539de65518d8216a3ea7cf97..415b215afd6aaf4ba1eb53a35b5830ae37581e4f 100755 --- a/deploy/build_env/Ubuntu16.04/build_image.sh +++ b/deploy/build_env/Ubuntu16.04/build_image.sh @@ -1,3 +1,4 @@ #!/usr/bin/env bash +set -e docker build -t yakser/asapo-env:ubuntu16.04 . docker push yakser/asapo-env:ubuntu16.04 diff --git a/deploy/build_env/Ubuntu16.04/install_cmake.sh b/deploy/build_env/Ubuntu16.04/install_cmake.sh new file mode 100755 index 0000000000000000000000000000000000000000..55245ffb3a58f94111e147c138a79a488279c6ca --- /dev/null +++ b/deploy/build_env/Ubuntu16.04/install_cmake.sh @@ -0,0 +1,13 @@ +#!/usr/bin/env bash + +wget https://cmake.org/files/v3.10/cmake-3.10.0.tar.gz + +tar zxvf cmake-3.* +cd cmake-3.* +./bootstrap --prefix=/usr/local +make -j$(nproc) +make install + +cmake --version + +/usr/local/bin/cmake --version diff --git a/deploy/build_env/manylinux2010/Dockerfile b/deploy/build_env/manylinux2010/Dockerfile new file mode 100644 index 0000000000000000000000000000000000000000..f9ea1e6244926873f98c0f7ea3e77ed3d47d8af6 --- /dev/null +++ b/deploy/build_env/manylinux2010/Dockerfile @@ -0,0 +1,16 @@ +FROM quay.io/pypa/manylinux2010_x86_64 + +ENV GOPATH /tmp + +RUN yum update -y && yum install -y golang wget zlib-devel + +ADD install_curl.sh install_curl.sh +RUN ./install_curl.sh /curl + +ADD build.sh /bin/build.sh + +RUN chmod og+rwX -R /opt + +ADD install_cmake.sh install_cmake.sh +RUN ./install_cmake.sh + diff --git a/deploy/build_env/manylinux2010/build.sh b/deploy/build_env/manylinux2010/build.sh new file mode 100755 index 0000000000000000000000000000000000000000..afc0ab8d0a5e6116bf06991def4a92e1c1108c39 --- /dev/null +++ b/deploy/build_env/manylinux2010/build.sh @@ -0,0 +1,28 @@ +#!/usr/bin/env bash +set -e + +for python_path in /opt/python/cp{27,35,36,37}*m; do + python=$python_path/bin/python + pip=$python_path/bin/pip + + cd /asapo/build + cmake -DCMAKE_BUILD_TYPE="Release" -DLIBCURL_DIR=/curl -DPython_EXECUTABLE=$python .. + cd consumer \ + && $pip install -r /asapo/consumer/api/python/dev-requirements.txt \ + && make \ + && $pip wheel api/python/source_dist_linux/dist/*.tar.gz -w wheelhouse --no-deps + cd ../producer \ + && $pip install -r /asapo/producer/api/python/dev-requirements.txt \ + && make \ + && $pip wheel api/python/source_dist_linux/dist/*.tar.gz -w wheelhouse --no-deps +done + +cd ../consumer \ + && for wheel in wheelhouse/asapo_consumer*.whl; do + auditwheel repair $wheel --plat manylinux2010_x86_64 -w /asapo/build/wheelhouse + done + +cd ../producer \ + && for wheel in wheelhouse/asapo_producer*.whl; do + auditwheel repair $wheel --plat manylinux2010_x86_64 -w /asapo/build/wheelhouse + done \ No newline at end of file diff --git a/deploy/build_env/manylinux2010/build_image.sh b/deploy/build_env/manylinux2010/build_image.sh new file mode 100755 index 0000000000000000000000000000000000000000..d5667a5145247e95d3213293323425d91a4c75f8 --- /dev/null +++ b/deploy/build_env/manylinux2010/build_image.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash + +docker build -t yakser/asapo-env:manylinux2010_ . +./docker-squash yakser/asapo-env:manylinux2010_ -t yakser/asapo-env:manylinux2010 +docker push yakser/asapo-env:manylinux2010 + diff --git a/deploy/build_env/manylinux2010/docker-squash b/deploy/build_env/manylinux2010/docker-squash new file mode 100755 index 0000000000000000000000000000000000000000..22433497d01c838a7981dbff32f7ccef785a09d5 --- /dev/null +++ b/deploy/build_env/manylinux2010/docker-squash @@ -0,0 +1,11 @@ +#!/usr/bin/python3 + +# -*- coding: utf-8 -*- +import re +import sys + +from docker_squash.cli import run + +if __name__ == '__main__': + sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0]) + sys.exit(run()) diff --git a/deploy/build_env/manylinux2010/install_cmake.sh b/deploy/build_env/manylinux2010/install_cmake.sh new file mode 100755 index 0000000000000000000000000000000000000000..55245ffb3a58f94111e147c138a79a488279c6ca --- /dev/null +++ b/deploy/build_env/manylinux2010/install_cmake.sh @@ -0,0 +1,13 @@ +#!/usr/bin/env bash + +wget https://cmake.org/files/v3.10/cmake-3.10.0.tar.gz + +tar zxvf cmake-3.* +cd cmake-3.* +./bootstrap --prefix=/usr/local +make -j$(nproc) +make install + +cmake --version + +/usr/local/bin/cmake --version diff --git a/deploy/build_env/manylinux2010/install_curl.sh b/deploy/build_env/manylinux2010/install_curl.sh new file mode 100755 index 0000000000000000000000000000000000000000..ac368ddc7e71cd37da7987fa69e59708ab8d8458 --- /dev/null +++ b/deploy/build_env/manylinux2010/install_curl.sh @@ -0,0 +1,16 @@ +#!/usr/bin/env bash + +mkdir -p $1 +cd $1 +wget https://curl.haxx.se/download/curl-7.58.0.tar.gz +tar xzf curl-7.58.0.tar.gz +cd curl-7.58.0 +./configure --without-ssl --disable-shared --disable-manual --disable-ares --disable-cookies \ +--disable-crypto-auth --disable-ipv6 --disable-proxy --disable-unix-sockets \ +--without-libidn --without-librtmp --without-zlib --disable-ldap \ +--disable-libcurl-option --prefix=`pwd`/../ +make +make install +cd - +rm -rf bin share curl-7.58.0 +rm curl-7.58.0.tar.gz diff --git a/docs/sphinx/CMakeLists.txt b/docs/sphinx/CMakeLists.txt index a04cdcb697392e120ee2ac85c85236c9020a965f..77fda050e6c860103cc70fb958ef823cb0b12b5a 100644 --- a/docs/sphinx/CMakeLists.txt +++ b/docs/sphinx/CMakeLists.txt @@ -8,5 +8,5 @@ add_custom_target( WORKING_DIRECTORY sphinx ) -add_dependencies(docs-py python-lib3-producer) -add_dependencies(docs-py python-lib3) +add_dependencies(docs-py python-lib-producer) +add_dependencies(docs-py python-lib) diff --git a/examples/consumer/getnext_broker_python/CMakeLists.txt b/examples/consumer/getnext_broker_python/CMakeLists.txt index 2e13a9d90ec9b5b6d278fd3d257a2542a38fd0f8..bf53e51c584e69ae1d900eba3295caae447c8b31 100644 --- a/examples/consumer/getnext_broker_python/CMakeLists.txt +++ b/examples/consumer/getnext_broker_python/CMakeLists.txt @@ -4,12 +4,12 @@ set(TARGET_NAME getnext_broker_python) prepare_asapo() if (UNIX) - get_target_property(PYTHON_LIBS python-lib2 BINARY_DIR) + get_target_property(PYTHON_LIBS python-lib BINARY_DIR) else() get_target_property(PYTHON_LIBS asapo_consumer BINARY_DIR) endif() -add_script_test("${TARGET_NAME}" ${PYTHON_LIBS} nomem) +add_script_test("${TARGET_NAME}" "${PYTHON_LIBS} ${Python_EXECUTABLE}" nomem) configure_file(getnext.py getnext.py COPYONLY) diff --git a/examples/consumer/getnext_broker_python/check_linux.sh b/examples/consumer/getnext_broker_python/check_linux.sh index 2217862e5b3a3d67e4c22000a1d79390344fd4b2..b1a508025c94fade1010a2b5f40492e32c791ecb 100644 --- a/examples/consumer/getnext_broker_python/check_linux.sh +++ b/examples/consumer/getnext_broker_python/check_linux.sh @@ -8,8 +8,6 @@ token_test_run=K38Mqc90iRv8fC7prcFHd994mF_wfUiJnWBfIjIzieo= group_id=bif31l2uiddd4r0q6b40 set -e - - trap Cleanup EXIT Cleanup() { @@ -35,27 +33,19 @@ echo 'db.meta.insert({"_id":0,"meta_test":"test"})' | mongo ${database_name} sleep 1 export PYTHONPATH=$1:${PYTHONPATH} +Python_EXECUTABLE=$2 + -python getnext.py 127.0.0.1:8400 $source_path $beamtime_id $token_test_run $group_id > out +$Python_EXECUTABLE getnext.py 127.0.0.1:8400 $source_path $beamtime_id $token_test_run $group_id > out cat out cat out | grep '"size": 100' cat out | grep '"_id": 1' cat out | grep '"meta_test": "test"' -python getnext.py 127.0.0.1:8400 $source_path $beamtime_id $token_test_run $group_id> out +$Python_EXECUTABLE getnext.py 127.0.0.1:8400 $source_path $beamtime_id $token_test_run $group_id> out cat out cat out | grep '"_id": 2' -python3 getnext.py 127.0.0.1:8400 $source_path $beamtime_id $token_test_run $group_id> out -cat out -cat out | grep '"_id": 3' - - -python3 getnext.py 127.0.0.1:8400 $source_path $beamtime_id $token_test_run new> out -cat out -cat out | grep '"_id": 1' - - #echo $? diff --git a/examples/pipeline/in_to_out_python/CMakeLists.txt b/examples/pipeline/in_to_out_python/CMakeLists.txt index c52a878b077c79429ef7a56da9ebcd2ac3e16536..9ab39455b74d188afbe611bf05599c4e84f876f0 100644 --- a/examples/pipeline/in_to_out_python/CMakeLists.txt +++ b/examples/pipeline/in_to_out_python/CMakeLists.txt @@ -3,8 +3,8 @@ set(TARGET_NAME pipeline_inout_python) prepare_asapo() if (UNIX) - get_target_property(PYTHON_LIBS_CONSUMER python-lib2 BINARY_DIR) - get_target_property(PYTHON_LIBS_PRODUCER python-lib2-producer BINARY_DIR) + get_target_property(PYTHON_LIBS_CONSUMER python-lib BINARY_DIR) + get_target_property(PYTHON_LIBS_PRODUCER python-lib-producer BINARY_DIR) else() get_target_property(PYTHON_LIBS_CONSUMER asapo_consumer BINARY_DIR) get_target_property(PYTHON_LIBS_PRODUCER asapo_producer BINARY_DIR) @@ -12,5 +12,5 @@ endif() file(TO_NATIVE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/in_to_out.py TEST_SCRIPT ) -add_script_test("${TARGET_NAME}" "python ${PYTHON_LIBS_CONSUMER} ${PYTHON_LIBS_PRODUCER} ${TEST_SCRIPT} " nomem) +add_script_test("${TARGET_NAME}" "${Python_EXECUTABLE} ${PYTHON_LIBS_CONSUMER} ${PYTHON_LIBS_PRODUCER} ${TEST_SCRIPT} " nomem) diff --git a/producer/CMakeLists.txt b/producer/CMakeLists.txt index 62ecdca0cdcb1fa34c4619e5b93da4377ad2159e..3c8560c158c9f3cabadc119cc4baae3205d4f3d1 100644 --- a/producer/CMakeLists.txt +++ b/producer/CMakeLists.txt @@ -1,4 +1,6 @@ add_subdirectory(api/cpp) add_subdirectory(api/python) -add_subdirectory(event_monitor_producer) +if(BUILD_EVENT_MONITOR_PRODUCER) + add_subdirectory(event_monitor_producer) +endif(BUILD_EVENT_MONITOR_PRODUCER) diff --git a/producer/api/python/CMakeLists_Linux.cmake b/producer/api/python/CMakeLists_Linux.cmake index 3e0bfcdd7946f525bae0a5c24a600ae046cae4ea..0a8ca96ac36608c9b266e1ee5903dfe0d75059d1 100644 --- a/producer/api/python/CMakeLists_Linux.cmake +++ b/producer/api/python/CMakeLists_Linux.cmake @@ -9,19 +9,15 @@ else() set (EXTRA_LINK_ARGS "[]") ENDIF() -get_property(ASAPO_PRODUCER_LIB TARGET asapo-producer PROPERTY LOCATION) - set (ASAPO_PRODUCER_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../cpp/include) configure_files(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR} @ONLY) +file(GENERATE OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/setup.py INPUT ${CMAKE_CURRENT_BINARY_DIR}/setup.py) -ADD_CUSTOM_TARGET(python-lib2-producer ALL - COMMAND python setup.py build_ext --inplace --force ) -ADD_CUSTOM_TARGET(python-lib3-producer ALL - COMMAND python3 setup.py build_ext --inplace --force) +ADD_CUSTOM_TARGET(python-lib-producer ALL + COMMAND ${Python_EXECUTABLE} setup.py build_ext --inplace --force) -ADD_DEPENDENCIES(python-lib2-producer asapo-producer) -ADD_DEPENDENCIES(python-lib3-producer asapo-producer) +ADD_DEPENDENCIES(python-lib-producer asapo-producer) add_subdirectory(source_dist_linux) diff --git a/producer/api/python/dev-requirements.txt b/producer/api/python/dev-requirements.txt new file mode 100644 index 0000000000000000000000000000000000000000..6e5e5e427263113b61c154a9241cb72204b14989 --- /dev/null +++ b/producer/api/python/dev-requirements.txt @@ -0,0 +1,2 @@ +cython +numpy==1.14.6 \ No newline at end of file diff --git a/producer/api/python/setup.py.in b/producer/api/python/setup.py.in index 180039026505919394e2739dbb3e070a4e4c97c1..75da93f36dc9089f197759b1a042245b2b8eb4c6 100644 --- a/producer/api/python/setup.py.in +++ b/producer/api/python/setup.py.in @@ -6,7 +6,7 @@ from Cython.Build import cythonize import numpy module = Extension("asapo_producer", ["asapo_producer.pyx"], - extra_objects=['@ASAPO_PRODUCER_LIB@', + extra_objects=['$<TARGET_FILE:asapo-producer>', '@CURL_LIBRARIES@'], include_dirs=["@ASAPO_CXX_COMMON_INCLUDE_DIR@","@ASAPO_PRODUCER_INCLUDE_DIR@",numpy.get_include()], extra_compile_args=@EXTRA_COMPILE_ARGS@, diff --git a/producer/api/python/source_dist_linux/CMakeLists.txt b/producer/api/python/source_dist_linux/CMakeLists.txt index 2acfffd0d0eff2b56297e4506a3951e7ff7b5f78..89a61bd74699c238f8e85bc7aff94b9815d7185d 100644 --- a/producer/api/python/source_dist_linux/CMakeLists.txt +++ b/producer/api/python/source_dist_linux/CMakeLists.txt @@ -3,7 +3,7 @@ configure_file(MANIFEST.in MANIFEST.in @ONLY) ADD_CUSTOM_TARGET(python-dist-producer ALL - COMMAND python setup.py sdist + COMMAND ${Python_EXECUTABLE} setup.py sdist ) ADD_CUSTOM_TARGET(copy_python_dist-producer ALL @@ -20,6 +20,6 @@ ADD_CUSTOM_TARGET(copy_python_dist-producer ALL ) -ADD_DEPENDENCIES(copy_python_dist-producer python-lib3-producer) +ADD_DEPENDENCIES(copy_python_dist-producer python-lib-producer) ADD_DEPENDENCIES(python-dist-producer copy_python_dist-producer) diff --git a/producer/api/python/source_dist_linux/setup.py.in b/producer/api/python/source_dist_linux/setup.py.in index 3e92976f88cb472bf0b3ce2d9601c63a0efb4132..0f7bb563317f7275f6f72acbae17d73265efec68 100644 --- a/producer/api/python/source_dist_linux/setup.py.in +++ b/producer/api/python/source_dist_linux/setup.py.in @@ -4,8 +4,7 @@ import numpy ext_modules = [ Extension("asapo_producer", ["asapo_producer.cpp"], - extra_objects=['lib/libasapo-producer.a'], - libraries = ['curl'], + extra_objects=['lib/libasapo-producer.a', 'lib/libcurl.a'], include_dirs=["include/common","include",numpy.get_include()], extra_compile_args=@EXTRA_COMPILE_ARGS@, extra_link_args=@EXTRA_LINK_ARGS@, diff --git a/tests/automatic/bug_fixes/consumer_python_memleak/CMakeLists.txt b/tests/automatic/bug_fixes/consumer_python_memleak/CMakeLists.txt index b139ef5ebdc798d675f3e90f6da10c1b8e2b764f..6c6b66006a123dac465173c7a91dd01c43c10068 100644 --- a/tests/automatic/bug_fixes/consumer_python_memleak/CMakeLists.txt +++ b/tests/automatic/bug_fixes/consumer_python_memleak/CMakeLists.txt @@ -4,12 +4,12 @@ set(TARGET_NAME consumer_python_memleak) prepare_asapo() if (UNIX) - get_target_property(PYTHON_LIBS python-lib2 BINARY_DIR) + get_target_property(PYTHON_LIBS python-lib BINARY_DIR) else() get_target_property(PYTHON_LIBS asapo_consumer BINARY_DIR) endif() -add_script_test("${TARGET_NAME}" ${PYTHON_LIBS} nomem) +add_script_test("${TARGET_NAME}" "${PYTHON_LIBS} ${Python_EXECUTABLE}" nomem) configure_file(memleak.py memleak.py COPYONLY) diff --git a/tests/automatic/bug_fixes/consumer_python_memleak/check_linux.sh b/tests/automatic/bug_fixes/consumer_python_memleak/check_linux.sh index c3dff6e8a90e5c53c90a28d8924ca54c3e2bceb5..6b81cebc39ec499ecc2b31c09bedf4f2579b644d 100644 --- a/tests/automatic/bug_fixes/consumer_python_memleak/check_linux.sh +++ b/tests/automatic/bug_fixes/consumer_python_memleak/check_linux.sh @@ -32,11 +32,10 @@ echo 'db.data_default.insert({"_id":'1',"size":'$size',"name":"'$fname'","lastch dd if=/dev/zero of=$fname bs=$size count=1 export PYTHONPATH=$1:${PYTHONPATH} +export Python_EXECUTABLE=$2 -export PYTHONPATH=/home/yakubov/projects/asapo/cmake-build-debug/consumer/api/python:${PYTHONPATH} - -python memleak.py $endpoint $path $beamtime_id $token &> out & +$Python_EXECUTABLE memleak.py $endpoint $path $beamtime_id $token &> out & pid=`echo $!` sleep 1 diff --git a/tests/automatic/bug_fixes/error-sending-data-using-callback-method/CMakeLists.txt b/tests/automatic/bug_fixes/error-sending-data-using-callback-method/CMakeLists.txt index d3cd169bb8a1e32c906ebce529374ab50af8b06f..08bd8372ea5cd0b79f3fe94dcefebe75facd821e 100644 --- a/tests/automatic/bug_fixes/error-sending-data-using-callback-method/CMakeLists.txt +++ b/tests/automatic/bug_fixes/error-sending-data-using-callback-method/CMakeLists.txt @@ -8,7 +8,7 @@ prepare_asapo() prepare_asapo() if (UNIX) - get_target_property(PYTHON_LIBS python-lib2-producer BINARY_DIR) + get_target_property(PYTHON_LIBS python-lib-producer BINARY_DIR) else() get_target_property(PYTHON_LIBS asapo_producer BINARY_DIR) endif() @@ -16,8 +16,8 @@ endif() file(TO_NATIVE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/bugfix_callback.py TEST_SCRIPT ) -add_script_test("${TARGET_NAME}-python2" "python ${PYTHON_LIBS} ${TEST_SCRIPT} " nomem) +add_script_test("${TARGET_NAME}-python" "${Python_EXECUTABLE} ${PYTHON_LIBS} ${TEST_SCRIPT} " nomem) -add_script_test("${TARGET_NAME}-python3" "python3 ${PYTHON_LIBS} ${TEST_SCRIPT} " nomem) +#add_script_test("${TARGET_NAME}-python3" "python3 ${PYTHON_LIBS} ${TEST_SCRIPT} " nomem) diff --git a/tests/automatic/bug_fixes/error-sending-data-using-callback-method/bugfix_callback.py b/tests/automatic/bug_fixes/error-sending-data-using-callback-method/bugfix_callback.py index 77d716f161a809b1e8ce1cf39658bada9a5a5282..5b8d930cb429495415e46bf883cb922d8d17e9ed 100644 --- a/tests/automatic/bug_fixes/error-sending-data-using-callback-method/bugfix_callback.py +++ b/tests/automatic/bug_fixes/error-sending-data-using-callback-method/bugfix_callback.py @@ -36,4 +36,4 @@ meta['name'] = stream+"/"+"file1" data = np.array([[1, 2, 3], [4, 5, 6]], np.float32) sender.send(data, meta) -producer.wait_requests_finished(5000) +producer.wait_requests_finished(15000) diff --git a/tests/automatic/bug_fixes/error-sending-data-using-callback-method/check_linux.sh b/tests/automatic/bug_fixes/error-sending-data-using-callback-method/check_linux.sh index 61baf3c850964854d1c13c5f8bf1722c17782481..67bf2b9a4cd680750662368ef86fe26c7870ab67 100644 --- a/tests/automatic/bug_fixes/error-sending-data-using-callback-method/check_linux.sh +++ b/tests/automatic/bug_fixes/error-sending-data-using-callback-method/check_linux.sh @@ -5,7 +5,7 @@ set -e trap Cleanup EXIT beamtime_id=asapo_test -stream=$1 +stream=python beamline=test receiver_root_folder=/tmp/asapo/receiver/files facility=test_facility diff --git a/tests/automatic/bug_fixes/error-sending-data-using-callback-method/check_windows.bat b/tests/automatic/bug_fixes/error-sending-data-using-callback-method/check_windows.bat index 4e4fce955a6f40d2ded16e39db10d4872333c615..e5affaa43e61d5c9d867bb2b4ff4f9fea838ebea 100644 --- a/tests/automatic/bug_fixes/error-sending-data-using-callback-method/check_windows.bat +++ b/tests/automatic/bug_fixes/error-sending-data-using-callback-method/check_windows.bat @@ -1,7 +1,7 @@ SET mongo_exe="c:\Program Files\MongoDB\Server\4.2\bin\mongo.exe" SET beamtime_id=asapo_test SET beamline=test -SET stream=%1 +SET stream=python SET receiver_root_folder=c:\tmp\asapo\receiver\files SET receiver_folder="%receiver_root_folder%\test_facility\gpfs\%beamline%\2019\data\%beamtime_id%" SET dbname = %beamtime_id%_%stream% diff --git a/tests/automatic/common/cpp/src/testing.cpp b/tests/automatic/common/cpp/src/testing.cpp index 72a0b23b52c122eab4bd08b93eefa7f6e1f5009a..ca14d633be5124850e88daf241bd26c5cebb56f4 100644 --- a/tests/automatic/common/cpp/src/testing.cpp +++ b/tests/automatic/common/cpp/src/testing.cpp @@ -16,7 +16,7 @@ void T_AssertEq(const T& expected, const T& got) { } void M_AssertTrue(bool value, std::string name) { - std::cout<<"asserting "<<name<<std::endl; + std::cout << "asserting " << name << std::endl; if (!value) { std::cerr << "Assert failed: " << name << "\n" << "Expected:\t'" << "1" << "'\n" diff --git a/tests/automatic/consumer/consumer_api/consumer_api.cpp b/tests/automatic/consumer/consumer_api/consumer_api.cpp index d47e758124c650aa72c505aff732d6e375518dcd..9a51b41a1a331689f4336e65a64fb2e670308858 100644 --- a/tests/automatic/consumer/consumer_api/consumer_api.cpp +++ b/tests/automatic/consumer/consumer_api/consumer_api.cpp @@ -126,7 +126,7 @@ void TestSingle(const std::unique_ptr<asapo::DataBroker>& broker, const std::str //streams - err = broker->GetNext(&fi, group_id,"stream1", nullptr); + err = broker->GetNext(&fi, group_id, "stream1", nullptr); if (err) { std::cout << err->Explain() << std::endl; } @@ -134,7 +134,7 @@ void TestSingle(const std::unique_ptr<asapo::DataBroker>& broker, const std::str M_AssertTrue(err == nullptr, "GetNext stream1 no error"); M_AssertTrue(fi.name == "11", "GetNext stream1 filename"); - err = broker->GetNext(&fi, group_id,"stream2", nullptr); + err = broker->GetNext(&fi, group_id, "stream2", nullptr); M_AssertTrue(err == nullptr, "GetNext stream2 no error"); M_AssertTrue(fi.name == "21", "GetNext stream2 filename"); diff --git a/tests/automatic/consumer/consumer_api_python/CMakeLists.txt b/tests/automatic/consumer/consumer_api_python/CMakeLists.txt index 02e91a3f390528430184f56f349813025b4a09d6..03b6ff48320be3947dcf696aa94c97a5efb63147 100644 --- a/tests/automatic/consumer/consumer_api_python/CMakeLists.txt +++ b/tests/automatic/consumer/consumer_api_python/CMakeLists.txt @@ -4,11 +4,11 @@ set(TARGET_NAME consumer_api_python) prepare_asapo() if (UNIX) - get_target_property(PYTHON_LIBS python-lib2 BINARY_DIR) + get_target_property(PYTHON_LIBS python-lib BINARY_DIR) else() get_target_property(PYTHON_LIBS asapo_consumer BINARY_DIR) endif() -add_script_test("${TARGET_NAME}" ${PYTHON_LIBS} nomem) +add_script_test("${TARGET_NAME}" "${PYTHON_LIBS} ${Python_EXECUTABLE}" nomem) configure_file(consumer_api.py consumer_api.py COPYONLY) diff --git a/tests/automatic/consumer/consumer_api_python/check_linux.sh b/tests/automatic/consumer/consumer_api_python/check_linux.sh index 90b7d62f268938f8cb3ff31150295d4a80033d24..df7485701ab514ba84090defcef0fdb2807f07e7 100644 --- a/tests/automatic/consumer/consumer_api_python/check_linux.sh +++ b/tests/automatic/consumer/consumer_api_python/check_linux.sh @@ -44,8 +44,8 @@ done sleep 1 export PYTHONPATH=$1:${PYTHONPATH} - -python consumer_api.py 127.0.0.1:8400 $source_path $beamtime_id $token_test_run single +export Python_EXECUTABLE=$2 +$Python_EXECUTABLE consumer_api.py 127.0.0.1:8400 $source_path $beamtime_id $token_test_run single #check datasets @@ -65,4 +65,4 @@ do done -python consumer_api.py 127.0.0.1:8400 $source_path $beamtime_id $token_test_run datasets +$Python_EXECUTABLE consumer_api.py 127.0.0.1:8400 $source_path $beamtime_id $token_test_run datasets diff --git a/tests/automatic/full_chain/simple_chain_usermeta_python/CMakeLists.txt b/tests/automatic/full_chain/simple_chain_usermeta_python/CMakeLists.txt index abb01d4f6cce9ed9c9e31682177cc82a720c5257..956e8dea68e05bdafdb875447c7dfd4d6c857475 100644 --- a/tests/automatic/full_chain/simple_chain_usermeta_python/CMakeLists.txt +++ b/tests/automatic/full_chain/simple_chain_usermeta_python/CMakeLists.txt @@ -6,10 +6,10 @@ set(TARGET_NAME full_chain_usermeta_python) prepare_asapo() if (UNIX) - get_target_property(PYTHON_LIBS python-lib2 BINARY_DIR) + get_target_property(PYTHON_LIBS python-lib BINARY_DIR) else() get_target_property(PYTHON_LIBS asapo_consumer BINARY_DIR) endif() -add_script_test("${TARGET_NAME}" "$<TARGET_FILE:dummy-data-producer> $<TARGET_PROPERTY:asapo,EXENAME> ${CMAKE_CURRENT_SOURCE_DIR} ${PYTHON_LIBS}" nomem) +add_script_test("${TARGET_NAME}" "$<TARGET_FILE:dummy-data-producer> $<TARGET_PROPERTY:asapo,EXENAME> ${CMAKE_CURRENT_SOURCE_DIR} ${PYTHON_LIBS} ${Python_EXECUTABLE}" nomem) diff --git a/tests/automatic/full_chain/simple_chain_usermeta_python/check_linux.sh b/tests/automatic/full_chain/simple_chain_usermeta_python/check_linux.sh index fe028afa24a02e9b5feaddbc0f720de148e8bcd5..fca9fca048d39be93477e413caf1095977289158 100644 --- a/tests/automatic/full_chain/simple_chain_usermeta_python/check_linux.sh +++ b/tests/automatic/full_chain/simple_chain_usermeta_python/check_linux.sh @@ -46,9 +46,10 @@ mkdir -p ${receiver_folder} $1 localhost:8400 ${beamtime_id} 100 100 1 0 100 export PYTHONPATH=$4:${PYTHONPATH} +export Python_EXECUTABLE=$5 -python $3/get_user_meta.py $proxy_address $receiver_folder $beamtime_id $token new > out +$Python_EXECUTABLE $3/get_user_meta.py $proxy_address $receiver_folder $beamtime_id $token new > out cat out cat out | grep "found images: 100" cat out | grep "test100" diff --git a/tests/automatic/producer/python_api/CMakeLists.txt b/tests/automatic/producer/python_api/CMakeLists.txt index 0fccc0377100d8aee0d253fffc19b49532903183..8e8282c914c64197afab2716f74734d94d89b0a5 100644 --- a/tests/automatic/producer/python_api/CMakeLists.txt +++ b/tests/automatic/producer/python_api/CMakeLists.txt @@ -8,7 +8,7 @@ prepare_asapo() prepare_asapo() if (UNIX) - get_target_property(PYTHON_LIBS python-lib2-producer BINARY_DIR) + get_target_property(PYTHON_LIBS python-lib-producer BINARY_DIR) else() get_target_property(PYTHON_LIBS asapo_producer BINARY_DIR) endif() @@ -16,8 +16,7 @@ endif() file(TO_NATIVE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/producer_api.py TEST_SCRIPT ) -add_script_test("${TARGET_NAME}-python2" "python ${PYTHON_LIBS} ${TEST_SCRIPT} " nomem) +add_script_test("${TARGET_NAME}-python" "${Python_EXECUTABLE} ${PYTHON_LIBS} ${TEST_SCRIPT} " nomem) -add_script_test("${TARGET_NAME}-python3" "python3 ${PYTHON_LIBS} ${TEST_SCRIPT} " nomem) diff --git a/tests/automatic/producer/python_api/check_linux.sh b/tests/automatic/producer/python_api/check_linux.sh index 4989ca00ad0df537e0b4e12063e862c3d239e671..3a332e03d9866d8b987a11df9647ccedc469289c 100644 --- a/tests/automatic/producer/python_api/check_linux.sh +++ b/tests/automatic/producer/python_api/check_linux.sh @@ -5,7 +5,7 @@ set -e trap Cleanup EXIT beamtime_id=asapo_test -stream=$1 +stream=python beamline=test receiver_root_folder=/tmp/asapo/receiver/files facility=test_facility @@ -26,7 +26,7 @@ Cleanup() { export PYTHONPATH=$2:${PYTHONPATH} -echo "db.${beamtime_id}_${stream}.insert({dummy:1})" | mongo ${beamtime_id}_${stream} >/dev/null +echo "db.${beamtime_id}_${stream}.insert({dummy:1})" | mongo ${beamtime_id}_${stream} >/dev/null nomad run authorizer.nmd >/dev/null nomad run nginx.nmd >/dev/null diff --git a/tests/automatic/producer/python_api/check_windows.bat b/tests/automatic/producer/python_api/check_windows.bat index 3d5386b7a95ff1ff4a108f4a168c4ab0b42a4b92..01c8380785c2959e04b0ead2a8395cfdcfe81a45 100644 --- a/tests/automatic/producer/python_api/check_windows.bat +++ b/tests/automatic/producer/python_api/check_windows.bat @@ -1,7 +1,7 @@ SET mongo_exe="c:\Program Files\MongoDB\Server\4.2\bin\mongo.exe" SET beamtime_id=asapo_test SET beamline=test -SET stream=%1 +SET stream=python SET receiver_root_folder=c:\tmp\asapo\receiver\files SET receiver_folder="%receiver_root_folder%\test_facility\gpfs\%beamline%\2019\data\%beamtime_id%" SET dbname = %beamtime_id%_%stream% diff --git a/tests/manual/python_tests/producer/asapo_producer.so b/tests/manual/python_tests/producer/asapo_producer.so deleted file mode 120000 index cd186e18092ad6fd8de0e7ab30f6b7a4b5417775..0000000000000000000000000000000000000000 --- a/tests/manual/python_tests/producer/asapo_producer.so +++ /dev/null @@ -1 +0,0 @@ -/home/yakubov/projects/asapo/cmake-build-debug/producer/api/python/asapo_producer.so \ No newline at end of file diff --git a/tests/manual/python_tests/producer_wait_bug_mongo/asapo_producer.so b/tests/manual/python_tests/producer_wait_bug_mongo/asapo_producer.so deleted file mode 120000 index cd186e18092ad6fd8de0e7ab30f6b7a4b5417775..0000000000000000000000000000000000000000 --- a/tests/manual/python_tests/producer_wait_bug_mongo/asapo_producer.so +++ /dev/null @@ -1 +0,0 @@ -/home/yakubov/projects/asapo/cmake-build-debug/producer/api/python/asapo_producer.so \ No newline at end of file diff --git a/tests/manual/python_tests/producer_wait_threads/asapo_producer.so b/tests/manual/python_tests/producer_wait_threads/asapo_producer.so deleted file mode 120000 index cd186e18092ad6fd8de0e7ab30f6b7a4b5417775..0000000000000000000000000000000000000000 --- a/tests/manual/python_tests/producer_wait_threads/asapo_producer.so +++ /dev/null @@ -1 +0,0 @@ -/home/yakubov/projects/asapo/cmake-build-debug/producer/api/python/asapo_producer.so \ No newline at end of file