Chapter 2. Installation
This chapter guides you through the steps to install Red Hat build of Apache Qpid ProtonJ2 in your environment.
2.1. Prerequisites Copy linkLink copied to clipboard!
- You must have a subscription to access AMQ release files and repositories.
- To build programs with Red Hat build of Apache Qpid ProtonJ2, you must install Apache Maven.
- To use Red Hat build of Apache Qpid ProtonJ2, you must install Java.
2.2. Installing on Red Hat Enterprise Linux Copy linkLink copied to clipboard!
2.3. Using the Red Hat Maven repository Copy linkLink copied to clipboard!
Procedure
Configure your Maven environment to download the client library from the Red Hat Maven repository.
Procedure
Add the Red Hat repository to your Maven settings or POM file. For example configuration files, see Section B.1, “Using the online repository”.
<repository> <id>red-hat-ga</id> <url>https://maven.repository.redhat.com/ga</url> </repository>Add the library dependency to your POM file.
<dependency> <groupId>org.apache.qpid</groupId> <artifactId>protonj2-client</artifactId> <version>1.0.0.M23-redhat-00002</version> </dependency>
The client is now available in your Maven project.
2.4. Installing a local Maven repository Copy linkLink copied to clipboard!
As an alternative to the online repository, Red Hat build of Apache Qpid ProtonJ2 can be installed to your local filesystem as a file-based Maven repository.
Procedure
- Use your subscription to download the amq-qpid-protonj2-1.0.0.M23 Maven repository .zip file.
Extract the file contents into a directory of your choosing.
On Linux or UNIX, use the
unzipcommand to extract the file contents.$ unzip amq-qpid-protonj2-1.0.0.M23-maven-repository.zipOn Windows, right-click the .zip file and select Extract All.
-
Configure Maven to use the repository in the
maven-repositorydirectory inside the extracted install directory. For more information, see Section B.2, “Using a local repository”.
2.5. Installing the examples Copy linkLink copied to clipboard!
-
Use the
git clonecommand to clone the source repository to a local directory namedqpid-protonj2:
$ git clone https://github.com/apache/qpid-protonj2.git
Change to the qpid-protonj2 directory and use the git checkout command to checkout the commit associated with this release:
$ cd qpid-protonj2
$ git checkout 1.0.0-M23
$ cd protonj2-client-examples
The resulting local directory is referred to as <source-dir> in this guide.