Skip to content

Commit ca3681f

Browse files
committed
Add logging to cloudwatch for zookeeper logs
Still need a way to filter out the ruok requests
1 parent 5213cf5 commit ca3681f

File tree

3 files changed

+35
-0
lines changed

3 files changed

+35
-0
lines changed

README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
______ _
2+
|___ / | |
3+
/ / ___ ___ | | _____ ___ _ __ ___ _ __
4+
/ / / _ \ / _ \| |/ / _ \/ _ \ '_ \ / _ \ '__|
5+
./ /__| (_) | (_) | < __/ __/ |_) | __/ |
6+
\_____/\___/ \___/|_|\_\___|\___| .__/ \___|_|
7+
| |
8+
|_|
9+
10+
#### Introduction
11+

outputs.tf

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
output "zookeeper_asg_arns" {
2+
value = [aws_autoscaling_group.zookeeper.*.arn]
3+
}
4+
5+
output "zookeeper_internal_sg_id" {
6+
value = aws_security_group.zookeeper-internal.id
7+
}
8+
9+
output "zookeeper_external_sg_id" {
10+
value = aws_security_group.zookeeper-external.id
11+
}

scripts/cloud-init.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,19 @@ server.${node}=zk${node}.${domain}:2888:3888
107107
"metrics_collection_interval": 60,
108108
"run_as_user": "cwagent"
109109
},
110+
"logs": {
111+
"logs_collected": {
112+
"files": {
113+
"collect_list": [
114+
{
115+
"file_path": "/zookeeper/logs/zookeeper-zookeeper*",
116+
"log_group_name": "zookeeper.log",
117+
"timestamp_format": "%Y-%m-%d %H:%M:%S,%f"
118+
}
119+
]
120+
}
121+
}
122+
},
110123
"metrics": {
111124
"namespace": "${cloudwatch_namespace}",
112125
"append_dimensions": {

0 commit comments

Comments
 (0)