Add perf metrics collection, TCO estimator, and JMeter load-test wrapper#142
Open
sidd190 wants to merge 3 commits into
Open
Add perf metrics collection, TCO estimator, and JMeter load-test wrapper#142sidd190 wants to merge 3 commits into
sidd190 wants to merge 3 commits into
Conversation
Contributor
|
👋 Hi @sidd190 — thank you for your pull request. This PR is currently blocked because we do not have a Contributor License Agreement (CLA) on file for your GitHub account. To get unblocked:
|
Contributor
|
hi @sidd190 , this PR is intriguing but can you please tell me about how you tested and connected to the JVM before we go any further |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a self-contained performance/resource metrics and total cost of ownership (TCO) estimation toolkit for Mifos Gazelle, aligned with the current codebase and deployment model.
Addresses the spirit of GAZ-5: give operators and contributors a repeatable way to snapshot what the stack consumes on a real cluster and produce directional cloud cost estimates from those snapshots.
Evidence Artifacts from the cloud VM that was run on GCP, and the metrics generated!
metrics-after.json
metrics-before.json
tco-result.json
summary.txt
live-metrics.json
What was added
src/utils/perf/collect-metrics.shkubectl top podsfor Gazelle namespaces (infra,mifosx,paymenthub,vnext). Optional--storageflag sums requested PVC capacity per namespace. Writes a single JSON report. Supports--mockfor local testing without a cluster.src/utils/perf/tco-estimate.py--pricing-file), configurable--egress-gib,--topology(single-node|ha-3node), and--headroom. Supports--json-outand--all-providerscomparison.src/utils/perf/run-load-test.shperformance-testing/paymentHubEE.jmx. Runs JMeter with parameterized threads/duration/host, and invokescollect-metrics.sh --storagebefore/after when snapshots are enabled. Supports--mockdry-run.docs/PERF-TCO.mdImplementation notes
collect-metrics.shavoids usingnamespaceas anawkvariable name (reserved in gawk), ensuringkubectl topoutput parses correctly on Ubuntu 22.04+.collect-metrics.sh --storageso TCO inputs can use measured PVC requests when the cluster is reachable.Quick start
See
docs/PERF-TCO.mdfor full details. Typical flow on a machine withkubectlpointed at a Gazelle cluster:Measured inputs vs. modeled costs
Grounded in real cluster data (when run live):
kubectl top(point-in-time usage, not guaranteed limits)--storage: per-namespacestorage_gibfrom summed PVC requested sizes (not bytes used on disk)Modeled or user-supplied:
--pricing-file(indicative on-demand Linux prices;pricing_as_of/sourceare surfaced in output)hourly_rate × 730 h/month × topology multiplier(ha-3nodeuses a 3× planning multiplier)requested GiB × per-GiB/month rate × topology multiplier--egress-gib × per-GiB egress rate(defaults are conservative placeholders)Caveats and known limitations
kubectl topreflects current usage; short spikes may not be captured, and limits/requests differ from usagepaymentHubEE.jmxis unchanged in this PR. On a real Gazelle deployment, requests may fail at the HTTP layer (auth, paths, tenant config) until the plan is aligned with current PHEE ingress and APIs. The wrapper, snapshots, and JTL/HTML reporting still validate the pipeline end-to-end.Testing
collect-metrics.sh --mocke2-standard-4) with full Gazelle deploy; JSON output includesmode: "live", namespaces, andstorage_gibwhen--storageis usedtco-estimate.pyon real metrics JSON;--all-providersand--json-outexercisedrun-load-test.shend-to-end with JMeter + JDK; JMeter samples executed; HTTP failures documented as JMX/config gap, not script failurerun-load-test.sh --mockdry-run without JMeterFollow-up (separate PR)
JMeter plan maintenance: Update or supplement
performance-testing/paymentHubEE.jmx(and/or document required JMeter properties) so a default run against a standard Gazelle install achieves a meaningful success rate without manual credential configuration. Requires input from PHEE maintainers on supported public test endpoints and safe demo credentials.Related