This is an automated email from the ASF dual-hosted git repository.

lizhimins pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/rocketmq-clients.git


The following commit(s) were added to refs/heads/master by this push:
     new 725539a0 fix(cpp): propagate resource namespace in FifoProducerBuilder 
(#1510)
725539a0 is described below

commit 725539a0efe11608f5999510a7fa0e4a0145b88e
Author: lizhimins <[email protected]>
AuthorDate: Fri Nov 27 17:28:35 2026 +0800

    fix(cpp): propagate resource namespace in FifoProducerBuilder (#1510)
    
    Fixes #1509.
    
    Propagate configuration.resourceNamespace() in 
FifoProducerBuilder::withConfiguration
    so FIFO producers send the x-mq-namespace header and authenticate on 
namespaced
    instances, mirroring ProducerBuilder.
    
    Also pin the macOS CMake CI job to macos-15 / OpenSSL 1.1: macos-latest now 
ships
    OpenSSL 4.x, which gRPC 1.46.3 cannot compile against (const-correctness API
    changes in ssl_transport_security.cc).
---
 .github/workflows/cpp_build.yml      | 14 +++++++++++---
 cpp/source/rocketmq/FifoProducer.cpp |  1 +
 2 files changed, 12 insertions(+), 3 deletions(-)

diff --git a/.github/workflows/cpp_build.yml b/.github/workflows/cpp_build.yml
index 066b4201..65c5fdfd 100644
--- a/.github/workflows/cpp_build.yml
+++ b/.github/workflows/cpp_build.yml
@@ -4,11 +4,14 @@ on:
 jobs:
   cmake-build:
     name: "CMake ${{ matrix.os }}"
-    runs-on: ${{ matrix.os }}
+    runs-on: ${{ matrix.runner || matrix.os }}
     strategy:
       fail-fast: false
       matrix:
         os: [ubuntu-22.04, macos-latest, windows-2022]
+        include:
+          - os: macos-latest
+            runner: macos-15
     steps:
       - uses: actions/checkout@v3
         with:
@@ -20,7 +23,12 @@ jobs:
 
       - name: Install dependencies (macOS)
         if: runner.os == 'macOS'
-        run: brew install openssl zlib
+        run: |
+          brew install zlib
+          # gRPC 1.46.3 cannot compile against OpenSSL 3.x/4.x 
(const-correctness
+          # API changes). Use the OpenSSL 1.1 pre-installed on the macos-15 
image
+          # for both gRPC and the SDK so they link a single, compatible 
OpenSSL.
+          echo "OPENSSL_ROOT_DIR=$(brew --prefix [email protected])" >> "$GITHUB_ENV"
 
       - name: Install dependencies (Windows)
         if: runner.os == 'Windows'
@@ -31,7 +39,7 @@ jobs:
         uses: actions/cache@v3
         with:
           path: ${{ runner.temp }}/grpc-install
-          key: grpc-1.46.3-${{ matrix.os }}
+          key: grpc-1.46.3-${{ matrix.runner || matrix.os }}
 
       - name: Build gRPC from source
         if: steps.cache-grpc.outputs.cache-hit != 'true'
diff --git a/cpp/source/rocketmq/FifoProducer.cpp 
b/cpp/source/rocketmq/FifoProducer.cpp
index 32971ad4..ffdc9c8f 100644
--- a/cpp/source/rocketmq/FifoProducer.cpp
+++ b/cpp/source/rocketmq/FifoProducer.cpp
@@ -45,6 +45,7 @@ FifoProducerBuilder& 
FifoProducerBuilder::withConfiguration(Configuration config
   producer_impl_->withCredentialsProvider(configuration.credentialsProvider());
   producer_impl_->withRequestTimeout(configuration.requestTimeout());
   producer_impl_->withSsl(configuration.withSsl());
+  producer_impl_->withResourceNamespace(configuration.resourceNamespace());
   return *this;
 }
 

Reply via email to