File tree Expand file tree Collapse file tree
chaosk8s/chaosmesh/stress Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -111,7 +111,7 @@ def stress_memory(
111111 secrets : Secrets = None ,
112112) -> Dict [str , Any ]:
113113 """
114- Stress the CPU to impact a process/container.
114+ Stress the memory to impact a process/container.
115115
116116 See: https://chaos-mesh.org/docs/simulate-heavy-stress-on-kubernetes/
117117 """
@@ -125,7 +125,7 @@ def stress_memory(
125125 spec:
126126 selector: {}
127127 stressors:
128- cpu : {}
128+ memory : {}
129129 """
130130 )
131131 )
@@ -134,9 +134,9 @@ def stress_memory(
134134 r ["metadata" ]["ns" ] = ns
135135
136136 s = r ["spec" ]
137- c = s ["stressors" ]["cpu " ]
137+ c = s ["stressors" ]["memory " ]
138138 c ["workers" ] = workers
139- c ["load " ] = size
139+ c ["size " ] = size
140140 c ["time" ] = time_to_get_to_size
141141 c ["oomScoreAdj" ] = oom_score
142142
You can’t perform that action at this time.
0 commit comments