javacore-analyser 2.0rc1__py3-none-any.whl → 2.1.0.dev66__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- javacore_analyser/abstract_snapshot_collection.py +2 -2
- javacore_analyser/constants.py +2 -1
- javacore_analyser/data/expand.js +2 -0
- javacore_analyser/data/html/processing_data.html +17 -0
- javacore_analyser/data/jquery/search.js +22 -0
- javacore_analyser/data/jquery/wait2scripts.js +27 -5
- javacore_analyser/data/xml/javacores/javacore.xsl +126 -117
- javacore_analyser/data/xml/report.xsl +1 -1
- javacore_analyser/data/xml/threads/thread.xsl +162 -153
- javacore_analyser/javacore.py +5 -3
- javacore_analyser/javacore_analyser_batch.py +34 -14
- javacore_analyser/javacore_analyser_web.py +58 -26
- javacore_analyser/javacore_set.py +78 -43
- javacore_analyser/snapshot_collection_collection.py +5 -3
- javacore_analyser/stack_trace.py +2 -2
- javacore_analyser/stack_trace_element.py +1 -1
- javacore_analyser/templates/index.html +9 -4
- javacore_analyser/thread_snapshot.py +3 -2
- javacore_analyser/tips.py +5 -3
- javacore_analyser/verbose_gc.py +4 -1
- {javacore_analyser-2.0rc1.dist-info → javacore_analyser-2.1.0.dev66.dist-info}/METADATA +25 -15
- javacore_analyser-2.1.0.dev66.dist-info/RECORD +45 -0
- {javacore_analyser-2.0rc1.dist-info → javacore_analyser-2.1.0.dev66.dist-info}/WHEEL +1 -1
- javacore_analyser-2.0rc1.dist-info/RECORD +0 -44
- {javacore_analyser-2.0rc1.dist-info → javacore_analyser-2.1.0.dev66.dist-info}/entry_points.txt +0 -0
- {javacore_analyser-2.0rc1.dist-info → javacore_analyser-2.1.0.dev66.dist-info}/licenses/LICENSE +0 -0
@@ -17,6 +17,7 @@ from xml.dom.minidom import parseString
|
|
17
17
|
import importlib_resources
|
18
18
|
from lxml import etree
|
19
19
|
from lxml.etree import XMLSyntaxError
|
20
|
+
from tqdm import tqdm
|
20
21
|
|
21
22
|
from javacore_analyser import tips
|
22
23
|
from javacore_analyser.code_snapshot_collection import CodeSnapshotCollection
|
@@ -32,7 +33,7 @@ def _create_xml_xsl_for_collection(tmp_dir, templates_dir, xml_xsl_filename, col
|
|
32
33
|
logging.info("Creating xmls and xsls in " + tmp_dir)
|
33
34
|
os.mkdir(tmp_dir)
|
34
35
|
extensions = [".xsl", ".xml"]
|
35
|
-
for extension in extensions:
|
36
|
+
for extension in tqdm(extensions, desc="Creating xml/xsl files", unit=" file"):
|
36
37
|
file_full_path = os.path.normpath(os.path.join(templates_dir, xml_xsl_filename + extension))
|
37
38
|
if not file_full_path.startswith(templates_dir):
|
38
39
|
raise Exception("Security exception: Uncontrolled data used in path expression")
|
@@ -89,6 +90,7 @@ class JavacoreSet:
|
|
89
90
|
|
90
91
|
# Assisted by WCA@IBM
|
91
92
|
# Latest GenAI contribution: ibm/granite-8b-code-instruct
|
93
|
+
@staticmethod
|
92
94
|
def process_javacores(input_path):
|
93
95
|
"""
|
94
96
|
Processes Java core data and generates tips based on the analysis.
|
@@ -124,49 +126,53 @@ class JavacoreSet:
|
|
124
126
|
temp_dir = tempfile.TemporaryDirectory()
|
125
127
|
temp_dir_name = temp_dir.name
|
126
128
|
logging.info("Created temp dir: " + temp_dir_name)
|
127
|
-
self.__create_output_files_structure(output_dir)
|
128
129
|
self.__create_report_xml(temp_dir_name + "/report.xml")
|
130
|
+
placeholder_filename = os.path.join(output_dir, "data", "html", "processing_data.html")
|
131
|
+
self.__generate_placeholder_htmls(placeholder_filename,
|
132
|
+
os.path.join(output_dir, "threads"),
|
133
|
+
self.threads, "thread")
|
134
|
+
self.__generate_placeholder_htmls(placeholder_filename,
|
135
|
+
os.path.join(output_dir, "javacores"),
|
136
|
+
self.javacores, "")
|
137
|
+
self.__create_index_html(temp_dir_name, output_dir)
|
129
138
|
self.__generate_htmls_for_threads(output_dir, temp_dir_name)
|
130
139
|
self.__generate_htmls_for_javacores(output_dir, temp_dir_name)
|
131
|
-
self.__create_index_html(temp_dir_name, output_dir)
|
132
140
|
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
raise Exception("Security exception: Uncontrolled data used in path expression")
|
139
|
-
if os.path.isdir(data_output_dir):
|
140
|
-
shutil.rmtree(data_output_dir, ignore_errors=True)
|
141
|
-
logging.info("Data dir: " + data_output_dir)
|
141
|
+
@staticmethod
|
142
|
+
def __generate_placeholder_htmls(placeholder_file, directory, collection, file_prefix):
|
143
|
+
if os.path.exists(directory):
|
144
|
+
shutil.rmtree(directory)
|
145
|
+
os.mkdir(directory)
|
142
146
|
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
+
for element in tqdm(collection, desc="Generating placeholder htmls", unit=" file"):
|
148
|
+
filename = file_prefix + "_" + element.get_id() + ".html"
|
149
|
+
if filename.startswith("_"):
|
150
|
+
filename = filename[1:]
|
151
|
+
file_path = os.path.join(directory, filename)
|
152
|
+
shutil.copy2(placeholder_file, file_path)
|
147
153
|
|
148
154
|
def __generate_htmls_for_threads(self, output_dir, temp_dir_name):
|
149
|
-
_create_xml_xsl_for_collection(temp_dir_name
|
150
|
-
output_dir
|
155
|
+
_create_xml_xsl_for_collection(os.path.join(temp_dir_name, "threads"),
|
156
|
+
os.path.join(output_dir, "data", "xml", "threads"), "thread",
|
151
157
|
self.threads,
|
152
158
|
"thread")
|
153
159
|
self.generate_htmls_from_xmls_xsls(self.report_xml_file,
|
154
|
-
temp_dir_name
|
155
|
-
output_dir
|
160
|
+
os.path.join(temp_dir_name, "threads"),
|
161
|
+
os.path.join(output_dir, "threads"))
|
156
162
|
|
157
163
|
def __generate_htmls_for_javacores(self, output_dir, temp_dir_name):
|
158
|
-
_create_xml_xsl_for_collection(temp_dir_name
|
159
|
-
output_dir
|
164
|
+
_create_xml_xsl_for_collection(os.path.join(temp_dir_name, "javacores"),
|
165
|
+
os.path.join(output_dir, "data", "xml", "javacores"), "javacore",
|
160
166
|
self.javacores,
|
161
167
|
"")
|
162
168
|
self.generate_htmls_from_xmls_xsls(self.report_xml_file,
|
163
|
-
temp_dir_name
|
164
|
-
output_dir
|
169
|
+
os.path.join(temp_dir_name, "javacores"),
|
170
|
+
os.path.join(output_dir, "javacores"))
|
165
171
|
|
166
172
|
def populate_snapshot_collections(self):
|
167
173
|
for javacore in self.javacores:
|
168
174
|
javacore.print_javacore()
|
169
|
-
for s in javacore.snapshots:
|
175
|
+
for s in tqdm(javacore.snapshots, desc="Populating snapshot collection", unit=" javacore"):
|
170
176
|
self.threads.add_snapshot(s)
|
171
177
|
self.stacks.add_snapshot(s)
|
172
178
|
|
@@ -234,6 +240,7 @@ class JavacoreSet:
|
|
234
240
|
filename = os.path.join(self.path, filename)
|
235
241
|
curr_line = ""
|
236
242
|
i = 0
|
243
|
+
file = None
|
237
244
|
try:
|
238
245
|
file = open(filename, 'r')
|
239
246
|
for line in file:
|
@@ -253,17 +260,18 @@ class JavacoreSet:
|
|
253
260
|
elif line.startswith(JAVA_VERSION):
|
254
261
|
self.java_version = line[len(JAVA_VERSION) + 1:].strip()
|
255
262
|
continue
|
256
|
-
except Exception as
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
263
|
+
except Exception as ex:
|
264
|
+
logging.exception(ex)
|
265
|
+
logging.error(f'Error during processing file: {file.name} \n'
|
266
|
+
f'line number: {i} \n'
|
267
|
+
f'line: {curr_line}\n'
|
268
|
+
f'Check the exception below what happened')
|
261
269
|
finally:
|
262
270
|
file.close()
|
263
271
|
|
264
272
|
def parse_javacores(self):
|
265
273
|
""" creates a Javacore object for each javacore...txt file in the given path """
|
266
|
-
for filename in self.files:
|
274
|
+
for filename in tqdm(self.files, "Parsing javacore files", unit=" file"):
|
267
275
|
filename = os.path.join(self.path, filename)
|
268
276
|
javacore = Javacore()
|
269
277
|
javacore.create(filename, self)
|
@@ -283,7 +291,7 @@ class JavacoreSet:
|
|
283
291
|
# return None
|
284
292
|
|
285
293
|
def sort_snapshots(self):
|
286
|
-
for thread in self.threads:
|
294
|
+
for thread in tqdm(self.threads, "Sorting snapshot data", unit=" snapshot"):
|
287
295
|
thread.sort_snapshots()
|
288
296
|
# thread.compare_call_stacks()
|
289
297
|
|
@@ -314,7 +322,7 @@ class JavacoreSet:
|
|
314
322
|
def print_thread_states(self):
|
315
323
|
for thread in self.threads:
|
316
324
|
logging.debug("max running states:" + str(thread.get_continuous_running_states()))
|
317
|
-
logging.debug(thread.name + "(id: " + str(thread.id) + "; hash: " + thread.get_hash() + ") " +
|
325
|
+
logging.debug(thread.name + "(id: " + str(thread.id) + "; hash: " + thread.get_hash() + ") " +
|
318
326
|
"states: " + thread.get_snapshot_states())
|
319
327
|
|
320
328
|
# Assisted by WCA@IBM
|
@@ -474,6 +482,7 @@ class JavacoreSet:
|
|
474
482
|
Returns:
|
475
483
|
str: The JavaCore set in the XML format.
|
476
484
|
"""
|
485
|
+
file = None
|
477
486
|
try:
|
478
487
|
file = open(self.report_xml_file, "r")
|
479
488
|
content = file.read()
|
@@ -492,11 +501,12 @@ class JavacoreSet:
|
|
492
501
|
def __create_index_html(input_dir, output_dir):
|
493
502
|
|
494
503
|
# Copy index.xml and report.xsl to temp - for index.html we don't need to generate anything. Copying is enough.
|
495
|
-
#index_xml = validate_uncontrolled_data_used_in_path([output_dir, "data", "xml", "index.xml"])
|
496
|
-
index_xml = os.path.normpath(importlib_resources.files("javacore_analyser") / "data" / "xml" / "index.xml")
|
504
|
+
# index_xml = validate_uncontrolled_data_used_in_path([output_dir, "data", "xml", "index.xml"])
|
505
|
+
index_xml = os.path.normpath(str(importlib_resources.files("javacore_analyser") / "data" / "xml" / "index.xml"))
|
497
506
|
shutil.copy2(index_xml, input_dir)
|
498
507
|
|
499
|
-
report_xsl = os.path.normpath(
|
508
|
+
report_xsl = os.path.normpath(
|
509
|
+
str(importlib_resources.files("javacore_analyser") / "data" / "xml" / "report.xsl"))
|
500
510
|
shutil.copy2(report_xsl, input_dir)
|
501
511
|
|
502
512
|
xslt_doc = etree.parse(input_dir + "/report.xsl")
|
@@ -519,17 +529,22 @@ class JavacoreSet:
|
|
519
529
|
os.mkdir(output_dir)
|
520
530
|
shutil.copy2(report_xml_file, data_input_dir)
|
521
531
|
|
522
|
-
# Generating list of tuples. This is required attribute for p.map function executed few lines below.
|
523
|
-
generate_html_from_xml_xsl_files_params = []
|
524
|
-
for file in os.listdir(data_input_dir):
|
525
|
-
generate_html_from_xml_xsl_files_params.append((file, data_input_dir, output_dir))
|
526
|
-
|
527
532
|
# https://docs.python.org/3.8/library/multiprocessing.html
|
528
533
|
threads_no = JavacoreSet.get_number_of_parallel_threads()
|
529
534
|
logging.info(f"Using {threads_no} threads to generate html files")
|
535
|
+
|
536
|
+
list_files = os.listdir(data_input_dir)
|
537
|
+
progress_bar = tqdm(desc="Generating html files", unit=' files')
|
538
|
+
|
539
|
+
# Generating list of tuples. This is required attribute for p.map function executed few lines below.
|
540
|
+
generate_html_from_xml_xsl_files_params = []
|
541
|
+
for file in list_files:
|
542
|
+
generate_html_from_xml_xsl_files_params.append((file, data_input_dir, output_dir, progress_bar))
|
543
|
+
|
530
544
|
with Pool(threads_no) as p:
|
531
545
|
p.map(JavacoreSet.generate_html_from_xml_xsl_files, generate_html_from_xml_xsl_files_params)
|
532
546
|
|
547
|
+
progress_bar.close()
|
533
548
|
logging.info(f"Generated html files in {output_dir}")
|
534
549
|
|
535
550
|
# Run with the same number of threads as you have processes but leave one thread for something else.
|
@@ -540,7 +555,7 @@ class JavacoreSet:
|
|
540
555
|
@staticmethod
|
541
556
|
def generate_html_from_xml_xsl_files(args):
|
542
557
|
|
543
|
-
collection_file, collection_input_dir, output_dir = args
|
558
|
+
collection_file, collection_input_dir, output_dir, progress_bar = args
|
544
559
|
|
545
560
|
if not collection_file.endswith(".xsl"): return
|
546
561
|
|
@@ -567,10 +582,30 @@ class JavacoreSet:
|
|
567
582
|
logging.debug("Generating file " + html_file)
|
568
583
|
output_doc.write(html_file, pretty_print=True)
|
569
584
|
|
585
|
+
progress_bar.update(1)
|
586
|
+
|
587
|
+
@staticmethod
|
588
|
+
def create_xml_xsl_for_collection(tmp_dir, xml_xsls_prefix_path, collection, output_file_prefix):
|
589
|
+
logging.info("Creating xmls and xsls in " + tmp_dir)
|
590
|
+
os.mkdir(tmp_dir)
|
591
|
+
extensions = [".xsl", ".xml"]
|
592
|
+
for extension in extensions:
|
593
|
+
file_content = Path(xml_xsls_prefix_path + extension).read_text()
|
594
|
+
for element in tqdm(collection, desc="Creating xml/xsl files", unit=" files"):
|
595
|
+
element_id = element.get_id()
|
596
|
+
filename = output_file_prefix + "_" + str(element_id) + extension
|
597
|
+
if filename.startswith("_"):
|
598
|
+
filename = filename[1:]
|
599
|
+
file = os.path.join(tmp_dir, filename)
|
600
|
+
logging.debug("Writing file " + file)
|
601
|
+
f = open(file, "w")
|
602
|
+
f.write(file_content.format(id=element_id))
|
603
|
+
f.close()
|
604
|
+
|
570
605
|
@staticmethod
|
571
606
|
def parse_mem_arg(line):
|
572
607
|
line = line.split()[-1] # avoid matching the '2' in tag name 2CIUSERARG
|
573
|
-
tokens = re.findall("
|
608
|
+
tokens = re.findall("\d+[KkMmGg]?$", line)
|
574
609
|
if len(tokens) != 1: return UNKNOWN
|
575
610
|
return tokens[0]
|
576
611
|
|
@@ -2,6 +2,8 @@
|
|
2
2
|
# Copyright IBM Corp. 2024 - 2024
|
3
3
|
# SPDX-License-Identifier: Apache-2.0
|
4
4
|
#
|
5
|
+
from tqdm import tqdm
|
6
|
+
|
5
7
|
|
6
8
|
class SnapshotCollectionCollection:
|
7
9
|
|
@@ -23,15 +25,15 @@ class SnapshotCollectionCollection:
|
|
23
25
|
def __iter__(self):
|
24
26
|
return self.snapshot_collections.__iter__()
|
25
27
|
|
26
|
-
def __next__(self):
|
27
|
-
|
28
|
+
# def __next__(self):
|
29
|
+
# return self.snapshot_collections.__next__()
|
28
30
|
|
29
31
|
def get_xml(self, doc):
|
30
32
|
info_node = doc.createElement(self.snapshot_collection_type.__name__)
|
31
33
|
|
32
34
|
all_threads_node = doc.createElement('all_snapshot_collection')
|
33
35
|
info_node.appendChild(all_threads_node)
|
34
|
-
for collection in self.snapshot_collections:
|
36
|
+
for collection in tqdm(self.snapshot_collections, desc=" Generating threads data", unit=" thread"):
|
35
37
|
all_threads_node.appendChild(collection.get_xml(doc))
|
36
38
|
|
37
39
|
return info_node
|
javacore_analyser/stack_trace.py
CHANGED
@@ -26,8 +26,8 @@ class StackTrace:
|
|
26
26
|
def __iter__(self):
|
27
27
|
return self.stack_trace_elements.__iter__()
|
28
28
|
|
29
|
-
def __next__(self):
|
30
|
-
|
29
|
+
# def __next__(self):
|
30
|
+
# return self.stack_trace_elements.__next__()
|
31
31
|
|
32
32
|
def equals(self, stack_trace):
|
33
33
|
self_stack_trace_size = len(self.stack_trace_elements)
|
@@ -17,12 +17,17 @@
|
|
17
17
|
|
18
18
|
<h2>Generate report:</h2>
|
19
19
|
<form action="/upload" method="post" enctype="multipart/form-data">
|
20
|
-
<
|
21
|
-
<
|
20
|
+
<ol>
|
21
|
+
<li>Choose archive (zip, 7z, tgz, bz2) file or multiple javacore files:
|
22
|
+
<input type="file" name="files" multiple required>
|
23
|
+
</li>
|
24
|
+
<li>Give the name for your report: <input type="text" id="report_name" name="report_name" required></li>
|
25
|
+
<li>Click button to process: <input type="submit" value="Run"></li>
|
26
|
+
</ol>
|
22
27
|
<strong>
|
23
|
-
NOTE:
|
28
|
+
NOTE: Report generation is an expensive operation. It may take a few minutes. Please be patient.
|
24
29
|
</strong>
|
25
|
-
|
30
|
+
|
26
31
|
</form>
|
27
32
|
<br></br>
|
28
33
|
|
@@ -2,7 +2,7 @@
|
|
2
2
|
# Copyright IBM Corp. 2024 - 2024
|
3
3
|
# SPDX-License-Identifier: Apache-2.0
|
4
4
|
#
|
5
|
-
|
5
|
+
import logging
|
6
6
|
import os
|
7
7
|
import re
|
8
8
|
from datetime import datetime
|
@@ -123,7 +123,8 @@ class ThreadSnapshot:
|
|
123
123
|
try:
|
124
124
|
token = m.group(1)
|
125
125
|
self.cpu_usage = float(token)
|
126
|
-
except:
|
126
|
+
except Exception as ex:
|
127
|
+
logging.warning(ex)
|
127
128
|
self.cpu_usage = 0
|
128
129
|
# tokens = re.findall("[0-9]+\.[0-9]+", line)
|
129
130
|
# if len(tokens) == 0:
|
javacore_analyser/tips.py
CHANGED
@@ -2,6 +2,7 @@
|
|
2
2
|
# Copyright IBM Corp. 2024 - 2024
|
3
3
|
# SPDX-License-Identifier: Apache-2.0
|
4
4
|
#
|
5
|
+
import logging
|
5
6
|
|
6
7
|
# This is a module containing list of the tips.
|
7
8
|
# Each tip has to implement dynamic method generate(javacore_set)
|
@@ -16,6 +17,7 @@ class TestTip:
|
|
16
17
|
|
17
18
|
@staticmethod
|
18
19
|
def generate(javacore_set):
|
20
|
+
logging.info(javacore_set)
|
19
21
|
return ["this is a test tip. Ignore it."]
|
20
22
|
|
21
23
|
|
@@ -157,7 +159,7 @@ class BlockingThreadsTip:
|
|
157
159
|
result.append(BlockingThreadsTip.BLOCKING_THREADS_TEXT.format(blocker_name,
|
158
160
|
blocked_size / javacores_no))
|
159
161
|
if len(result) >= BlockingThreadsTip.MAX_BLOCKING_THREADS_NO:
|
160
|
-
break
|
162
|
+
break
|
161
163
|
return result
|
162
164
|
|
163
165
|
|
@@ -165,9 +167,9 @@ class HighCpuUsageTip:
|
|
165
167
|
# Generates the tip if the thread is using above x percent of CPU. Also informs, if this is verbose gc thread.
|
166
168
|
|
167
169
|
# Report as high cpu usage for the application using the cpu usage above this value
|
168
|
-
CRITICAL_CPU_USAGE = 50
|
170
|
+
CRITICAL_CPU_USAGE = 50
|
169
171
|
|
170
|
-
CRITICAL_USAGE_FOR_GC = 5
|
172
|
+
CRITICAL_USAGE_FOR_GC = 5
|
171
173
|
|
172
174
|
MAX_NUMBER_OF_HIGH_CPU_USAGE_THREADS = 5
|
173
175
|
|
javacore_analyser/verbose_gc.py
CHANGED
@@ -8,6 +8,8 @@ import ntpath
|
|
8
8
|
from datetime import datetime
|
9
9
|
from xml.dom.minidom import Element, parseString
|
10
10
|
|
11
|
+
from tqdm import tqdm
|
12
|
+
|
11
13
|
ROOT_CLOSING_TAG = "</verbosegc>"
|
12
14
|
GC_START = "gc-start"
|
13
15
|
GC_END = "gc-end"
|
@@ -43,7 +45,7 @@ class VerboseGcParser:
|
|
43
45
|
|
44
46
|
def parse_files(self, start_time, stop_time):
|
45
47
|
logging.info("Started parsing GC files")
|
46
|
-
for file_path in self.__file_paths:
|
48
|
+
for file_path in tqdm(self.__file_paths, desc="Parsing verbose gc", unit=" file"):
|
47
49
|
try:
|
48
50
|
collects_from_time_range = 0
|
49
51
|
file = VerboseGcFile(file_path)
|
@@ -109,6 +111,7 @@ class VerboseGcFile:
|
|
109
111
|
|
110
112
|
def __parse(self):
|
111
113
|
# read in the file as collection of lines
|
114
|
+
file = None
|
112
115
|
try:
|
113
116
|
xml_text = ""
|
114
117
|
root_closing_tag_available = False
|
@@ -1,6 +1,6 @@
|
|
1
|
-
Metadata-Version: 2.
|
1
|
+
Metadata-Version: 2.4
|
2
2
|
Name: javacore_analyser
|
3
|
-
Version: 2.
|
3
|
+
Version: 2.1.0.dev66
|
4
4
|
Summary: The tool to review IBM Javacore files
|
5
5
|
Project-URL: Homepage, https://github.com/IBM/javacore-analyser
|
6
6
|
Project-URL: Issues, https://github.com/IBM/javacore-analyser/issues
|
@@ -209,6 +209,7 @@ License: Apache License
|
|
209
209
|
See the License for the specific language governing permissions and
|
210
210
|
limitations under the License.
|
211
211
|
|
212
|
+
License-File: LICENSE
|
212
213
|
Classifier: Development Status :: 5 - Production/Stable
|
213
214
|
Classifier: Environment :: Console
|
214
215
|
Classifier: Environment :: Web Environment
|
@@ -226,12 +227,12 @@ Classifier: Programming Language :: Python :: 3.11
|
|
226
227
|
Classifier: Programming Language :: Python :: 3.12
|
227
228
|
Classifier: Programming Language :: Python :: 3.13
|
228
229
|
Requires-Python: >=3.9
|
229
|
-
Requires-Dist: dicttoxml
|
230
230
|
Requires-Dist: flask
|
231
231
|
Requires-Dist: importlib-resources
|
232
232
|
Requires-Dist: lxml
|
233
233
|
Requires-Dist: py7zr
|
234
234
|
Requires-Dist: pyana
|
235
|
+
Requires-Dist: tqdm
|
235
236
|
Requires-Dist: waitress
|
236
237
|
Description-Content-Type: text/markdown
|
237
238
|
|
@@ -280,9 +281,7 @@ This is recommended for geeks only:
|
|
280
281
|
#### Running cmd application:
|
281
282
|
1. Install application if not done yet
|
282
283
|
2. Activate your created virtual environment according to activate Virtual Environment according to [Creating virtual environments](https://docs.python.org/3/tutorial/venv.html#creating-virtual-environments)
|
283
|
-
3.
|
284
|
-
`pip install requirements.txt`
|
285
|
-
4. Run the following command from cmd: `javacore-analyser-batch <input-data> <generated-reports-dir>`
|
284
|
+
3. Run the following command from cmd: `javacore-analyser-batch <input-data> <generated-reports-dir>`
|
286
285
|
Where `<input-data>` is one of the following:
|
287
286
|
* The directory containing javacores and optionally verbose gc
|
288
287
|
* Archive (7z, zip, tar.gz, tar.bz2) containing the same
|
@@ -292,17 +291,28 @@ You can type the following command to obtain the help:
|
|
292
291
|
|
293
292
|
#### Running web application:
|
294
293
|
1. Repeat steps 1-3 from cmd application
|
295
|
-
2.
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
The first parameter sets where the reports need to be stored. If not set, then the `reports` dir will be created in current location.
|
301
|
-
The first parameter set the port to use by application. If not specified, 5000 will be used.
|
302
|
-
3. Execute the following command from cmd:
|
303
|
-
`javacore_analyser_web`
|
294
|
+
2. Execute the following command from cmd:
|
295
|
+
`javacore_analyser_web --port=500 --reports-dir=/data/reports_dir`
|
296
|
+
|
297
|
+
The first parameter set the port to use by application. If not specified, 5000 will be used.
|
298
|
+
The second parameter sets where the reports need to be stored. If not set, then the `reports` dir will be created in current location.
|
304
299
|
|
305
300
|
Now you can type (http://localhost:5000/).
|
301
|
+
|
302
|
+
### Running container image
|
303
|
+
There is an unofficial Docker/Podman container managed by one of projects developers. Use the following command
|
304
|
+
to start it:
|
305
|
+
|
306
|
+
`podman run -it --rm --name javacore-analyser --mount type=bind,src="/local-reports-dir",target=/reports -p 5001:5000 ghcr.io/kkazmierczyk/javacore-analyser:latest`
|
307
|
+
|
308
|
+
or
|
309
|
+
`docker run -it --rm --name javacore-analyser --mount type=bind,src="/local-reports-dir",target=/reports -p 5001:5000 ghcr.io/kkazmierczyk/javacore-analyser:latest`
|
310
|
+
|
311
|
+
The `mount` option specifies where you want locally to store the reports. The reports in the container are stored in
|
312
|
+
`/reports` directory. If you remove mount option, the application will work but the reports will not persist after
|
313
|
+
restart.
|
314
|
+
The application is running in the container on port 5000. By using `-p 5001:5000` option, you specify to map container
|
315
|
+
port 5000 to port 5001 on your machine. Therefore the application will be available under `http://localhost:5001/`.
|
306
316
|
|
307
317
|
<!-- The following are OPTIONAL, but strongly suggested to have in your repository. -->
|
308
318
|
<!--
|
@@ -0,0 +1,45 @@
|
|
1
|
+
javacore_analyser/__init__.py,sha256=Sw2ZeqcI2Kx1cDDv083n1SiSY_FDRCmidTuzaN1uRSw,76
|
2
|
+
javacore_analyser/abstract_snapshot_collection.py,sha256=jGfd2XgujurRlKgEtlJjqNJK9sUvTdFsdgFnX9oLzt4,5589
|
3
|
+
javacore_analyser/code_snapshot_collection.py,sha256=6_C5myag5ocjOTwXVDbBamN6Lf1szgS3ylSHEEjUdVg,2655
|
4
|
+
javacore_analyser/constants.py,sha256=iGYAznPK8AySq6uqk-cpCU8Dbjbq6PrCh6q2mF8oeu8,1003
|
5
|
+
javacore_analyser/java_thread.py,sha256=4zUfmmlH47SrIxgfPmrJHl_YUziVJXVNVedD5X25vXY,4464
|
6
|
+
javacore_analyser/javacore.py,sha256=_2abTyvXEaZ6Tx8r9d3NEzRCIBcf4Is8lSjpKyPu-R8,6884
|
7
|
+
javacore_analyser/javacore_analyser_batch.py,sha256=g6xVPYFDHTaXDbaruyMRUrD3g2IlJK3Ht-XUzHv3LoQ,6802
|
8
|
+
javacore_analyser/javacore_analyser_web.py,sha256=Ef91ZTI5TBaJPJhl0FtzrFHvzJNPLe07fmvbvik3OJQ,5788
|
9
|
+
javacore_analyser/javacore_set.py,sha256=YM6ZKUhbfqzjuKE5y7Jy19Hbl-BSLA1i5gIsP7NbX38,31241
|
10
|
+
javacore_analyser/logging_utils.py,sha256=vLob0ikezysjGv9XGqv9GbLekxu4eO_csq22M-gtLiQ,966
|
11
|
+
javacore_analyser/snapshot_collection.py,sha256=fLEnwg9-cOjVVUUludtzI7R2yO9BBVgJgxkhvqG5QDg,443
|
12
|
+
javacore_analyser/snapshot_collection_collection.py,sha256=1PV1TX4QQk01dAbX-k-kTpgKr6Il867Bw6X7HHBuv-Q,1346
|
13
|
+
javacore_analyser/stack_trace.py,sha256=8sb8z4ac_L0yyxqJX1ukrTZRyngkHcA3zkXyqxG5ygA,1664
|
14
|
+
javacore_analyser/stack_trace_element.py,sha256=pZPrK1ACBUDE7YsVOFhTfewXequ1m5P-B0N-9RuhkWo,1143
|
15
|
+
javacore_analyser/stack_trace_kind.py,sha256=lOdfb_F3XrwDLciPk_ZgM_fmMn5JoXsIUjr7pjvmU4M,157
|
16
|
+
javacore_analyser/thread_snapshot.py,sha256=2Do8NPBXdpUezQrUI_9nyGbtU4b2s5euPnHqcuuKq7U,13255
|
17
|
+
javacore_analyser/tips.py,sha256=EhwLUAha0FvFJtO5kmvba9a1nKXGdqNHFa2jFbHZr4U,8655
|
18
|
+
javacore_analyser/verbose_gc.py,sha256=LLJ-PS2maOkP6zfW-RBGoEoHQBI99Reejb1tqpZispY,6872
|
19
|
+
javacore_analyser/data/expand.js,sha256=KwqvNUoO7yMDeQKcnLDywfMdR3Zsjan5L8QoPsQQLGo,956
|
20
|
+
javacore_analyser/data/style.css,sha256=YzHl0NSnfRik4ar6AInp7pZ_re1rirQy6L5jqdbKoKg,2246
|
21
|
+
javacore_analyser/data/html/processing_data.html,sha256=S1S2GMXQ8oQdqdYTcPzVMxUib-NLtM4ffT3OJaIIO7w,421
|
22
|
+
javacore_analyser/data/jquery/chart.js,sha256=tgiW1vJqfIKxE0F2uVvsXbgUlTyrhPMY_sm30hh_Sxc,203464
|
23
|
+
javacore_analyser/data/jquery/chartjs-adapter-date-fns.bundle.min.js,sha256=6nqzDSbDjc8fLSa7Q-c6lFN7WPGQb1XhpUbdCTIbVhU,50650
|
24
|
+
javacore_analyser/data/jquery/jq.css,sha256=CXwJ7OOkFWXsebmAipjne1TnNanpp_2z241eLsVB7Ls,6751
|
25
|
+
javacore_analyser/data/jquery/jquery.mark.min.js,sha256=p_nep2K57or4Km0eXahvl6J_geaGx-wwGqIGSNhGUa4,8123
|
26
|
+
javacore_analyser/data/jquery/jquery.min.js,sha256=pvPw-upLPUjgMXY0G-8O0xUf-_Im1MZjXxxgOcBQBXU,89947
|
27
|
+
javacore_analyser/data/jquery/jquery.tablesorter.min.js,sha256=dtGH1XcAyKopMui5x20KnPxuGuSx9Rs6piJB_4Oqu6I,44365
|
28
|
+
javacore_analyser/data/jquery/jquery.tablesorter.widgets.min.js,sha256=GxbszpUzg-iYIcyDGyNVLz9Y0dQvzmQgXXVk5cHJbw0,53100
|
29
|
+
javacore_analyser/data/jquery/search.js,sha256=Jwi-cBJ9YKDHJwqIlcKXqrpcM1BX-wx93uKAR44JLww,4200
|
30
|
+
javacore_analyser/data/jquery/sorting.js,sha256=HsuVLa7F70IM4ZMXZpjj7wtVI1TXL1SPbZGWenv0Jp8,369
|
31
|
+
javacore_analyser/data/jquery/theme.blue.css,sha256=mI0RCGd6G5GOKSG7BPagp0N58xipSjPXUKvrcHJ4h1Q,7528
|
32
|
+
javacore_analyser/data/jquery/theme.default.min.css,sha256=5sgExNTnkN8NcApKIU73_aqgZmqq_zJp9-9zXf9aSEw,4502
|
33
|
+
javacore_analyser/data/jquery/wait2scripts.js,sha256=CMbSqte7Ln0hP9ZScESGdIDfWEmxJwvfLZjDfYNc1Sg,8427
|
34
|
+
javacore_analyser/data/xml/index.xml,sha256=9VH2rmri3FQpXcW39kbyi2dON94C5XTiaQn0ioExCe8,282
|
35
|
+
javacore_analyser/data/xml/report.xsl,sha256=XEwgf0qfXL1fXjj-X5iYYwt-D0cPjI9mLjhTmRvyNnk,49697
|
36
|
+
javacore_analyser/data/xml/javacores/javacore.xml,sha256=6dG89Whx1_kpEYVS_F6Upa2XuXnXorlQATFc8kD5Mfc,280
|
37
|
+
javacore_analyser/data/xml/javacores/javacore.xsl,sha256=5cnIp08Q9FccljHH8duoJQYofyW8lwUCGtpdzz5Y0Y8,11644
|
38
|
+
javacore_analyser/data/xml/threads/thread.xml,sha256=6dG89Whx1_kpEYVS_F6Upa2XuXnXorlQATFc8kD5Mfc,280
|
39
|
+
javacore_analyser/data/xml/threads/thread.xsl,sha256=rkqr5GQ2aZ_xrdhUjl2QZDCZ-09zxqUmtV8DFZVjTAA,13927
|
40
|
+
javacore_analyser/templates/index.html,sha256=aEuyry-HZ9HlQNwfbugugvqbSxwlo7LrQnrDmqO34YE,1682
|
41
|
+
javacore_analyser-2.1.0.dev66.dist-info/METADATA,sha256=Viz5zYXbffyGSshp-4U0fTiKLOFoTN4wmNP2aAziw18,21231
|
42
|
+
javacore_analyser-2.1.0.dev66.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
43
|
+
javacore_analyser-2.1.0.dev66.dist-info/entry_points.txt,sha256=W3S799zI58g5-jWMsC3wY9xksz21LPEMYOILv8sayfM,160
|
44
|
+
javacore_analyser-2.1.0.dev66.dist-info/licenses/LICENSE,sha256=xllut76FgcGL5zbIRvuRc7aezPbvlMUTWJPsVr2Sugg,11358
|
45
|
+
javacore_analyser-2.1.0.dev66.dist-info/RECORD,,
|
@@ -1,44 +0,0 @@
|
|
1
|
-
javacore_analyser/__init__.py,sha256=Sw2ZeqcI2Kx1cDDv083n1SiSY_FDRCmidTuzaN1uRSw,76
|
2
|
-
javacore_analyser/abstract_snapshot_collection.py,sha256=zXLRPQRdFpOufC8OVMh1wAhFnFDYQgWy10zZOZWaZQc,5592
|
3
|
-
javacore_analyser/code_snapshot_collection.py,sha256=6_C5myag5ocjOTwXVDbBamN6Lf1szgS3ylSHEEjUdVg,2655
|
4
|
-
javacore_analyser/constants.py,sha256=hGEsldGuuJGqy1iM7POiQnjVqNLclO5CjIKeIW2oeIQ,924
|
5
|
-
javacore_analyser/java_thread.py,sha256=4zUfmmlH47SrIxgfPmrJHl_YUziVJXVNVedD5X25vXY,4464
|
6
|
-
javacore_analyser/javacore.py,sha256=NkvxN6C93eG24wEB_kfH-yf0_f_ECj7Let4bQ1i22AM,6860
|
7
|
-
javacore_analyser/javacore_analyser_batch.py,sha256=ApC_xcDMIP4DxQ0MUiD6XrF3hzcyFmofVH1Jq4-6_4s,5408
|
8
|
-
javacore_analyser/javacore_analyser_web.py,sha256=DJgzHKuGUkATKaE7pI6zOQPGITB6hdM86tUXsZ1fCWw,4526
|
9
|
-
javacore_analyser/javacore_set.py,sha256=3EIl3Wrq3RUo3APfHmDq4Nllq5_ufSC9qZquogiy4ns,29420
|
10
|
-
javacore_analyser/logging_utils.py,sha256=vLob0ikezysjGv9XGqv9GbLekxu4eO_csq22M-gtLiQ,966
|
11
|
-
javacore_analyser/snapshot_collection.py,sha256=fLEnwg9-cOjVVUUludtzI7R2yO9BBVgJgxkhvqG5QDg,443
|
12
|
-
javacore_analyser/snapshot_collection_collection.py,sha256=JyNr038nC8mcX1mjeXjNSzZT4oE9ACFmCYJORUKzyvw,1265
|
13
|
-
javacore_analyser/stack_trace.py,sha256=RY1nmvSA_lyRqVejHcXBbxT8EhbkJPktBqsQ4kKSgtA,1661
|
14
|
-
javacore_analyser/stack_trace_element.py,sha256=1WOV7pilb8RAc_hMN7lsXMrPevW6WFHAaLOGpsMmJgs,1145
|
15
|
-
javacore_analyser/stack_trace_kind.py,sha256=lOdfb_F3XrwDLciPk_ZgM_fmMn5JoXsIUjr7pjvmU4M,157
|
16
|
-
javacore_analyser/thread_snapshot.py,sha256=TR0StpE-r4FYax8oULUANBsKJDYX3FQ0lwzwnvEPxic,13193
|
17
|
-
javacore_analyser/tips.py,sha256=pA8mpmyPk9RXPVt5GFiB9dlhiBeiGPKUBgJgvPRUmLk,8608
|
18
|
-
javacore_analyser/verbose_gc.py,sha256=mSFIRb-thl5nrdEd_SOxFcvobso_07NQ2_g1_9IXgY0,6782
|
19
|
-
javacore_analyser/data/expand.js,sha256=mNjvT_00YHQxWhlAQwFElzlhBWvKP5WEMSWJkL1PKl8,954
|
20
|
-
javacore_analyser/data/style.css,sha256=YzHl0NSnfRik4ar6AInp7pZ_re1rirQy6L5jqdbKoKg,2246
|
21
|
-
javacore_analyser/data/jquery/chart.js,sha256=tgiW1vJqfIKxE0F2uVvsXbgUlTyrhPMY_sm30hh_Sxc,203464
|
22
|
-
javacore_analyser/data/jquery/chartjs-adapter-date-fns.bundle.min.js,sha256=6nqzDSbDjc8fLSa7Q-c6lFN7WPGQb1XhpUbdCTIbVhU,50650
|
23
|
-
javacore_analyser/data/jquery/jq.css,sha256=CXwJ7OOkFWXsebmAipjne1TnNanpp_2z241eLsVB7Ls,6751
|
24
|
-
javacore_analyser/data/jquery/jquery.mark.min.js,sha256=p_nep2K57or4Km0eXahvl6J_geaGx-wwGqIGSNhGUa4,8123
|
25
|
-
javacore_analyser/data/jquery/jquery.min.js,sha256=pvPw-upLPUjgMXY0G-8O0xUf-_Im1MZjXxxgOcBQBXU,89947
|
26
|
-
javacore_analyser/data/jquery/jquery.tablesorter.min.js,sha256=dtGH1XcAyKopMui5x20KnPxuGuSx9Rs6piJB_4Oqu6I,44365
|
27
|
-
javacore_analyser/data/jquery/jquery.tablesorter.widgets.min.js,sha256=GxbszpUzg-iYIcyDGyNVLz9Y0dQvzmQgXXVk5cHJbw0,53100
|
28
|
-
javacore_analyser/data/jquery/search.js,sha256=hY0kp5ZIUazzM32hEmArA3ql6MTiOjjf5wosxXvowAw,3398
|
29
|
-
javacore_analyser/data/jquery/sorting.js,sha256=HsuVLa7F70IM4ZMXZpjj7wtVI1TXL1SPbZGWenv0Jp8,369
|
30
|
-
javacore_analyser/data/jquery/theme.blue.css,sha256=mI0RCGd6G5GOKSG7BPagp0N58xipSjPXUKvrcHJ4h1Q,7528
|
31
|
-
javacore_analyser/data/jquery/theme.default.min.css,sha256=5sgExNTnkN8NcApKIU73_aqgZmqq_zJp9-9zXf9aSEw,4502
|
32
|
-
javacore_analyser/data/jquery/wait2scripts.js,sha256=DmSgbHk_nP-9Echk1OwvdVXi_MwsfdFe0F7qIyfmsbM,8054
|
33
|
-
javacore_analyser/data/xml/index.xml,sha256=9VH2rmri3FQpXcW39kbyi2dON94C5XTiaQn0ioExCe8,282
|
34
|
-
javacore_analyser/data/xml/report.xsl,sha256=ZFcy8dfEB7rTQwcQvUKKSvyEl7HylXgjHjD7bWVpYes,49693
|
35
|
-
javacore_analyser/data/xml/javacores/javacore.xml,sha256=6dG89Whx1_kpEYVS_F6Upa2XuXnXorlQATFc8kD5Mfc,280
|
36
|
-
javacore_analyser/data/xml/javacores/javacore.xsl,sha256=9FANZSXy1pTKIkb2pMQBS9IxOfAK2yKRzsKlabs-X2g,10509
|
37
|
-
javacore_analyser/data/xml/threads/thread.xml,sha256=6dG89Whx1_kpEYVS_F6Upa2XuXnXorlQATFc8kD5Mfc,280
|
38
|
-
javacore_analyser/data/xml/threads/thread.xsl,sha256=YvfwICfSDNQbB7tSrISCdlQ1hTNkfiEFd0XtO7-Lhb0,12636
|
39
|
-
javacore_analyser/templates/index.html,sha256=3XVMLjUOv8e5ISW_Z4OyvVuBxnb2Ytrq-seC810kUq8,1582
|
40
|
-
javacore_analyser-2.0rc1.dist-info/METADATA,sha256=ZA-ftJphoR5Tb37o6_rpGjuVquHAhg2c2rxuVgVGU0c,20363
|
41
|
-
javacore_analyser-2.0rc1.dist-info/WHEEL,sha256=C2FUgwZgiLbznR-k0b_5k3Ai_1aASOXDss3lzCUsUug,87
|
42
|
-
javacore_analyser-2.0rc1.dist-info/entry_points.txt,sha256=W3S799zI58g5-jWMsC3wY9xksz21LPEMYOILv8sayfM,160
|
43
|
-
javacore_analyser-2.0rc1.dist-info/licenses/LICENSE,sha256=xllut76FgcGL5zbIRvuRc7aezPbvlMUTWJPsVr2Sugg,11358
|
44
|
-
javacore_analyser-2.0rc1.dist-info/RECORD,,
|
{javacore_analyser-2.0rc1.dist-info → javacore_analyser-2.1.0.dev66.dist-info}/entry_points.txt
RENAMED
File without changes
|
{javacore_analyser-2.0rc1.dist-info → javacore_analyser-2.1.0.dev66.dist-info}/licenses/LICENSE
RENAMED
File without changes
|