You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2020/12/11 12:13:33 UTC

[GitHub] [pulsar] sijia-w opened a new pull request #8919: [docs 8477] Duplicate info of using C++ in Pulsar

sijia-w opened a new pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919


   #8477 
   
   Modification:
   1. Merge two files into one.
   2. Delete the develop-cpp file.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] sijia-w commented on pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
sijia-w commented on pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#issuecomment-750058510


   @Jennifer88huang Thanks for your comments. Updated. PTAL.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] Jennifer88huang commented on pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
Jennifer88huang commented on pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#issuecomment-750672053


   @sijia-w Thanks for your contribution.
   Since you've remove one file, you need to remove it from the [sidebars.json](https://github.com/apache/pulsar/blob/master/site2/website/sidebars.json) file as well.
   You can do it in this PR or in a separate PR, either is OK. Just remember to do it.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] sijia-w commented on pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
sijia-w commented on pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#issuecomment-743741784


   @Huanli-Meng @merlimat Thanks for your comments. Updated. PTAL.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] Jennifer88huang commented on a change in pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
Jennifer88huang commented on a change in pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#discussion_r547081007



##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -104,7 +163,7 @@ mvn install -DskipTests
 pulsar-client-cpp/pkg/rpm/docker-build-rpm.sh
 ```
 
-This builds the RPM inside a Docker container and it leaves the RPMs in `pulsar-client-cpp/pkg/rpm/RPMS/x86_64/`.
+This command builds the RPM inside a Docker container and it leaves the RPMs in `pulsar-client-cpp/pkg/rpm/RPMS/x86_64/`.

Review comment:
       what does "leaves" mean in this sentence?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] Jennifer88huang commented on a change in pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
Jennifer88huang commented on a change in pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#discussion_r547079344



##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,99 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+
 ## Linux
 
+### Compilation 
+
+1. Clone the Pulsar repository.
+
+```shell
+$ git clone https://github.com/apache/pulsar
+```
+
+2. Install all necessary dependencies.
+
+```shell
+$ apt-get install cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
+  libprotobuf-dev protobuf-compiler libboost-all-dev google-mock libgtest-dev libjsoncpp-dev
+```
+
+3. Compile and install [Google Test](https://github.com/google/googletest).
+
+```shell
+# libgtest-dev version is 1.18.0 or above
+$ cd /usr/src/googletest
+$ sudo cmake .
+$ sudo make
+$ sudo cp ./googlemock/libgmock.a ./googlemock/gtest/libgtest.a /usr/lib/
+
+# less than 1.18.0
+$ cd /usr/src/gtest
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgtest.a /usr/lib
+
+$ cd /usr/src/gmock
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgmock.a /usr/lib
+```
+
+4. Compile the Pulsar client library for C++ inside the Pulsar repository.
+
+```shell
+$ cd pulsar-client-cpp
+$ cmake .
+$ make
+```
+
+With a successful installation, the files `libpulsar.so` and `libpulsar.a` will be in the `lib` folder of the repository. The tools `perfProducer` and `perfConsumer` will be in the `perf` directory.
+
+### Install Dependencies
+
 > Since 2.1.0 release, Pulsar ships pre-built RPM and Debian packages. You can download and install those packages directly.
 
-Four kind of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb download and install.
-By default, they are build under code path `${PULSAR_HOME}/pulsar-client-cpp`, using command
- `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`
-These libraries rely on some other libraries, if you want to get detailed version of dependencies libraries, please reference [these](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) [files](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile).
+The `libpulsar.so`, `libpulsarnossl.so`, `libpulsar.a`, and `libpulsarwithdeps.a` libraries are included in your `/usr/lib` after RPM or DEB being downloaded and installed.
+
+By default, they are built under code path `${PULSAR_HOME}/pulsar-client-cpp`. The building command is as below.

Review comment:
       under --> in
   in the xxx path




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] Jennifer88huang merged pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
Jennifer88huang merged pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] Huanli-Meng commented on a change in pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
Huanli-Meng commented on a change in pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#discussion_r541419352



##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,100 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [Log4CXX](https://logging.apache.org/log4cxx)
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+* [JsonCpp](https://github.com/open-source-parsers/jsoncpp)
+
 ## Linux
 
+### Compilation 

Review comment:
       I think it is better to use an ordered list to refine this part. Ans use the period (.) at the end of each sentence instead of a colon (:). Please check through the whole updates.

##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,100 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [Log4CXX](https://logging.apache.org/log4cxx)
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+* [JsonCpp](https://github.com/open-source-parsers/jsoncpp)
+
 ## Linux
 
+### Compilation 
+
+The compilation starts with cloning the Pulsar repository:
+
+```shell
+$ git clone https://github.com/apache/pulsar
+```
+
+Install all of the necessary dependencies:
+
+```shell
+$ apt-get install cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
+  libprotobuf-dev protobuf-compiler libboost-all-dev google-mock libgtest-dev libjsoncpp-dev
+```
+
+Then compile and install [Google Test](https://github.com/google/googletest):
+
+```shell
+# libgtest-dev version is 1.18.0 or above
+$ cd /usr/src/googletest
+$ sudo cmake .
+$ sudo make
+$ sudo cp ./googlemock/libgmock.a ./googlemock/gtest/libgtest.a /usr/lib/
+
+# less than 1.18.0
+$ cd /usr/src/gtest
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgtest.a /usr/lib
+
+$ cd /usr/src/gmock
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgmock.a /usr/lib
+```
+
+Finally, compile the Pulsar client library for C++ inside the Pulsar repo:
+
+```shell
+$ cd pulsar-client-cpp
+$ cmake .
+$ make
+```
+
+The resulting files, `libpulsar.so` and `libpulsar.a` will be placed in the `lib` folder of the repo. The tools `perfProducer` and `perfConsumer` will be placed in the `perf` directory.
+
+### Install Dependencies
+
 > Since 2.1.0 release, Pulsar ships pre-built RPM and Debian packages. You can download and install those packages directly.
 
-Four kind of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb download and install.
-By default, they are build under code path `${PULSAR_HOME}/pulsar-client-cpp`, using command
- `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`
-These libraries rely on some other libraries, if you want to get detailed version of dependencies libraries, please reference [these](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) [files](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile).
+Four kinds of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb being downloaded and installed.

Review comment:
       ```suggestion
   The `libpulsar.so`, `libpulsarnossl.so`, `libpulsar.a`, and `libpulsarwithdeps.a` libraries are included in your `/usr/lib` after RPM or DEB being downloaded and installed.
   ```

##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,100 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [Log4CXX](https://logging.apache.org/log4cxx)
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+* [JsonCpp](https://github.com/open-source-parsers/jsoncpp)
+
 ## Linux
 
+### Compilation 
+
+The compilation starts with cloning the Pulsar repository:
+
+```shell
+$ git clone https://github.com/apache/pulsar
+```
+
+Install all of the necessary dependencies:
+
+```shell
+$ apt-get install cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
+  libprotobuf-dev protobuf-compiler libboost-all-dev google-mock libgtest-dev libjsoncpp-dev
+```
+
+Then compile and install [Google Test](https://github.com/google/googletest):
+
+```shell
+# libgtest-dev version is 1.18.0 or above
+$ cd /usr/src/googletest
+$ sudo cmake .
+$ sudo make
+$ sudo cp ./googlemock/libgmock.a ./googlemock/gtest/libgtest.a /usr/lib/
+
+# less than 1.18.0
+$ cd /usr/src/gtest
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgtest.a /usr/lib
+
+$ cd /usr/src/gmock
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgmock.a /usr/lib
+```
+
+Finally, compile the Pulsar client library for C++ inside the Pulsar repo:
+
+```shell
+$ cd pulsar-client-cpp
+$ cmake .
+$ make
+```
+
+The resulting files, `libpulsar.so` and `libpulsar.a` will be placed in the `lib` folder of the repo. The tools `perfProducer` and `perfConsumer` will be placed in the `perf` directory.
+
+### Install Dependencies
+
 > Since 2.1.0 release, Pulsar ships pre-built RPM and Debian packages. You can download and install those packages directly.
 
-Four kind of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb download and install.
-By default, they are build under code path `${PULSAR_HOME}/pulsar-client-cpp`, using command
- `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`
-These libraries rely on some other libraries, if you want to get detailed version of dependencies libraries, please reference [these](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) [files](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile).
+Four kinds of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb being downloaded and installed.
+
+By default, they are built under code path `${PULSAR_HOME}/pulsar-client-cpp`. You can use this command:
+ `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`.
+These libraries rely on some other libraries, if you want to get detailed version of dependencies, please reference [rpm](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) or [deb](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile) files.
+
+1. `libpulsar.so` is a shared library, which contains statically linked `boost` and `openssl`. It also dynamically links all other needed libraries. Below is the command to use this Pulsar library:
 
-1. `libpulsar.so` is the Shared library, it contains statically linked `boost` and `openssl`, and will also dynamically link all other needed libraries.
-The command the when use this pulsar library is like this:
 ```bash
  g++ --std=c++11  PulsarTest.cpp -o test /usr/lib/libpulsar.so -I/usr/local/ssl/include
 ```
 
-2. `libpulsarnossl.so` is the Shared library that similar to `libpulsar.so` except that the library `openssl` and `crypto` are dynamically linked.
-The command the when use this pulsar library is like this:
+2. `libpulsarnossl.so` is a shared library that similar to `libpulsar.so` except that the libraries `openssl` and `crypto` are dynamically linked. Below is the command to use this Pulsar library:
+
 ```bash
  g++ --std=c++11  PulsarTest.cpp -o test /usr/lib/libpulsarnossl.so -lssl -lcrypto -I/usr/local/ssl/include -L/usr/local/ssl/lib
 ```
 
-3. `libpulsar.a` is the Static library, it need to load some dependencies library when using it. 
-The command the when use this pulsar library is like this:
+3. `libpulsar.a` is the static library. You need load dependencies before using this library. Below is the command to use this Pulsar library:

Review comment:
       ```suggestion
   3. `libpulsar.a` is a static library. You need load dependencies before using this library. Below is the command to use this Pulsar library:
   ```

##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,100 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [Log4CXX](https://logging.apache.org/log4cxx)
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+* [JsonCpp](https://github.com/open-source-parsers/jsoncpp)
+
 ## Linux
 
+### Compilation 
+
+The compilation starts with cloning the Pulsar repository:
+
+```shell
+$ git clone https://github.com/apache/pulsar
+```
+
+Install all of the necessary dependencies:
+
+```shell
+$ apt-get install cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
+  libprotobuf-dev protobuf-compiler libboost-all-dev google-mock libgtest-dev libjsoncpp-dev
+```
+
+Then compile and install [Google Test](https://github.com/google/googletest):
+
+```shell
+# libgtest-dev version is 1.18.0 or above
+$ cd /usr/src/googletest
+$ sudo cmake .
+$ sudo make
+$ sudo cp ./googlemock/libgmock.a ./googlemock/gtest/libgtest.a /usr/lib/
+
+# less than 1.18.0
+$ cd /usr/src/gtest
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgtest.a /usr/lib
+
+$ cd /usr/src/gmock
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgmock.a /usr/lib
+```
+
+Finally, compile the Pulsar client library for C++ inside the Pulsar repo:
+
+```shell
+$ cd pulsar-client-cpp
+$ cmake .
+$ make
+```
+
+The resulting files, `libpulsar.so` and `libpulsar.a` will be placed in the `lib` folder of the repo. The tools `perfProducer` and `perfConsumer` will be placed in the `perf` directory.

Review comment:
       ```suggestion
   The resulting files, `libpulsar.so` and `libpulsar.a` will be placed in the `lib` folder of the repository. The tools `perfProducer` and `perfConsumer` will be placed in the `perf` directory.
   ```

##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,100 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [Log4CXX](https://logging.apache.org/log4cxx)
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+* [JsonCpp](https://github.com/open-source-parsers/jsoncpp)
+
 ## Linux
 
+### Compilation 
+
+The compilation starts with cloning the Pulsar repository:
+
+```shell
+$ git clone https://github.com/apache/pulsar
+```
+
+Install all of the necessary dependencies:
+
+```shell
+$ apt-get install cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
+  libprotobuf-dev protobuf-compiler libboost-all-dev google-mock libgtest-dev libjsoncpp-dev
+```
+
+Then compile and install [Google Test](https://github.com/google/googletest):
+
+```shell
+# libgtest-dev version is 1.18.0 or above
+$ cd /usr/src/googletest
+$ sudo cmake .
+$ sudo make
+$ sudo cp ./googlemock/libgmock.a ./googlemock/gtest/libgtest.a /usr/lib/
+
+# less than 1.18.0
+$ cd /usr/src/gtest
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgtest.a /usr/lib
+
+$ cd /usr/src/gmock
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgmock.a /usr/lib
+```
+
+Finally, compile the Pulsar client library for C++ inside the Pulsar repo:
+
+```shell
+$ cd pulsar-client-cpp
+$ cmake .
+$ make
+```
+
+The resulting files, `libpulsar.so` and `libpulsar.a` will be placed in the `lib` folder of the repo. The tools `perfProducer` and `perfConsumer` will be placed in the `perf` directory.
+
+### Install Dependencies
+
 > Since 2.1.0 release, Pulsar ships pre-built RPM and Debian packages. You can download and install those packages directly.
 
-Four kind of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb download and install.
-By default, they are build under code path `${PULSAR_HOME}/pulsar-client-cpp`, using command
- `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`
-These libraries rely on some other libraries, if you want to get detailed version of dependencies libraries, please reference [these](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) [files](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile).
+Four kinds of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb being downloaded and installed.
+
+By default, they are built under code path `${PULSAR_HOME}/pulsar-client-cpp`. You can use this command:
+ `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`.
+These libraries rely on some other libraries, if you want to get detailed version of dependencies, please reference [rpm](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) or [deb](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile) files.

Review comment:
       ```suggestion
   These libraries rely on some other libraries, if you want to get detailed version of dependencies, see [RPM](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) or [DEB](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile) files.
   ```

##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,100 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [Log4CXX](https://logging.apache.org/log4cxx)
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+* [JsonCpp](https://github.com/open-source-parsers/jsoncpp)
+
 ## Linux
 
+### Compilation 
+
+The compilation starts with cloning the Pulsar repository:
+
+```shell
+$ git clone https://github.com/apache/pulsar
+```
+
+Install all of the necessary dependencies:
+
+```shell
+$ apt-get install cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
+  libprotobuf-dev protobuf-compiler libboost-all-dev google-mock libgtest-dev libjsoncpp-dev
+```
+
+Then compile and install [Google Test](https://github.com/google/googletest):
+
+```shell
+# libgtest-dev version is 1.18.0 or above
+$ cd /usr/src/googletest
+$ sudo cmake .
+$ sudo make
+$ sudo cp ./googlemock/libgmock.a ./googlemock/gtest/libgtest.a /usr/lib/
+
+# less than 1.18.0
+$ cd /usr/src/gtest
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgtest.a /usr/lib
+
+$ cd /usr/src/gmock
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgmock.a /usr/lib
+```
+
+Finally, compile the Pulsar client library for C++ inside the Pulsar repo:
+
+```shell
+$ cd pulsar-client-cpp
+$ cmake .
+$ make
+```
+
+The resulting files, `libpulsar.so` and `libpulsar.a` will be placed in the `lib` folder of the repo. The tools `perfProducer` and `perfConsumer` will be placed in the `perf` directory.
+
+### Install Dependencies
+
 > Since 2.1.0 release, Pulsar ships pre-built RPM and Debian packages. You can download and install those packages directly.
 
-Four kind of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb download and install.
-By default, they are build under code path `${PULSAR_HOME}/pulsar-client-cpp`, using command
- `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`
-These libraries rely on some other libraries, if you want to get detailed version of dependencies libraries, please reference [these](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) [files](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile).
+Four kinds of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb being downloaded and installed.
+
+By default, they are built under code path `${PULSAR_HOME}/pulsar-client-cpp`. You can use this command:
+ `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`.
+These libraries rely on some other libraries, if you want to get detailed version of dependencies, please reference [rpm](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) or [deb](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile) files.
+
+1. `libpulsar.so` is a shared library, which contains statically linked `boost` and `openssl`. It also dynamically links all other needed libraries. Below is the command to use this Pulsar library:
 
-1. `libpulsar.so` is the Shared library, it contains statically linked `boost` and `openssl`, and will also dynamically link all other needed libraries.
-The command the when use this pulsar library is like this:
 ```bash
  g++ --std=c++11  PulsarTest.cpp -o test /usr/lib/libpulsar.so -I/usr/local/ssl/include
 ```
 
-2. `libpulsarnossl.so` is the Shared library that similar to `libpulsar.so` except that the library `openssl` and `crypto` are dynamically linked.
-The command the when use this pulsar library is like this:
+2. `libpulsarnossl.so` is a shared library that similar to `libpulsar.so` except that the libraries `openssl` and `crypto` are dynamically linked. Below is the command to use this Pulsar library:
+
 ```bash
  g++ --std=c++11  PulsarTest.cpp -o test /usr/lib/libpulsarnossl.so -lssl -lcrypto -I/usr/local/ssl/include -L/usr/local/ssl/lib
 ```
 
-3. `libpulsar.a` is the Static library, it need to load some dependencies library when using it. 
-The command the when use this pulsar library is like this:
+3. `libpulsar.a` is the static library. You need load dependencies before using this library. Below is the command to use this Pulsar library:
+
 ```bash
  g++ --std=c++11  PulsarTest.cpp -o test /usr/lib/libpulsar.a -lssl -lcrypto -ldl -lpthread  -I/usr/local/ssl/include -L/usr/local/ssl/lib -lboost_system -lboost_regex -lcurl -lprotobuf -lzstd -lz
 ```
 
-4. `libpulsarwithdeps.a` is the Static library, base on `libpulsar.a`, and archived in the dependencies libraries of `libboost_regex`,  `libboost_system`, `libcurl`, `libprotobuf`, `libzstd` and `libz`, 
-The command the when use this pulsar library is like this:
+4. `libpulsarwithdeps.a` is a static library, based on `libpulsar.a`. It is archived in the dependencies of `libboost_regex`, `libboost_system`, `libcurl`, `libprotobuf`, `libzstd` and `libz`. Below is the command to use this Pulsar library:
+
 ```bash
  g++ --std=c++11  PulsarTest.cpp -o test /usr/lib/libpulsarwithdeps.a -lssl -lcrypto -ldl -lpthread  -I/usr/local/ssl/include -L/usr/local/ssl/lib
 ```
-`libpulsarwithdeps.a` does not include library openssl related libraries: `libssl` and `libcrypto`, because these 2 library is related to security, 
-by using user local system provided version is more reasonable, and more easy for user to handling security issue and library upgrade.
+`libpulsarwithdeps.a` does not include library openssl related libraries `libssl` and `libcrypto`, because these 2 libraries are related to security. It is more reasonable and easier to use the versions provided by the local system to handle security issues and upgrade libraries.

Review comment:
       ```suggestion
   `libpulsarwithdeps.a` does not include library `openssl` related libraries `libssl` and `libcrypto`, because these two libraries are related to security. It is more reasonable and easier to use the versions provided by the local system to handle security issues and upgrade libraries.
   ```

##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,100 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [Log4CXX](https://logging.apache.org/log4cxx)
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+* [JsonCpp](https://github.com/open-source-parsers/jsoncpp)
+
 ## Linux
 
+### Compilation 
+
+The compilation starts with cloning the Pulsar repository:
+
+```shell
+$ git clone https://github.com/apache/pulsar
+```
+
+Install all of the necessary dependencies:
+
+```shell
+$ apt-get install cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
+  libprotobuf-dev protobuf-compiler libboost-all-dev google-mock libgtest-dev libjsoncpp-dev
+```
+
+Then compile and install [Google Test](https://github.com/google/googletest):
+
+```shell
+# libgtest-dev version is 1.18.0 or above
+$ cd /usr/src/googletest
+$ sudo cmake .
+$ sudo make
+$ sudo cp ./googlemock/libgmock.a ./googlemock/gtest/libgtest.a /usr/lib/
+
+# less than 1.18.0
+$ cd /usr/src/gtest
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgtest.a /usr/lib
+
+$ cd /usr/src/gmock
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgmock.a /usr/lib
+```
+
+Finally, compile the Pulsar client library for C++ inside the Pulsar repo:
+
+```shell
+$ cd pulsar-client-cpp
+$ cmake .
+$ make
+```
+
+The resulting files, `libpulsar.so` and `libpulsar.a` will be placed in the `lib` folder of the repo. The tools `perfProducer` and `perfConsumer` will be placed in the `perf` directory.
+
+### Install Dependencies
+
 > Since 2.1.0 release, Pulsar ships pre-built RPM and Debian packages. You can download and install those packages directly.
 
-Four kind of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb download and install.
-By default, they are build under code path `${PULSAR_HOME}/pulsar-client-cpp`, using command
- `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`
-These libraries rely on some other libraries, if you want to get detailed version of dependencies libraries, please reference [these](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) [files](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile).
+Four kinds of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb being downloaded and installed.
+
+By default, they are built under code path `${PULSAR_HOME}/pulsar-client-cpp`. You can use this command:

Review comment:
       how is this command is used for? used for build libraries under the default code path or use this command to build these libraries under a different code path? It is better ti explain more detailed.

##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,100 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [Log4CXX](https://logging.apache.org/log4cxx)
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+* [JsonCpp](https://github.com/open-source-parsers/jsoncpp)
+
 ## Linux
 
+### Compilation 
+
+The compilation starts with cloning the Pulsar repository:
+
+```shell
+$ git clone https://github.com/apache/pulsar
+```
+
+Install all of the necessary dependencies:
+
+```shell
+$ apt-get install cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
+  libprotobuf-dev protobuf-compiler libboost-all-dev google-mock libgtest-dev libjsoncpp-dev
+```
+
+Then compile and install [Google Test](https://github.com/google/googletest):
+
+```shell
+# libgtest-dev version is 1.18.0 or above
+$ cd /usr/src/googletest
+$ sudo cmake .
+$ sudo make
+$ sudo cp ./googlemock/libgmock.a ./googlemock/gtest/libgtest.a /usr/lib/
+
+# less than 1.18.0
+$ cd /usr/src/gtest
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgtest.a /usr/lib
+
+$ cd /usr/src/gmock
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgmock.a /usr/lib
+```
+
+Finally, compile the Pulsar client library for C++ inside the Pulsar repo:
+
+```shell
+$ cd pulsar-client-cpp
+$ cmake .
+$ make
+```
+
+The resulting files, `libpulsar.so` and `libpulsar.a` will be placed in the `lib` folder of the repo. The tools `perfProducer` and `perfConsumer` will be placed in the `perf` directory.
+
+### Install Dependencies
+
 > Since 2.1.0 release, Pulsar ships pre-built RPM and Debian packages. You can download and install those packages directly.
 
-Four kind of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb download and install.
-By default, they are build under code path `${PULSAR_HOME}/pulsar-client-cpp`, using command
- `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`
-These libraries rely on some other libraries, if you want to get detailed version of dependencies libraries, please reference [these](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) [files](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile).
+Four kinds of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb being downloaded and installed.
+
+By default, they are built under code path `${PULSAR_HOME}/pulsar-client-cpp`. You can use this command:
+ `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`.
+These libraries rely on some other libraries, if you want to get detailed version of dependencies, please reference [rpm](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) or [deb](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile) files.
+
+1. `libpulsar.so` is a shared library, which contains statically linked `boost` and `openssl`. It also dynamically links all other needed libraries. Below is the command to use this Pulsar library:
 
-1. `libpulsar.so` is the Shared library, it contains statically linked `boost` and `openssl`, and will also dynamically link all other needed libraries.
-The command the when use this pulsar library is like this:
 ```bash
  g++ --std=c++11  PulsarTest.cpp -o test /usr/lib/libpulsar.so -I/usr/local/ssl/include
 ```
 
-2. `libpulsarnossl.so` is the Shared library that similar to `libpulsar.so` except that the library `openssl` and `crypto` are dynamically linked.
-The command the when use this pulsar library is like this:
+2. `libpulsarnossl.so` is a shared library that similar to `libpulsar.so` except that the libraries `openssl` and `crypto` are dynamically linked. Below is the command to use this Pulsar library:

Review comment:
       ```suggestion
   2. `libpulsarnossl.so` is a shared library that is similar to `libpulsar.so` except that the libraries `openssl` and `crypto` are dynamically linked. Below is the command to use this Pulsar library:
   ```

##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -129,6 +189,45 @@ Debian packages are created at `pulsar-client-cpp/pkg/deb/BUILD/DEB/`.
 
 ## MacOS
 
+### Compilation
+
+The compilation starts with cloning the Pulsar repository:

Review comment:
       use an ordered list and use a period(.) instead of a colon (:) at the end of each sentence.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] Jennifer88huang commented on a change in pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
Jennifer88huang commented on a change in pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#discussion_r547080042



##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,99 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+
 ## Linux
 
+### Compilation 
+
+1. Clone the Pulsar repository.
+
+```shell
+$ git clone https://github.com/apache/pulsar
+```
+
+2. Install all necessary dependencies.
+
+```shell
+$ apt-get install cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
+  libprotobuf-dev protobuf-compiler libboost-all-dev google-mock libgtest-dev libjsoncpp-dev
+```
+
+3. Compile and install [Google Test](https://github.com/google/googletest).
+
+```shell
+# libgtest-dev version is 1.18.0 or above
+$ cd /usr/src/googletest
+$ sudo cmake .
+$ sudo make
+$ sudo cp ./googlemock/libgmock.a ./googlemock/gtest/libgtest.a /usr/lib/
+
+# less than 1.18.0
+$ cd /usr/src/gtest
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgtest.a /usr/lib
+
+$ cd /usr/src/gmock
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgmock.a /usr/lib
+```
+
+4. Compile the Pulsar client library for C++ inside the Pulsar repository.
+
+```shell
+$ cd pulsar-client-cpp
+$ cmake .
+$ make
+```
+
+With a successful installation, the files `libpulsar.so` and `libpulsar.a` will be in the `lib` folder of the repository. The tools `perfProducer` and `perfConsumer` will be in the `perf` directory.
+
+### Install Dependencies
+
 > Since 2.1.0 release, Pulsar ships pre-built RPM and Debian packages. You can download and install those packages directly.
 
-Four kind of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb download and install.
-By default, they are build under code path `${PULSAR_HOME}/pulsar-client-cpp`, using command
- `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`
-These libraries rely on some other libraries, if you want to get detailed version of dependencies libraries, please reference [these](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) [files](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile).
+The `libpulsar.so`, `libpulsarnossl.so`, `libpulsar.a`, and `libpulsarwithdeps.a` libraries are included in your `/usr/lib` after RPM or DEB being downloaded and installed.
+
+By default, they are built under code path `${PULSAR_HOME}/pulsar-client-cpp`. The building command is as below.
+ `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`.
+
+These libraries rely on some other libraries, if you want to get detailed version of dependencies, see [RPM](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) or [DEB](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile) files.
+
+1. `libpulsar.so` is a shared library, which contains statically linked `boost` and `openssl`. It also dynamically links all other needed libraries. Below is the command to use this Pulsar library.
 
-1. `libpulsar.so` is the Shared library, it contains statically linked `boost` and `openssl`, and will also dynamically link all other needed libraries.
-The command the when use this pulsar library is like this:
 ```bash
  g++ --std=c++11  PulsarTest.cpp -o test /usr/lib/libpulsar.so -I/usr/local/ssl/include
 ```
 
-2. `libpulsarnossl.so` is the Shared library that similar to `libpulsar.so` except that the library `openssl` and `crypto` are dynamically linked.
-The command the when use this pulsar library is like this:
+2. `libpulsarnossl.so` is a shared library, similar to `libpulsar.so` except that the libraries `openssl` and `crypto` are dynamically linked. Below is the command to use this Pulsar library.

Review comment:
       Below is the command to use this Pulsar library -->
   You can use this Pulsar library with the command below.
   
   If it's an action that should be done by users, use the second person, see https://developers.google.com/style/person




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] sijia-w commented on pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
sijia-w commented on pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#issuecomment-750830327


   @Jennifer88huang I found no file is referring the deleted file, and the sidebar is updated. Thank you.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] Jennifer88huang commented on a change in pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
Jennifer88huang commented on a change in pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#discussion_r547078755



##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,99 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+
 ## Linux
 
+### Compilation 
+
+1. Clone the Pulsar repository.
+
+```shell
+$ git clone https://github.com/apache/pulsar
+```
+
+2. Install all necessary dependencies.
+
+```shell
+$ apt-get install cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
+  libprotobuf-dev protobuf-compiler libboost-all-dev google-mock libgtest-dev libjsoncpp-dev
+```
+
+3. Compile and install [Google Test](https://github.com/google/googletest).
+
+```shell
+# libgtest-dev version is 1.18.0 or above
+$ cd /usr/src/googletest
+$ sudo cmake .
+$ sudo make
+$ sudo cp ./googlemock/libgmock.a ./googlemock/gtest/libgtest.a /usr/lib/
+
+# less than 1.18.0
+$ cd /usr/src/gtest
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgtest.a /usr/lib
+
+$ cd /usr/src/gmock
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgmock.a /usr/lib
+```
+
+4. Compile the Pulsar client library for C++ inside the Pulsar repository.
+
+```shell
+$ cd pulsar-client-cpp
+$ cmake .
+$ make
+```
+
+With a successful installation, the files `libpulsar.so` and `libpulsar.a` will be in the `lib` folder of the repository. The tools `perfProducer` and `perfConsumer` will be in the `perf` directory.

Review comment:
       Use present tense, see https://developers.google.com/style/tense




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] Jennifer88huang commented on a change in pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
Jennifer88huang commented on a change in pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#discussion_r547079235



##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,99 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+
 ## Linux
 
+### Compilation 
+
+1. Clone the Pulsar repository.
+
+```shell
+$ git clone https://github.com/apache/pulsar
+```
+
+2. Install all necessary dependencies.
+
+```shell
+$ apt-get install cmake libssl-dev libcurl4-openssl-dev liblog4cxx-dev \
+  libprotobuf-dev protobuf-compiler libboost-all-dev google-mock libgtest-dev libjsoncpp-dev
+```
+
+3. Compile and install [Google Test](https://github.com/google/googletest).
+
+```shell
+# libgtest-dev version is 1.18.0 or above
+$ cd /usr/src/googletest
+$ sudo cmake .
+$ sudo make
+$ sudo cp ./googlemock/libgmock.a ./googlemock/gtest/libgtest.a /usr/lib/
+
+# less than 1.18.0
+$ cd /usr/src/gtest
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgtest.a /usr/lib
+
+$ cd /usr/src/gmock
+$ sudo cmake .
+$ sudo make
+$ sudo cp libgmock.a /usr/lib
+```
+
+4. Compile the Pulsar client library for C++ inside the Pulsar repository.
+
+```shell
+$ cd pulsar-client-cpp
+$ cmake .
+$ make
+```
+
+With a successful installation, the files `libpulsar.so` and `libpulsar.a` will be in the `lib` folder of the repository. The tools `perfProducer` and `perfConsumer` will be in the `perf` directory.
+
+### Install Dependencies
+
 > Since 2.1.0 release, Pulsar ships pre-built RPM and Debian packages. You can download and install those packages directly.
 
-Four kind of libraries `libpulsar.so` / `libpulsarnossl.so` / `libpulsar.a` / `libpulsarwithdeps.a` are included in your `/usr/lib` after rpm/deb download and install.
-By default, they are build under code path `${PULSAR_HOME}/pulsar-client-cpp`, using command
- `cmake . -DBUILD_TESTS=OFF -DLINK_STATIC=ON && make pulsarShared pulsarSharedNossl pulsarStatic pulsarStaticWithDeps -j 3`
-These libraries rely on some other libraries, if you want to get detailed version of dependencies libraries, please reference [these](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/rpm/Dockerfile) [files](https://github.com/apache/pulsar/blob/master/pulsar-client-cpp/pkg/deb/Dockerfile).
+The `libpulsar.so`, `libpulsarnossl.so`, `libpulsar.a`, and `libpulsarwithdeps.a` libraries are included in your `/usr/lib` after RPM or DEB being downloaded and installed.

Review comment:
       Try to use active voice, see https://developers.google.com/style/voice
   You can refine it as sth like:
   "The xxx are included in your `/usr/lib` after you download and install xxx"




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] Jennifer88huang commented on a change in pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
Jennifer88huang commented on a change in pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#discussion_r547078422



##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,99 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:

Review comment:
       You need to install the following components before using the C++ client:




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] merlimat commented on a change in pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
merlimat commented on a change in pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#discussion_r541429283



##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,100 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [Log4CXX](https://logging.apache.org/log4cxx)
+* [libcurl](https://curl.haxx.se/libcurl/)
+* [Google Test](https://github.com/google/googletest)
+* [JsonCpp](https://github.com/open-source-parsers/jsoncpp)

Review comment:
       JsonCpp too is no longer required

##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -14,40 +14,100 @@ Pulsar C++ client is supported on **Linux** and **MacOS** platforms.
 
 [Doxygen](http://www.doxygen.nl/)-generated API docs for the C++ client are available [here](/api/cpp).
 
+## System requirements
+
+You need to have the following installed to use the C++ client:
+
+* [CMake](https://cmake.org/)
+* [Boost](http://www.boost.org/)
+* [Protocol Buffers](https://developers.google.com/protocol-buffers/) 2.6
+* [Log4CXX](https://logging.apache.org/log4cxx)

Review comment:
       Log4CXX is no longer required




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] Jennifer88huang commented on a change in pull request #8919: [ISSUE 8477][docs] Duplicate info of using C++ in Pulsar

Posted by GitBox <gi...@apache.org>.
Jennifer88huang commented on a change in pull request #8919:
URL: https://github.com/apache/pulsar/pull/8919#discussion_r547080679



##########
File path: site2/docs/client-libraries-cpp.md
##########
@@ -65,7 +124,7 @@ by using user local system provided version is more reasonable, and more easy fo
 $ rpm -ivh apache-pulsar-client*.rpm
 ```
 
-After install, Pulsar libraries will be placed under `/usr/lib`.
+With a successful installation, you will see Pulsar libraries under `/usr/lib`.

Review comment:
       After you install RPM successfully, Pulsar libraries are in the `/usr/lib` path.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org