You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by "Mortom123 (via GitHub)" <gi...@apache.org> on 2024/01/15 12:31:24 UTC
[PR] Resource specs for Init Containers [pulsar-helm-chart]
Mortom123 opened a new pull request, #428:
URL: https://github.com/apache/pulsar-helm-chart/pull/428
Implements #425
### Motivation
As described in the PR some cluster providers are a little bit more "strict" regarding their deployed containers and the resources they are allowed to use. This patch introduces resources to all init containers together with a corresponding section in `values.yaml`
### Modifications
`values.yaml` now has a new section `initContainer_resources` where each init container type is listed by name and describes the resources it is allowed to use.
I also addedd a blank `resources` section to `pulsar_metadata` because the currently existing template uses this attribute, however there was no sign of it in `values.yaml` which is unintuitive.
### Verifying this change
- [ ] Make sure that the change passes the CI checks.
(I don't know how, but lemme know how so I can run the checks)
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Resource specs for Init Containers [pulsar-helm-chart]
Posted by "lhotari (via GitHub)" <gi...@apache.org>.
lhotari commented on code in PR #428:
URL: https://github.com/apache/pulsar-helm-chart/pull/428#discussion_r1452425956
##########
charts/pulsar/values.yaml:
##########
@@ -1151,3 +1157,28 @@ job:
ttl:
enabled: false
secondsAfterFinished: 3600
+
+# This section is intended for cluster providers where all containers, including init containers,
+# need to provide the number of resources they are going to use.
+initContainer_resources:
+ zookeeper_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ cs_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ verify_cluster_id:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ broker_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ bookkeeper_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
Review Comment:
Since it's `requests` and not `limits`, it might not be that critical. I checked that the defaults for requests for memory in the chart for other containers are not adding any head room over `-Xmx`.
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Resource specs for Init Containers [pulsar-helm-chart]
Posted by "lhotari (via GitHub)" <gi...@apache.org>.
lhotari commented on code in PR #428:
URL: https://github.com/apache/pulsar-helm-chart/pull/428#discussion_r1452432663
##########
charts/pulsar/values.yaml:
##########
@@ -1151,3 +1157,28 @@ job:
ttl:
enabled: false
secondsAfterFinished: 3600
+
+# This section is intended for cluster providers where all containers, including init containers,
+# need to provide the number of resources they are going to use.
+initContainer_resources:
+ zookeeper_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ cs_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ verify_cluster_id:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ broker_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ bookkeeper_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+
Review Comment:
The linter doesn't like the blank empty line at the end of the file. Please remove 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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Resource specs for Init Containers [pulsar-helm-chart]
Posted by "Mortom123 (via GitHub)" <gi...@apache.org>.
Mortom123 commented on code in PR #428:
URL: https://github.com/apache/pulsar-helm-chart/pull/428#discussion_r1452442526
##########
charts/pulsar/values.yaml:
##########
@@ -1151,3 +1157,28 @@ job:
ttl:
enabled: false
secondsAfterFinished: 3600
+
+# This section is intended for cluster providers where all containers, including init containers,
+# need to provide the number of resources they are going to use.
+initContainer_resources:
+ zookeeper_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ cs_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ verify_cluster_id:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ broker_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ bookkeeper_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+
Review Comment:
done
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Resource specs for Init Containers [pulsar-helm-chart]
Posted by "lhotari (via GitHub)" <gi...@apache.org>.
lhotari commented on code in PR #428:
URL: https://github.com/apache/pulsar-helm-chart/pull/428#discussion_r1452480748
##########
charts/pulsar/values.yaml:
##########
@@ -1151,3 +1157,28 @@ job:
ttl:
enabled: false
secondsAfterFinished: 3600
+
+# This section is intended for cluster providers where all containers, including init containers,
+# need to provide the number of resources they are going to use.
+initContainer_resources:
+ zookeeper_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ cs_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ verify_cluster_id:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ broker_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+ bookkeeper_ready:
+ requests:
+ memory: 256Mi
+ cpu: 0.1
+
Review Comment:
It seems that it requires a new line at the end of the file (without a blank line).
```
[chart-testing lint: charts/pulsar/values.yaml#L1183](https://github.com/apache/pulsar-helm-chart/pull/428/files#annotation_16999124166)
1183:15 [new-line-at-end-of-file] no new line character at the end of 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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Resource specs for Init Containers [pulsar-helm-chart]
Posted by "lhotari (via GitHub)" <gi...@apache.org>.
lhotari merged PR #428:
URL: https://github.com/apache/pulsar-helm-chart/pull/428
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Resource specs for Init Containers [pulsar-helm-chart]
Posted by "lhotari (via GitHub)" <gi...@apache.org>.
lhotari commented on code in PR #428:
URL: https://github.com/apache/pulsar-helm-chart/pull/428#discussion_r1452419402
##########
charts/pulsar/values.yaml:
##########
@@ -1151,3 +1157,28 @@ job:
ttl:
enabled: false
secondsAfterFinished: 3600
+
+# This section is intended for cluster providers where all containers, including init containers,
+# need to provide the number of resources they are going to use.
+initContainer_resources:
+ zookeeper_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ cs_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ verify_cluster_id:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ broker_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ bookkeeper_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
Review Comment:
The default memory must be more than `128Mi` since `export PULSAR_MEM="-Xmx128M"` or `export BOOKIE_MEM="-Xmx128M"` seems to be used in many cases.
I'd suggest using `200Mi` when `-Xmx128M` is used. (Making this "guess" based on figures for -Xmx100M in https://gist.github.com/lhotari/062beedcaedcc1d87ef3591b9d7f82a9 . There are more details about Java's memory usage in https://stackoverflow.com/a/53624438)
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Resource specs for Init Containers [pulsar-helm-chart]
Posted by "Mortom123 (via GitHub)" <gi...@apache.org>.
Mortom123 commented on code in PR #428:
URL: https://github.com/apache/pulsar-helm-chart/pull/428#discussion_r1452424349
##########
charts/pulsar/values.yaml:
##########
@@ -1151,3 +1157,28 @@ job:
ttl:
enabled: false
secondsAfterFinished: 3600
+
+# This section is intended for cluster providers where all containers, including init containers,
+# need to provide the number of resources they are going to use.
+initContainer_resources:
+ zookeeper_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ cs_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ verify_cluster_id:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ broker_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
+ bookkeeper_ready:
+ requests:
+ memory: 128Mi
+ cpu: 0.1
Review Comment:
done
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org