Skip to content

Commit d0ba579

Browse files
committed
add new deployment task for property/namespace
1 parent 9feca63 commit d0ba579

File tree

3 files changed

+54
-1
lines changed

3 files changed

+54
-1
lines changed

driver-kafka/README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Apache Kafka benchmarks
2+
3+
This folder houses all of the assets necessary to run benchmarks for Apache Kafka.

driver-pulsar/README.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# Apache Pulsar benchmarks
2+
3+
This folder houses all of the assets necessary to run benchmarks for Apache Pulsar.
4+
5+
## Creating a Pulsar cluster on Amazon Web Services (AWS) using Terraform and Ansible
6+
7+
In order to create an Apache Pulsar cluster on AWS, you'll need to have the following installed:
8+
9+
* [Terraform](https://terraform.io)
10+
* [The `terraform-inventory` plugin for Terraform](https://github.com/adammck/terraform-inventory)
11+
* [Ansible](http://docs.ansible.com/ansible/latest/intro_installation.html)
12+
* The messaging benchmarks repository:
13+
14+
```bash
15+
$ git clone https://github.com/streamlio/messaging-benchmark
16+
$ cd messaging-benchmark/driver-pulsar/deploy
17+
```
18+
19+
In addition, you will need to:
20+
21+
* [Create an AWS account](https://aws.amazon.com/account/) (or use an existing account)
22+
* [Install the `aws` CLI tool](https://aws.amazon.com/cli/)
23+
* [Configure the `aws` CLI tool](http://docs.aws.amazon.com/cli/latest/userguide/cli-chap-getting-started.html)
24+
25+
Once those conditions are in place, you can create the necessary AWS resources using a single Terraform command (from this directory):
26+
27+
```bash
28+
$ terraform apply
29+
```
30+
31+
That will install the following [EC2](https://aws.amazon.com/ec2) instances (plus some other resources, such as a [Virtual Private Cloud](https://aws.amazon.com/vpc/) (VPC)):
32+
33+
Resource | Description | Count
34+
:--------|:------------|:-----
35+
Pulsar/BookKeeper instances | The VMs on which a Pulsar broker and BookKeeper bookie will run | 3
36+
ZooKeeper instances | The VMs on which a ZooKeeper node will run | 3
37+
Client instance | The VM from which the benchmarking suite itself will be run | 1
38+
39+
When you run `terraform apply`, you will be prompted to type `yes`. Type `yes` to continue with the installation or anything else to quit.
40+
41+
Once the installation is complete, you will see a confirmation message listing the resources that have been installed.

driver-pulsar/deploy/deploy.yaml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,6 @@
101101
daemon_reload: yes
102102
name: "zookeeper"
103103
- name: Initialize cluster metadata
104-
run_once: true
105104
command: >
106105
bin/pulsar initialize-cluster-metadata --cluster local
107106
--zookeeper localhost:2181
@@ -189,6 +188,16 @@
189188
dest: /opt/benchmark/bin/benchmark
190189
regexp: '^JVM_MEM='
191190
line: 'JVM_MEM="-Xms24G -Xmx24G -XX:+UseG1GC -XX:MaxGCPauseMillis=10 -XX:+ParallelRefProcEnabled -XX:+UnlockExperimentalVMOptions -XX:+AggressiveOpts -XX:+DoEscapeAnalysis -XX:ParallelGCThreads=32 -XX:ConcGCThreads=32 -XX:G1NewSizePercent=50 -XX:+DisableExplicitGC -XX:-ResizePLAB -XX:+PerfDisableSharedMem -XX:+AlwaysPreTouch -XX:-UseBiasedLocking"'
191+
- name: Pulsar property and namespace setup
192+
connection: ssh
193+
become: true
194+
command: >
195+
bin/pulsar-admin {{ item }}
196+
with_items:
197+
- properties create benchmark -r all -c local
198+
- namespaces create benchmark/local/ns
199+
args:
200+
chdir: /opt/pulsar
192201

193202
- name: Hosts addresses
194203
hosts: localhost

0 commit comments

Comments
 (0)