From 868ff467c404e4f244d609101595f061c3dbdadb Mon Sep 17 00:00:00 2001 From: David Gardner <96306125+dagardner-nv@users.noreply.github.com> Date: Tue, 28 Jan 2025 08:22:20 -0800 Subject: [PATCH 1/9] Suppress spurious socket error messages from `GenerateVizFramesStage` on shutdown (#2137) * Don't log error messages if `_server_close_event` has already been set. * Unrelated documentation improvement for the RabbitMQ examples to ensue the `MORPHEUS_ROOT` environment variable is set. Closes #2135 ## By Submitting this PR I confirm: - I am familiar with the [Contributing Guidelines](https://github.com/nv-morpheus/Morpheus/blob/main/docs/source/developer_guide/contributing.md). - When the PR is ready for review, new or existing tests cover these changes. - When the PR is ready for review, the documentation is up to date with these changes. Authors: - David Gardner (https://github.com/dagardner-nv) Approvers: - Eli Fajardo (https://github.com/efajardo-nv) URL: https://github.com/nv-morpheus/Morpheus/pull/2137 --- examples/developer_guide/2_2_rabbitmq/README.md | 1 + examples/developer_guide/4_rabbitmq_cpp_stage/README.md | 2 ++ .../stages/postprocess/generate_viz_frames_stage.py | 6 ++++-- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/examples/developer_guide/2_2_rabbitmq/README.md b/examples/developer_guide/2_2_rabbitmq/README.md index 540c412b3..63fe92542 100644 --- a/examples/developer_guide/2_2_rabbitmq/README.md +++ b/examples/developer_guide/2_2_rabbitmq/README.md @@ -44,6 +44,7 @@ pip install -r examples/developer_guide/2_2_rabbitmq/requirements.txt ## Launch the reader In a second terminal from the root of the Morpheus repo execute: ```bash +export MORPHEUS_ROOT=$(pwd) python examples/developer_guide/2_2_rabbitmq/read_simple.py ``` diff --git a/examples/developer_guide/4_rabbitmq_cpp_stage/README.md b/examples/developer_guide/4_rabbitmq_cpp_stage/README.md index 8799e91c5..cd3a54ac1 100644 --- a/examples/developer_guide/4_rabbitmq_cpp_stage/README.md +++ b/examples/developer_guide/4_rabbitmq_cpp_stage/README.md @@ -58,6 +58,7 @@ The image can be verified with the web management console by opening http://loca ## Launch the reader In a second terminal from the root of the Morpheus repo execute: ```bash +export MORPHEUS_ROOT=$(pwd) python examples/developer_guide/4_rabbitmq_cpp_stage/src/read_simple.py ``` @@ -68,6 +69,7 @@ If no exchange named 'logs' exists in RabbitMQ it will be created. ## Launch the writer In a third terminal from the root of the Morpheus repo execute: ```bash +export MORPHEUS_ROOT=$(pwd) python examples/developer_guide/4_rabbitmq_cpp_stage/src/write_simple.py ``` diff --git a/python/morpheus/morpheus/stages/postprocess/generate_viz_frames_stage.py b/python/morpheus/morpheus/stages/postprocess/generate_viz_frames_stage.py index 24a07bfe5..efa743982 100644 --- a/python/morpheus/morpheus/stages/postprocess/generate_viz_frames_stage.py +++ b/python/morpheus/morpheus/stages/postprocess/generate_viz_frames_stage.py @@ -25,7 +25,7 @@ import pandas as pd import pyarrow as pa import websockets.legacy.server -from websockets.server import serve +from websockets.server import serve # pylint: disable=no-name-in-module from morpheus.cli.register_stage import register_stage from morpheus.config import Config @@ -207,7 +207,9 @@ async def client_connected(websocket: websockets.legacy.server.WebSocketServerPr except Closed: break except Exception as ex: - logger.exception("Error occurred trying to send message over socket", exc_info=ex) + if not self._server_close_event.is_set(): + # Don't log if we are shutting down + logger.exception("Error occurred trying to send message over socket", exc_info=ex) logger.info("Disconnected from: %s:%s", *websocket.remote_address) From 6e2d715be7948a5cbc606e0e74dea620aa6f22df Mon Sep 17 00:00:00 2001 From: Eli Fajardo Date: Tue, 28 Jan 2025 15:19:07 -0500 Subject: [PATCH 2/9] Update `abp_nvsmi_detection` example README (#2138) - Update reference to output file to match name used in command - Change `0` and `1` to `false` and `true` in example results to match what was seen after running example ## By Submitting this PR I confirm: - I am familiar with the [Contributing Guidelines](https://github.com/nv-morpheus/Morpheus/blob/main/docs/source/developer_guide/contributing.md). - When the PR is ready for review, new or existing tests cover these changes. - When the PR is ready for review, the documentation is up to date with these changes. Authors: - Eli Fajardo (https://github.com/efajardo-nv) Approvers: - David Gardner (https://github.com/dagardner-nv) URL: https://github.com/nv-morpheus/Morpheus/pull/2138 --- examples/abp_nvsmi_detection/README.md | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/examples/abp_nvsmi_detection/README.md b/examples/abp_nvsmi_detection/README.md index 445b44809..9d4133c44 100644 --- a/examples/abp_nvsmi_detection/README.md +++ b/examples/abp_nvsmi_detection/README.md @@ -225,22 +225,22 @@ Inference Rate[Complete]: 1242inf [00:00, 1863.04inf/s] ====Pipeline Complete==== ``` -The output file `.tmp/output/detections.jsonlines` will contain a single boolean value for each input line. At some point the values will switch from `0` to `1`: +The output file `.tmp/output/abp_nvsmi_detections.jsonlines` will contain a single boolean value for each input line. At some point the values will switch from `false` to `true`: ``` ... -{"mining": 0} -{"mining": 0} -{"mining": 0} -{"mining": 0} -{"mining": 1} -{"mining": 1} -{"mining": 1} -{"mining": 1} -{"mining": 1} -{"mining": 1} -{"mining": 1} -{"mining": 1} +{"mining": false} +{"mining": false} +{"mining": false} +{"mining": false} +{"mining": true} +{"mining": true} +{"mining": true} +{"mining": true} +{"mining": true} +{"mining": true} +{"mining": true} +{"mining": true} ... ``` From 199eae29fbaf01f6dab6ae4d53276947a3d1dd36 Mon Sep 17 00:00:00 2001 From: Yuchen Zhang <134643420+yczhang-nv@users.noreply.github.com> Date: Wed, 29 Jan 2025 05:41:10 +0800 Subject: [PATCH 3/9] Fix C++ version of `MonitorStage` output issue caused by out of order function calls (#2140) image - [#2121](https://github.com/nv-morpheus/Morpheus/pull/2121) ensures the cursor is reset to the last line of output after shutdown by adding `ProgressBarContextManager::mark_pbar_as_completed()`. - When executing some of the pipelines, race conditions may cause calling `ProgressBarContextManager::display_all()` after `ProgressBarContextManager::mark_pbar_as_completed()`, which intermittently causes the log display issue above - which should has been fixed by this PR. Closes #2119 ## By Submitting this PR I confirm: - I am familiar with the [Contributing Guidelines](https://github.com/nv-morpheus/Morpheus/blob/main/docs/source/developer_guide/contributing.md). - When the PR is ready for review, new or existing tests cover these changes. - When the PR is ready for review, the documentation is up to date with these changes. Authors: - Yuchen Zhang (https://github.com/yczhang-nv) - David Gardner (https://github.com/dagardner-nv) Approvers: - David Gardner (https://github.com/dagardner-nv) - Will Killian (https://github.com/willkill07) URL: https://github.com/nv-morpheus/Morpheus/pull/2140 --- .../morpheus/controllers/monitor_controller.hpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/python/morpheus/morpheus/_lib/include/morpheus/controllers/monitor_controller.hpp b/python/morpheus/morpheus/_lib/include/morpheus/controllers/monitor_controller.hpp index 3028f924a..a2624321c 100644 --- a/python/morpheus/morpheus/_lib/include/morpheus/controllers/monitor_controller.hpp +++ b/python/morpheus/morpheus/_lib/include/morpheus/controllers/monitor_controller.hpp @@ -104,6 +104,12 @@ class ProgressBarContextManager { std::lock_guard lock(m_mutex); + // To avoid display_all() being executed after calling mark_pbar_as_completed() in some race conditions + if (m_is_completed) + { + return; + } + // A bit of hack here to make the font settings work. Indicators enables the font options only if the bars are // output to standard streams (see is_colorized() in ), but since we are still using // the ostream (m_stdout_os) that is connected to the console terminal, the font options should be enabled. @@ -114,11 +120,11 @@ class ProgressBarContextManager { pbar->print_progress(true); m_stdout_os << termcolor::reset; // The font option only works for the current bar - m_stdout_os << "\n"; + m_stdout_os << std::endl; } // After each round of display, move cursor up ("\033[A") to the beginning of the first bar - m_stdout_os << "\033[" << m_progress_bars.size() << "A"; + m_stdout_os << "\033[" << m_progress_bars.size() << "A" << std::flush; } void mark_pbar_as_completed(size_t bar_id) From dfd285f2261d542aed67b2b20731da997a651225 Mon Sep 17 00:00:00 2001 From: David Gardner Date: Wed, 29 Jan 2025 09:23:12 -0800 Subject: [PATCH 4/9] Make it clear when each approach should be taken --- .../developer_guide/guides/3_simple_cpp_stage.md | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/docs/source/developer_guide/guides/3_simple_cpp_stage.md b/docs/source/developer_guide/guides/3_simple_cpp_stage.md index 63e6285a6..696f8a5f7 100644 --- a/docs/source/developer_guide/guides/3_simple_cpp_stage.md +++ b/docs/source/developer_guide/guides/3_simple_cpp_stage.md @@ -17,12 +17,19 @@ limitations under the License. # Simple C++ Stage ## Building the Example -The code for this guide can be found in the `examples/developer_guide/3_simple_cpp_stage` directory of the Morpheus repository. There are two ways to build the example. The first is to build the examples along with Morpheus by passing the `-DMORPHEUS_BUILD_EXAMPLES=ON` flag to CMake, for users using the `scripts/compile.sh` at the root of the Morpheus repo can do this by setting the `CMAKE_CONFIGURE_EXTRA_ARGS` environment variable: +The code for this guide can be found in the `examples/developer_guide/3_simple_cpp_stage` directory of the Morpheus repository. There are two ways to build the example. + +The first is to build the examples along with Morpheus by passing the `-DMORPHEUS_BUILD_EXAMPLES=ON` flag to CMake. This approach is preferable for users who are already building Morpheus from source. For users using the `scripts/compile.sh` at the root of the Morpheus repo can do this by setting the `CMAKE_CONFIGURE_EXTRA_ARGS` environment variable: ```bash CMAKE_CONFIGURE_EXTRA_ARGS="-DMORPHEUS_BUILD_EXAMPLES=ON" ./scripts/compile.sh ``` -The second method is to build the example as a standalone project. From the root of the Morpheus repo execute: +The second method is to build the example as a standalone project. For those using the release container, additional dependencies will need to be installed prior to performing the build: +```bash +conda env update --solver=libmamba -n morpheus --file /workspace/conda/environments/dev_cuda-125_arch-$(arch).yaml +``` + +From the root of the Morpheus repo execute: ```bash cd examples/developer_guide/3_simple_cpp_stage ./compile.sh From 25102540d3fb0607977c6e855dce78116ff94258 Mon Sep 17 00:00:00 2001 From: David Gardner Date: Wed, 29 Jan 2025 09:23:28 -0800 Subject: [PATCH 5/9] Hopefully this works --- cmake/dependencies.cmake | 1 + 1 file changed, 1 insertion(+) diff --git a/cmake/dependencies.cmake b/cmake/dependencies.cmake index 04cefb999..0eda826d5 100644 --- a/cmake/dependencies.cmake +++ b/cmake/dependencies.cmake @@ -60,6 +60,7 @@ rapids_find_package(gflags REQUIRED # glog # ==== morpheus_utils_configure_glog() +add_compile_definitions(GLOG_USE_GLOG_EXPORT) if(MORPHEUS_BUILD_TESTS) # google test From 7778adf2d1c0591881727117e67f6ac616f1b127 Mon Sep 17 00:00:00 2001 From: David Gardner Date: Wed, 29 Jan 2025 10:06:22 -0800 Subject: [PATCH 6/9] Revert "Hopefully this works" This reverts commit 25102540d3fb0607977c6e855dce78116ff94258. --- cmake/dependencies.cmake | 1 - 1 file changed, 1 deletion(-) diff --git a/cmake/dependencies.cmake b/cmake/dependencies.cmake index 0eda826d5..04cefb999 100644 --- a/cmake/dependencies.cmake +++ b/cmake/dependencies.cmake @@ -60,7 +60,6 @@ rapids_find_package(gflags REQUIRED # glog # ==== morpheus_utils_configure_glog() -add_compile_definitions(GLOG_USE_GLOG_EXPORT) if(MORPHEUS_BUILD_TESTS) # google test From 91a2d25bf2c090593b51fa1b5349ba44865c8368 Mon Sep 17 00:00:00 2001 From: David Gardner Date: Wed, 29 Jan 2025 14:04:39 -0800 Subject: [PATCH 7/9] Use -exports not -core-exports --- cmake/dependencies.cmake | 20 +++++++++---------- .../morpheus/_lib/cmake/libmorpheus.cmake | 10 +++++----- .../morpheus/_lib/doca/CMakeLists.txt | 4 ++-- .../_lib/cmake/libmorpheus_llm.cmake | 15 +++++++------- 4 files changed, 24 insertions(+), 25 deletions(-) diff --git a/cmake/dependencies.cmake b/cmake/dependencies.cmake index 04cefb999..35d1c4abd 100644 --- a/cmake/dependencies.cmake +++ b/cmake/dependencies.cmake @@ -25,18 +25,18 @@ include(${CMAKE_CURRENT_LIST_DIR}/package_config/register_api.cmake) # Load direct physical package dependencies first, so we fail early. Add all dependencies to our export set rapids_find_package(Protobuf REQUIRED - BUILD_EXPORT_SET ${PROJECT_NAME}-core-exports - INSTALL_EXPORT_SET ${PROJECT_NAME}-core-exports + BUILD_EXPORT_SET ${PROJECT_NAME}-exports + INSTALL_EXPORT_SET ${PROJECT_NAME}-exports ) rapids_find_package(CUDAToolkit REQUIRED - BUILD_EXPORT_SET ${PROJECT_NAME}-core-exports - INSTALL_EXPORT_SET ${PROJECT_NAME}-core-exports + BUILD_EXPORT_SET ${PROJECT_NAME}-exports + INSTALL_EXPORT_SET ${PROJECT_NAME}-exports ) rapids_find_package(ZLIB - BUILD_EXPORT_SET ${PROJECT_NAME}-core-exports - INSTALL_EXPORT_SET ${PROJECT_NAME}-core-exports + BUILD_EXPORT_SET ${PROJECT_NAME}-exports + INSTALL_EXPORT_SET ${PROJECT_NAME}-exports ) if(MORPHEUS_BUILD_BENCHMARKS) @@ -44,8 +44,8 @@ if(MORPHEUS_BUILD_BENCHMARKS) # ================ include(${rapids-cmake-dir}/cpm/gbench.cmake) rapids_cpm_gbench( - BUILD_EXPORT_SET ${PROJECT_NAME}-core-exports - INSTALL_EXPORT_SET ${PROJECT_NAME}-core-exports + BUILD_EXPORT_SET ${PROJECT_NAME}-exports + INSTALL_EXPORT_SET ${PROJECT_NAME}-exports ) endif() @@ -66,8 +66,8 @@ if(MORPHEUS_BUILD_TESTS) # =========== include(${rapids-cmake-dir}/cpm/gtest.cmake) rapids_cpm_gtest( - BUILD_EXPORT_SET ${PROJECT_NAME}-core-exports - INSTALL_EXPORT_SET ${PROJECT_NAME}-core-exports + BUILD_EXPORT_SET ${PROJECT_NAME}-exports + INSTALL_EXPORT_SET ${PROJECT_NAME}-exports ) endif() diff --git a/python/morpheus/morpheus/_lib/cmake/libmorpheus.cmake b/python/morpheus/morpheus/_lib/cmake/libmorpheus.cmake index a9c99cf09..023039884 100644 --- a/python/morpheus/morpheus/_lib/cmake/libmorpheus.cmake +++ b/python/morpheus/morpheus/_lib/cmake/libmorpheus.cmake @@ -185,13 +185,13 @@ include(GNUInstallDirs) install( TARGETS - morpheus + morpheus EXPORT - ${PROJECT_NAME}-core-exports + ${PROJECT_NAME}-exports LIBRARY DESTINATION ${lib_dir} FILE_SET - public_headers + public_headers ) # ################################################################################################## @@ -221,7 +221,7 @@ endif() # Need to explicitly set VERSION ${PROJECT_VERSION} here since rapids_cmake gets # confused with the `RAPIDS_VERSION` variable we use rapids_export(INSTALL ${PROJECT_NAME} - EXPORT_SET ${PROJECT_NAME}-core-exports + EXPORT_SET ${PROJECT_NAME}-exports GLOBAL_TARGETS morpheus VERSION ${PROJECT_VERSION} NAMESPACE morpheus:: @@ -232,7 +232,7 @@ rapids_export(INSTALL ${PROJECT_NAME} # ################################################################################################## # - build export ---------------------------------------------------------------------------------- rapids_export(BUILD ${PROJECT_NAME} - EXPORT_SET ${PROJECT_NAME}-core-exports + EXPORT_SET ${PROJECT_NAME}-exports GLOBAL_TARGETS morpheus VERSION ${PROJECT_VERSION} LANGUAGES C CXX CUDA diff --git a/python/morpheus/morpheus/_lib/doca/CMakeLists.txt b/python/morpheus/morpheus/_lib/doca/CMakeLists.txt index 59236e87b..1d66aaa38 100644 --- a/python/morpheus/morpheus/_lib/doca/CMakeLists.txt +++ b/python/morpheus/morpheus/_lib/doca/CMakeLists.txt @@ -66,7 +66,7 @@ target_sources(morpheus_doca TYPE HEADERS BASE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/include" FILES - ${morpheus_doca_public_headers} + ${morpheus_doca_public_headers} ) target_compile_definitions(morpheus_doca @@ -96,7 +96,7 @@ install( TARGETS morpheus_doca EXPORT - ${PROJECT_NAME}-core-exports + ${PROJECT_NAME}-exports LIBRARY DESTINATION ${lib_dir} FILE_SET diff --git a/python/morpheus_llm/morpheus_llm/_lib/cmake/libmorpheus_llm.cmake b/python/morpheus_llm/morpheus_llm/_lib/cmake/libmorpheus_llm.cmake index 2b3bdbef4..a0d2b42ce 100644 --- a/python/morpheus_llm/morpheus_llm/_lib/cmake/libmorpheus_llm.cmake +++ b/python/morpheus_llm/morpheus_llm/_lib/cmake/libmorpheus_llm.cmake @@ -29,11 +29,11 @@ add_library(${PROJECT_NAME}::morpheus_llm ALIAS morpheus_llm) # morpheus_llm can be built two ways - # 1. For development purposes (eg. scripts/compile.sh) all the functional blocks are built. -# This includes morpheus (core), morpheus_llm, morpheus_dfp etc. In this case we -# set dependencies on build targets across components. +# This includes morpheus (core), morpheus_llm, morpheus_dfp etc. In this case we +# set dependencies on build targets across components. # 2. For conda packaging purposes morpheus_llm is built on its own. In this case -# the dependencies (including morpheus-core) are loaded from the conda enviroment. -if (MORPHEUS_BUILD_MORPHEUS_CORE) +# the dependencies (including morpheus-core) are loaded from the conda enviroment. +if(MORPHEUS_BUILD_MORPHEUS_CORE) # Add a dependency on the morpheus cpython libraries get_property(py_morpheus_target GLOBAL PROPERTY py_morpheus_target_property) add_dependencies(morpheus_llm ${py_morpheus_target}) @@ -81,7 +81,6 @@ target_sources(morpheus_llm ${morpheus_llm_public_headers} ) - # We want to use RUNPATH instead of RPATH to allow LD_LIBRARY_PATH to take precedence over the paths specified in the # binary. This is necessary to allow ld to find the real libcuda.so instead of the stub. Eventually, this can be removed # once upgraded to cuda-python 12.1. Ideally, cuda-python would just load libcuda.so.1 which would take precedence over @@ -113,11 +112,11 @@ include(GNUInstallDirs) install( TARGETS - morpheus_llm + morpheus_llm EXPORT - ${PROJECT_NAME}-core-exports + ${PROJECT_NAME}-exports LIBRARY DESTINATION ${lib_dir} FILE_SET - public_headers + public_headers ) From 1e7f9efad7655ab6c18a6bcee548c3640049c3ac Mon Sep 17 00:00:00 2001 From: David Gardner Date: Wed, 29 Jan 2025 14:05:54 -0800 Subject: [PATCH 8/9] Use -exports not -core-exports --- .../cmake/Configure_SimpleAmqpClient.cmake | 26 +++++++++---------- .../cmake/Configure_rabbitmq.cmake | 23 +++++++--------- 2 files changed, 22 insertions(+), 27 deletions(-) diff --git a/examples/developer_guide/4_rabbitmq_cpp_stage/cmake/Configure_SimpleAmqpClient.cmake b/examples/developer_guide/4_rabbitmq_cpp_stage/cmake/Configure_SimpleAmqpClient.cmake index 6033d28df..2f2148fe7 100644 --- a/examples/developer_guide/4_rabbitmq_cpp_stage/cmake/Configure_SimpleAmqpClient.cmake +++ b/examples/developer_guide/4_rabbitmq_cpp_stage/cmake/Configure_SimpleAmqpClient.cmake @@ -1,4 +1,4 @@ -#============================================================================= +# ============================================================================= # SPDX-FileCopyrightText: Copyright (c) 2022-2025, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # @@ -6,17 +6,16 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -#============================================================================= +# ============================================================================= function(find_and_configure_SimpleAmqpClient version) - list(APPEND CMAKE_MESSAGE_CONTEXT "SimpleAmqpClient") find_package(rabbitmq REQUIRED) @@ -25,18 +24,18 @@ function(find_and_configure_SimpleAmqpClient version) GLOBAL_TARGETS SimpleAmqpClient BUILD_EXPORT_SET - ${PROJECT_NAME}-core-exports + ${PROJECT_NAME}-exports INSTALL_EXPORT_SET - ${PROJECT_NAME}-core-exports + ${PROJECT_NAME}-exports CPM_ARGS PATCH_COMMAND git checkout -- . && git apply --whitespace=fix ${CMAKE_CURRENT_FUNCTION_LIST_DIR}/patches/simpleamqpclient_cpp_version.patch - GIT_REPOSITORY https://github.com/alanxz/SimpleAmqpClient - GIT_TAG "v${version}" - GIT_SHALLOW TRUE - OPTIONS "Rabbitmqc_INCLUDE_DIR ${rabbitmq_SOURCE_DIR}/include" - "Rabbitmqc_LIBRARY ${rabbitmq_BINARY_DIR}/librabbitmq/librabbitmq.so" - "BUILD_API_DOCS OFF" - "BUILD_SHARED_LIBS OFF" + GIT_REPOSITORY https://github.com/alanxz/SimpleAmqpClient + GIT_TAG "v${version}" + GIT_SHALLOW TRUE + OPTIONS "Rabbitmqc_INCLUDE_DIR ${rabbitmq_SOURCE_DIR}/include" + "Rabbitmqc_LIBRARY ${rabbitmq_BINARY_DIR}/librabbitmq/librabbitmq.so" + "BUILD_API_DOCS OFF" + "BUILD_SHARED_LIBS OFF" ) # Needed to pick up the generated export.h @@ -45,7 +44,6 @@ function(find_and_configure_SimpleAmqpClient version) # Suppress #warning deprecation messages from rabbitmq and SimpleAmqpClient # https://github.com/nv-morpheus/Morpheus/issues/1255 target_compile_options(SimpleAmqpClient PRIVATE -Wno-cpp -DBOOST_DISABLE_PRAGMA_MESSAGE) - endfunction() find_and_configure_SimpleAmqpClient(${SIMPLE_AMQP_CLIENT_VERSION}) diff --git a/examples/developer_guide/4_rabbitmq_cpp_stage/cmake/Configure_rabbitmq.cmake b/examples/developer_guide/4_rabbitmq_cpp_stage/cmake/Configure_rabbitmq.cmake index 44620be59..6662e2681 100644 --- a/examples/developer_guide/4_rabbitmq_cpp_stage/cmake/Configure_rabbitmq.cmake +++ b/examples/developer_guide/4_rabbitmq_cpp_stage/cmake/Configure_rabbitmq.cmake @@ -1,4 +1,4 @@ -#============================================================================= +# ============================================================================= # SPDX-FileCopyrightText: Copyright (c) 2022-2025, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # @@ -6,42 +6,39 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -#============================================================================= +# ============================================================================= function(find_and_configure_rabbitmq version) - list(APPEND CMAKE_MESSAGE_CONTEXT "rabbitmq") # Commit 7fa7b0b contains unreleased cmake fixes which currently only exist in the master branch of the repo. # https://github.com/alanxz/rabbitmq-c/issues/740 - rapids_cpm_find(rabbitmq ${version} GLOBAL_TARGETS rabbitmq rabbitmq::rabbitmq BUILD_EXPORT_SET - ${PROJECT_NAME}-core-exports + ${PROJECT_NAME}-exports INSTALL_EXPORT_SET - ${PROJECT_NAME}-core-exports + ${PROJECT_NAME}-exports CPM_ARGS - GIT_REPOSITORY https://github.com/alanxz/rabbitmq-c - GIT_SHALLOW TRUE - OPTIONS "BUILD_EXAMPLES OFF" - "BUILD_TESTING OFF" - "BUILD_TOOLS OFF" + GIT_REPOSITORY https://github.com/alanxz/rabbitmq-c + GIT_SHALLOW TRUE + OPTIONS "BUILD_EXAMPLES OFF" + "BUILD_TESTING OFF" + "BUILD_TOOLS OFF" ) if(rabbitmq_ADDED) set(rabbitmq_SOURCE_DIR "${rabbitmq_SOURCE_DIR}" PARENT_SCOPE) set(rabbitmq_BINARY_DIR "${rabbitmq_BINARY_DIR}" PARENT_SCOPE) endif() - endfunction() find_and_configure_rabbitmq(${RABBITMQ_VERSION}) From 254c43f3e14761694f72a13065561b6fc87dafd9 Mon Sep 17 00:00:00 2001 From: David Gardner Date: Wed, 29 Jan 2025 15:45:03 -0800 Subject: [PATCH 9/9] wip don't merge --- .../3_simple_cpp_stage/src/simple_cpp_stage/_lib/CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/developer_guide/3_simple_cpp_stage/src/simple_cpp_stage/_lib/CMakeLists.txt b/examples/developer_guide/3_simple_cpp_stage/src/simple_cpp_stage/_lib/CMakeLists.txt index 38a753dcb..343e089bc 100644 --- a/examples/developer_guide/3_simple_cpp_stage/src/simple_cpp_stage/_lib/CMakeLists.txt +++ b/examples/developer_guide/3_simple_cpp_stage/src/simple_cpp_stage/_lib/CMakeLists.txt @@ -24,6 +24,7 @@ morpheus_add_pybind11_module(pass_thru_cpp morpheus CUDA::nvtx3 cudf::cudf + glog::glog ) list(POP_BACK CMAKE_MESSAGE_CONTEXT)