Skip to content

Commit 9eecf36

Browse files
kkazmierczykPiotrAniola82
authored andcommitted
Ref #163 added stack trace depth
Signed-off-by: Krzysztof Kaźmierczyk <kazm@ibm.com> Signed-off-by: Piotr Anioła <piotr.aniola@ibm.com>
1 parent 3feaa82 commit 9eecf36

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/javacore_analyser/ai/csv_dataset_generator.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,14 @@ def main(input_files):
3030
state = snapshot.state
3131
blocking_threads = len(snapshot.blocking)
3232
stack_trace = snapshot.stack_trace
33+
stack_trace_depth = snapshot.get_java_stack_depth()
3334
if stack_trace is None:
3435
stack_trace = ""
3536
else:
3637
stack_trace = stack_trace.to_string().replace("\n", " ").replace("\r", " ")
3738
data.append({'name': name, 'cpu_usage': cpu_usage, 'allocated_mem': allocated_mem, 'state': state,
38-
'blocking_threads': blocking_threads, 'stack_trace': stack_trace})
39+
'blocking_threads': blocking_threads, 'stack_trace': stack_trace,
40+
'stack_trace_depth': stack_trace_depth})
3941
data.sort(key = lambda thread : len(thread['stack_trace']), reverse=True)
4042
pd.DataFrame.from_records(data).to_csv('data.csv', index=False)
4143

0 commit comments

Comments
 (0)