GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - poorbarcode/pulsar-client-cpp at a91e12a527325194e575e188c22627d8a310000e

BranchesTags
Open more actions menu

Latest commit

 

History

263 Commits
263 Commits

Folders and files

NameName
Last commit message
Last commit date
build-support
build-support
 
 
cmake_modules
cmake_modules
 
 
docker
docker
 
 
docs
docs
 
 
examples
examples
 
 
homebrew
homebrew
 
 
include/pulsar
include/pulsar
 
 
lib
lib
 
 
perf
perf
 
 
pkg
pkg
 
 
python
python
 
 
test-conf
test-conf
 
 
tests
tests
 
 
wireshark
wireshark
 
 
.clang-format
.clang-format
 
 
.gitignore
.gitignore
 
 
CMakeLists.txt
CMakeLists.txt
 
 
Doxyfile
Doxyfile
 
 
README.md
README.md
 
 
docker-build.sh
docker-build.sh
 
 
docker-format.sh
docker-format.sh
 
 
docker-tests.sh
docker-tests.sh
 
 
eclipse-formatter.xml
eclipse-formatter.xml
 
 
log4cxx.conf
log4cxx.conf
 
 
pulsar-test-service-start.sh
pulsar-test-service-start.sh
 
 
pulsar-test-service-stop.sh
pulsar-test-service-stop.sh
 
 
run-unit-tests.sh
run-unit-tests.sh
 
 
travis-build.sh
travis-build.sh
 
 

Repository files navigation

Pulsar C++ client library

  • Requirements
  • Platforms
  • Compilation
    • Compile on Ubuntu Server 16.04
    • Compile on Mac OS X
  • Tests
  • Requirements for Contributors

Examples for using the API to publish and consume messages can be found on https://github.com/apache/pulsar/tree/master/pulsar-client-cpp/examples

Requirements

  • CMake
  • Boost
  • Protocol Buffer 2.6
  • Log4CXX
  • LibCurl
  • GTest
  • JsonCpp

Platforms

Pulsar C++ Client Library has been tested on:

  • Linux
  • Mac OS X

Compilation

Compile within a Docker container

You can compile the C++ client library within a Docker container that already contains all the required dependencies.

./docker-build.sh

Run unit tests:

./docker-tests.sh

Compile on Ubuntu Server 16.04

Install all dependencies:

apt-get install -y g++ cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
                libprotobuf-dev libboost-all-dev  libgtest-dev google-mock \
                libjsoncpp-dev libxml2-utils protobuf-compiler python-setuptools

Compile and install Google Test:

cd /usr/src/gtest
sudo cmake .
sudo make
sudo cp *.a /usr/lib

Compile and install Google Mock:

cd /usr/src/gmock
sudo cmake .
sudo make
sudo cp *.a /usr/lib

Compile Pulsar client library:

cd pulsar/pulsar-client-cpp
cmake .
make

Checks

Client library will be placed in
lib/libpulsar.so
lib/libpulsar.a
Tools will be placed in
perf/perfProducer
perf/perfConsumer

Compile on Mac OS X

Install all dependencies:

# For openSSL
brew install openssl
export OPENSSL_INCLUDE_DIR=/usr/local/opt/openssl/include/
export OPENSSL_ROOT_DIR=/usr/local/opt/openssl/

# For Protobuf
brew tap homebrew/versions
brew install protobuf260 boost boost-python log4cxx jsoncpp

# For gtest
cd $HOME
git clone https://github.com/google/googletest.git
cd googletest
cmake .
make install
# Refer gtest documentation in case you get stuck somewhere

Compile Pulsar client library:

export PULSAR_PATH=<Path where you cloned pulsar repo>
cd ${PULSAR_PATH}/pulsar-client-cpp/
cmake .
make

Checks

Client library will be placed in
${PULSAR_PATH}/pulsar-client-cpp/lib/libpulsar.dylib
${PULSAR_PATH}/pulsar-client-cpp/lib/libpulsar.a
Tools will be placed in:
${PULSAR_PATH}/pulsar-client-cpp/perf/perfProducer
${PULSAR_PATH}/pulsar-client-cpp/perf/perfConsumer

Tests

# Source code
${PULSAR_PATH}/pulsar-client-cpp/tests/

# Execution
# Start standalone broker
export PULSAR_STANDALONE_CONF=${PULSAR_PATH}/pulsar-client-cpp/tests/standalone.conf
${PULSAR_PATH}/bin/pulsar standalone

# Run the tests
${PULSAR_PATH}/pulsar-client-cpp/tests/main

Requirements for Contributors

We welcome contributions from the open source community, kindly make sure your changes are backward compatible with gcc-4.4.7 and Boost 1.41.

About

Apache Pulsar C++ client library

pulsar.apache.org/

Resources

Readme
Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.