Skip to content

Commit f7c3b9b

Browse files
authored
Initial commit: add CloudPilot project
1 parent 25ccd27 commit f7c3b9b

1 file changed

Lines changed: 1 addition & 13 deletions

File tree

cloudpilot/load_tester.py

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import time
33
import logging
44

5-
# Set up logging for demonstration purposes
5+
66
logging.basicConfig(level=logging.INFO)
77

88

@@ -98,15 +98,3 @@ def stress_test(kubernetes_deployment, namespace="default", duration=30):
9898
return (
9999
f"Stress test on deployment '{kubernetes_deployment}' completed successfully."
100100
)
101-
102-
103-
# Example usage for testing the module
104-
if __name__ == "__main__":
105-
# Simulate a 10-second workload with a base intensity of 5 requests/sec during peak traffic.
106-
simulate_workload(duration=10, intensity=5, pattern="peak")
107-
108-
# Simulate a stress test on a deployment named 'your-deployment' for 15 seconds.
109-
result = stress_test(
110-
kubernetes_deployment="your-deployment", namespace="default", duration=15
111-
)
112-
logging.info(result)

0 commit comments

Comments
 (0)