javacore-analyser 2.0rc1__tar.gz → 2.1__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- javacore_analyser-2.1/CHANGELOG.md +23 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/CONTRIBUTING.md +22 -3
- javacore_analyser-2.1/Dockerfile +15 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/MAINTAINERS.md +1 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/PKG-INFO +46 -20
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/README.md +41 -16
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/pyproject.toml +5 -5
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/requirements.txt +2 -2
- javacore_analyser-2.1/src/javacore_analyser/__main__.py +43 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/abstract_snapshot_collection.py +2 -2
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/constants.py +2 -1
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/expand.js +2 -0
- javacore_analyser-2.1/src/javacore_analyser/data/html/processing_data.html +17 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/search.js +22 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/wait2scripts.js +31 -7
- javacore_analyser-2.1/src/javacore_analyser/data/xml/javacores/javacore.xsl +174 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/xml/report.xsl +36 -20
- javacore_analyser-2.1/src/javacore_analyser/data/xml/threads/thread.xsl +213 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/javacore.py +5 -3
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/javacore_analyser_batch.py +45 -22
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/javacore_analyser_web.py +62 -26
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/javacore_set.py +82 -43
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/snapshot_collection_collection.py +5 -3
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/stack_trace.py +2 -2
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/stack_trace_element.py +1 -1
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/templates/index.html +9 -4
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/thread_snapshot.py +3 -2
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/tips.py +5 -3
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/verbose_gc.py +4 -2
- javacore_analyser-2.0rc1/CHANGELOG.md +0 -12
- javacore_analyser-2.0rc1/src/javacore_analyser/data/xml/javacores/javacore.xsl +0 -165
- javacore_analyser-2.0rc1/src/javacore_analyser/data/xml/threads/thread.xsl +0 -204
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/.github/dco.yml +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/.gitignore +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/.travis.yml +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/CODE_OF_CONDUCT.md +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/LICENSE +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/REQUIREMENTS.md +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/SECURITY.md +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/docs/ClassDiagram.png +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/docs/dom_example.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/__init__.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/code_snapshot_collection.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/chart.js +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/chartjs-adapter-date-fns.bundle.min.js +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/jq.css +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/jquery.mark.min.js +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/jquery.min.js +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/jquery.tablesorter.min.js +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/jquery.tablesorter.widgets.min.js +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/sorting.js +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/theme.blue.css +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/theme.default.min.css +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/style.css +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/xml/index.xml +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/xml/javacores/javacore.xml +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/xml/threads/thread.xml +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/java_thread.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/logging_utils.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/snapshot_collection.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/stack_trace_kind.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/__init__.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/archives/archive_without_javacores.zip +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/archives/javacores/aaa-javacore.20220606.114458.32888.0001.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/archives/javacores/aaa-javacore.20220606.114502.32888.0002.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/archives/javacores-corrupted.zip +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/archives/javacores-starting-aaa.zip +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/archives/javacores.7z +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/archives/javacores.tar.bz2 +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/archives/javacores.tar.gz +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/archives/javacores.tgz +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/archives/javacores.zip +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/archives/javacores_with_invalid_chars.zip +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/issue129/javacore.20230602.091848.83156.0001.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/issue129/javacore.20230602.091853.83156.0002.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114458.32888.0001.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114502.32888.0002.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114506.32888.0003.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114513.32888.0004.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114516.32888.0005.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114900.32888.0006.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114907.32888.0007.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114912.32888.0008.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114931.32888.0009.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114947.32888.0010.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114948.32888.0011.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.20220606.114949.32888.0012.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/javacore.wrong.corr +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/verbosegc.230105.19308.txt.001 +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/verbosegc.230413.19984.txt.001 +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/javacores/verbosegc.230420.33424.txt.001 +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/quotationMarks/javacore.20230830.134339.30220.0001.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/quotationMarks/javacore.20230830.134339.30220.0002.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/verboseGc/verbosegc.230105.19308.txt.001 +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/verboseGc/verbosegc.230413.19984.txt.001 +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/verboseGc/verbosegc.230420.33424.txt.001 +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/verboseGcJavacores/javacore.20230602.091848.83156.0001.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/verboseGcJavacores/javacore.20230602.091853.83156.0002.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/verboseGcJavacores/javacore.20230602.092423.83156.0003.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/verboseGcJavacores/javacore.20230602.092537.83156.0004.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/verboseGcJavacores/javacore.20230602.092604.83156.0005.txt +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/verboseGcJavacores/verbosegc.230602.61164.txt.001 +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/verboseGcJavacores/verbosegc.230602.83156.txt.001 +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/data/verboseGcJavacores.zip +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/test_code_snapshot_collection.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/test_gc_collection.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/test_java_thread.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/test_javacore.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/test_javacore_analyser.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/test_javacore_set.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/test_stack_trace.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/test_stack_trace_element.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/test_thread_snapshot.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/test_tips.py +0 -0
- {javacore_analyser-2.0rc1 → javacore_analyser-2.1}/test/test_verbose_gc_parser.py +0 -0
@@ -0,0 +1,23 @@
|
|
1
|
+
# Changelog
|
2
|
+
|
3
|
+
|
4
|
+
## [2.0] - 2024-12-03
|
5
|
+
* #10 extract api methods by @kkazmierczyk in https://github.com/IBM/javacore-analyser/pull/11
|
6
|
+
* #8 generate web application by @kkazmierczyk in https://github.com/IBM/javacore-analyser/pull/23
|
7
|
+
* System information xmx value is blank when xmx does not have units by @PiotrAniola82 in https://github.com/IBM/javacore-analyser/pull/36
|
8
|
+
* #18-GC-activity-chart-shows-wrong-values-when-xmx-has-no-units by @tjanasiewicz in https://github.com/IBM/javacore-analyser/pull/45
|
9
|
+
* #14 Implemented progressbars by @kkazmierczyk in https://github.com/IBM/javacore-analyser/pull/15
|
10
|
+
* #12 generate pip package by @kkazmierczyk in https://github.com/IBM/javacore-analyser/pull/37
|
11
|
+
* Tidied up the expensive operation message by @PiotrAniola82 in https://github.com/IBM/javacore-analyser/pull/56
|
12
|
+
* Switched the doc link to point to the public wiki on github by @PiotrAniola82 in https://github.com/IBM/javacore-analyser/pull/54
|
13
|
+
* Added search bar to thread.xsl and javacore.xsl by @PiotrAniola82 in https://github.com/IBM/javacore-analyser/pull/51
|
14
|
+
* Updated the input/output arguments of the javacore_analyser_batch. by @tjanasiewicz in https://github.com/IBM/javacore-analyser/pull/63
|
15
|
+
|
16
|
+
[2.0]: https://github.com/IBM/javacore-analyser/releases/tag/2.0
|
17
|
+
|
18
|
+
## [1.0] - 2024-10-25
|
19
|
+
|
20
|
+
### Added
|
21
|
+
- Initial product release
|
22
|
+
|
23
|
+
[1.0]: https://github.com/IBM/javacore-analyser/releases/tag/v1.0
|
@@ -85,9 +85,9 @@ Change the second parameter to the directory where you want the output report be
|
|
85
85
|
|
86
86
|
To run web application:
|
87
87
|
1. Right click on **javacore_analyser_web.py** directory in **Project** view and select **Modify Run Configuration...**.
|
88
|
-
2. Add the following
|
89
|
-
|
90
|
-
|
88
|
+
2. Add the following parameters:
|
89
|
+
**debug=True reports_dir=/tmp/web_reports**
|
90
|
+
|
91
91
|
You can change the report dir to the location when you want to store the report.
|
92
92
|
The application will start on http://localhost:5000
|
93
93
|
|
@@ -96,6 +96,25 @@ To run web application:
|
|
96
96
|
Follow the steps from [Packaging projects](https://packaging.python.org/en/latest/tutorials/packaging-projects/).
|
97
97
|
Currently Chris has an API keys for test and production pypi
|
98
98
|
|
99
|
+
## Build container localy
|
100
|
+
To build a container:
|
101
|
+
`podman build -t javacore-analyser .`
|
102
|
+
|
103
|
+
or
|
104
|
+
|
105
|
+
`docker build -t javacore-analyser .`
|
106
|
+
|
107
|
+
To start the container:
|
108
|
+
`podman run -it --rm --name javacore-analyser --mount type=bind,src="local-dir-on-fs",target=/reports -p 5001:5000 javacore-analyser`
|
109
|
+
|
110
|
+
or
|
111
|
+
|
112
|
+
`docker run -it --rm --name javacore-analyser --mount type=bind,src="local-dir-on-fs",target=/reports -p 5001:5000 javacore-analyser`
|
113
|
+
|
114
|
+
`src` parameter specifies where you want to store reports locally
|
115
|
+
`-p` specifies port mapping. The application in container is running on port 5000. You can map it to another port on
|
116
|
+
your machine (5001 in this example).
|
117
|
+
|
99
118
|
## Testing
|
100
119
|
As default the tests in Pycharm are ran in the current selected directory. However we want to run them in main
|
101
120
|
directory of the tool (**javacore-analyser** directory, not **test** directory).
|
@@ -0,0 +1,15 @@
|
|
1
|
+
#
|
2
|
+
# Copyright IBM Corp. 2024 - 2024
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
4
|
+
#
|
5
|
+
|
6
|
+
FROM python:3
|
7
|
+
|
8
|
+
EXPOSE 5000/tcp
|
9
|
+
ENV REPORTS_DIR=/reports
|
10
|
+
RUN mkdir /reports
|
11
|
+
VOLUME ["/reports"]
|
12
|
+
|
13
|
+
RUN pip install --no-cache-dir javacore-analyser
|
14
|
+
|
15
|
+
CMD [ "javacore_analyser_web" ]
|
@@ -1,10 +1,10 @@
|
|
1
|
-
Metadata-Version: 2.
|
1
|
+
Metadata-Version: 2.4
|
2
2
|
Name: javacore_analyser
|
3
|
-
Version: 2.
|
3
|
+
Version: 2.1
|
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
|
7
|
-
Project-URL: Changelog, https://github.com/IBM/javacore-analyser/CHANGELOG.md
|
7
|
+
Project-URL: Changelog, https://github.com/IBM/javacore-analyser/blob/main/CHANGELOG.md
|
8
8
|
Project-URL: Source, https://github.com/IBM/javacore-analyser
|
9
9
|
Author-email: Krzysztof Kazmierczyk <kazm@ibm.com>, Piotr Aniola <Piotr.Aniola@ibm.com>, Tadeusz Janasiewicz <t.janasiewicz@ibm.com>
|
10
10
|
License: Apache License
|
@@ -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,20 +227,30 @@ 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
|
|
238
239
|
<!-- This should be the location of the title of the repository, normally the short name -->
|
239
240
|
# Javacore Analyser
|
240
241
|
|
242
|
+
![GitHub License](https://img.shields.io/github/license/IBM/javacore-analyser)
|
243
|
+
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/javacore-analyser)
|
244
|
+
![GitHub contributors](https://img.shields.io/github/contributors/IBM/javacore-analyser)
|
241
245
|
<!-- Build Status, is a great thing to have at the top of your repository, it shows that you take your CI/CD as first class citizens -->
|
242
246
|
[![Build Status](https://app.travis-ci.com/IBM/javacore-analyser.svg?token=w3i4X11XppEi2tJQsxDb&branch=main)](https://app.travis-ci.com/IBM/javacore-analyser)
|
247
|
+
![GitHub last commit](https://img.shields.io/github/last-commit/IBM/javacore-analyser)
|
248
|
+
![GitHub Release Date](https://img.shields.io/github/release-date/IBM/javacore-analyser)
|
249
|
+
![GitHub commit activity](https://img.shields.io/github/commit-activity/t/IBM/javacore-analyser)
|
250
|
+
![GitHub Issues or Pull Requests](https://img.shields.io/github/issues-pr/IBM/javacore-analyser)
|
251
|
+
![GitHub Issues or Pull Requests](https://img.shields.io/github/issues-pr-closed/IBM/javacore-analyser)
|
252
|
+
![PyPI - Downloads](https://img.shields.io/pypi/dm/javacore-analyser)
|
253
|
+
|
243
254
|
|
244
255
|
<!-- Not always needed, but a scope helps the user understand in a short sentance like below, why this repo exists -->
|
245
256
|
## Scope
|
@@ -266,7 +277,7 @@ Steps:
|
|
266
277
|
3. Run the following command:
|
267
278
|
`pip install javacore-analyser`
|
268
279
|
OR
|
269
|
-
`pip install --extra-index-url https://test.pypi.org/simple/ javacore-analyser` - if you want an experimental version
|
280
|
+
`pip install --pre --extra-index-url https://test.pypi.org/simple/ javacore-analyser` - if you want an experimental version
|
270
281
|
|
271
282
|
#### Installing from sources
|
272
283
|
This is recommended for geeks only:
|
@@ -280,29 +291,44 @@ This is recommended for geeks only:
|
|
280
291
|
#### Running cmd application:
|
281
292
|
1. Install application if not done yet
|
282
293
|
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
|
-
|
285
|
-
|
294
|
+
3. Run the following command from cmd:
|
295
|
+
`javacore-analyser-batch <input-data> <generated-reports-dir>`
|
296
|
+
or
|
297
|
+
`python -m javacore_analyser batch <input-data> <generated-reports-dir>`
|
298
|
+
|
286
299
|
Where `<input-data>` is one of the following:
|
287
300
|
* The directory containing javacores and optionally verbose gc
|
288
301
|
* Archive (7z, zip, tar.gz, tar.bz2) containing the same
|
289
302
|
* List of the javacores separated by `;` character. Optionally you can add `--separator` option to define your own separator.
|
290
303
|
You can type the following command to obtain the help:
|
291
|
-
`javacore-analyser-batch --help`
|
304
|
+
`javacore-analyser-batch --help` or `python -m javacore_analyser barch --help`
|
292
305
|
|
293
306
|
#### Running web application:
|
294
307
|
1. Repeat steps 1-3 from cmd application
|
295
|
-
2.
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
|
308
|
+
2. Execute the following command from cmd:
|
309
|
+
`javacore_analyser_web --port=5000 --reports-dir=/data/reports_dir`
|
310
|
+
or
|
311
|
+
`python -m javacore_analyser web --port=5000 --reports-dir=/data/reports_dir`
|
312
|
+
|
313
|
+
The first parameter set the port to use by application. If not specified, 5000 will be used.
|
314
|
+
The second parameter sets where the reports need to be stored. If not set, then the `reports` dir will be created in current location.
|
315
|
+
|
316
|
+
Now you can type (http://localhost:5000/).
|
317
|
+
|
318
|
+
### Running container image
|
319
|
+
There is an unofficial Docker/Podman container managed by one of projects developers. Use the following command
|
320
|
+
to start it:
|
321
|
+
|
322
|
+
`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`
|
323
|
+
|
324
|
+
or
|
325
|
+
`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`
|
326
|
+
|
327
|
+
The `mount` option specifies where you want locally to store the reports. The reports in the container are stored in
|
328
|
+
`/reports` directory. If you remove mount option, the application will work but the reports will not persist after
|
329
|
+
restart.
|
330
|
+
The application is running in the container on port 5000. By using `-p 5001:5000` option, you specify to map container
|
331
|
+
port 5000 to port 5001 on your machine. Therefore the application will be available under `http://localhost:5001/`.
|
306
332
|
|
307
333
|
<!-- The following are OPTIONAL, but strongly suggested to have in your repository. -->
|
308
334
|
<!--
|
@@ -1,8 +1,18 @@
|
|
1
1
|
<!-- This should be the location of the title of the repository, normally the short name -->
|
2
2
|
# Javacore Analyser
|
3
3
|
|
4
|
+
![GitHub License](https://img.shields.io/github/license/IBM/javacore-analyser)
|
5
|
+
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/javacore-analyser)
|
6
|
+
![GitHub contributors](https://img.shields.io/github/contributors/IBM/javacore-analyser)
|
4
7
|
<!-- Build Status, is a great thing to have at the top of your repository, it shows that you take your CI/CD as first class citizens -->
|
5
8
|
[![Build Status](https://app.travis-ci.com/IBM/javacore-analyser.svg?token=w3i4X11XppEi2tJQsxDb&branch=main)](https://app.travis-ci.com/IBM/javacore-analyser)
|
9
|
+
![GitHub last commit](https://img.shields.io/github/last-commit/IBM/javacore-analyser)
|
10
|
+
![GitHub Release Date](https://img.shields.io/github/release-date/IBM/javacore-analyser)
|
11
|
+
![GitHub commit activity](https://img.shields.io/github/commit-activity/t/IBM/javacore-analyser)
|
12
|
+
![GitHub Issues or Pull Requests](https://img.shields.io/github/issues-pr/IBM/javacore-analyser)
|
13
|
+
![GitHub Issues or Pull Requests](https://img.shields.io/github/issues-pr-closed/IBM/javacore-analyser)
|
14
|
+
![PyPI - Downloads](https://img.shields.io/pypi/dm/javacore-analyser)
|
15
|
+
|
6
16
|
|
7
17
|
<!-- Not always needed, but a scope helps the user understand in a short sentance like below, why this repo exists -->
|
8
18
|
## Scope
|
@@ -29,7 +39,7 @@ Steps:
|
|
29
39
|
3. Run the following command:
|
30
40
|
`pip install javacore-analyser`
|
31
41
|
OR
|
32
|
-
`pip install --extra-index-url https://test.pypi.org/simple/ javacore-analyser` - if you want an experimental version
|
42
|
+
`pip install --pre --extra-index-url https://test.pypi.org/simple/ javacore-analyser` - if you want an experimental version
|
33
43
|
|
34
44
|
#### Installing from sources
|
35
45
|
This is recommended for geeks only:
|
@@ -43,29 +53,44 @@ This is recommended for geeks only:
|
|
43
53
|
#### Running cmd application:
|
44
54
|
1. Install application if not done yet
|
45
55
|
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)
|
46
|
-
3.
|
47
|
-
|
48
|
-
|
56
|
+
3. Run the following command from cmd:
|
57
|
+
`javacore-analyser-batch <input-data> <generated-reports-dir>`
|
58
|
+
or
|
59
|
+
`python -m javacore_analyser batch <input-data> <generated-reports-dir>`
|
60
|
+
|
49
61
|
Where `<input-data>` is one of the following:
|
50
62
|
* The directory containing javacores and optionally verbose gc
|
51
63
|
* Archive (7z, zip, tar.gz, tar.bz2) containing the same
|
52
64
|
* List of the javacores separated by `;` character. Optionally you can add `--separator` option to define your own separator.
|
53
65
|
You can type the following command to obtain the help:
|
54
|
-
`javacore-analyser-batch --help`
|
66
|
+
`javacore-analyser-batch --help` or `python -m javacore_analyser barch --help`
|
55
67
|
|
56
68
|
#### Running web application:
|
57
69
|
1. Repeat steps 1-3 from cmd application
|
58
|
-
2.
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
70
|
+
2. Execute the following command from cmd:
|
71
|
+
`javacore_analyser_web --port=5000 --reports-dir=/data/reports_dir`
|
72
|
+
or
|
73
|
+
`python -m javacore_analyser web --port=5000 --reports-dir=/data/reports_dir`
|
74
|
+
|
75
|
+
The first parameter set the port to use by application. If not specified, 5000 will be used.
|
76
|
+
The second parameter sets where the reports need to be stored. If not set, then the `reports` dir will be created in current location.
|
77
|
+
|
78
|
+
Now you can type (http://localhost:5000/).
|
79
|
+
|
80
|
+
### Running container image
|
81
|
+
There is an unofficial Docker/Podman container managed by one of projects developers. Use the following command
|
82
|
+
to start it:
|
83
|
+
|
84
|
+
`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`
|
85
|
+
|
86
|
+
or
|
87
|
+
`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`
|
88
|
+
|
89
|
+
The `mount` option specifies where you want locally to store the reports. The reports in the container are stored in
|
90
|
+
`/reports` directory. If you remove mount option, the application will work but the reports will not persist after
|
91
|
+
restart.
|
92
|
+
The application is running in the container on port 5000. By using `-p 5001:5000` option, you specify to map container
|
93
|
+
port 5000 to port 5001 on your machine. Therefore the application will be available under `http://localhost:5001/`.
|
69
94
|
|
70
95
|
<!-- The following are OPTIONAL, but strongly suggested to have in your repository. -->
|
71
96
|
<!--
|
@@ -8,9 +8,9 @@ requires = ["hatchling", "versioningit"]
|
|
8
8
|
build-backend = "hatchling.build"
|
9
9
|
|
10
10
|
[project]
|
11
|
-
|
11
|
+
dynamic = ["version"]
|
12
12
|
name = "javacore_analyser"
|
13
|
-
version = "2.0rc1"
|
13
|
+
#version = "2.0rc1"
|
14
14
|
authors = [
|
15
15
|
{ name="Krzysztof Kazmierczyk", email="kazm@ibm.com" },
|
16
16
|
{ name="Piotr Aniola", email="Piotr.Aniola@ibm.com" },
|
@@ -40,13 +40,13 @@ classifiers = [
|
|
40
40
|
"Natural Language :: English",
|
41
41
|
]
|
42
42
|
dependencies = [
|
43
|
-
"dicttoxml",
|
44
43
|
"py7zr",
|
45
44
|
"lxml",
|
46
45
|
"pyana",
|
47
46
|
"importlib-resources",
|
48
47
|
"flask",
|
49
|
-
"waitress"
|
48
|
+
"waitress",
|
49
|
+
"tqdm"
|
50
50
|
]
|
51
51
|
|
52
52
|
[project.scripts]
|
@@ -56,7 +56,7 @@ javacore_analyser_web="javacore_analyser.javacore_analyser_web:main"
|
|
56
56
|
[project.urls]
|
57
57
|
Homepage = "https://github.com/IBM/javacore-analyser"
|
58
58
|
Issues = "https://github.com/IBM/javacore-analyser/issues"
|
59
|
-
Changelog = "https://github.com/IBM/javacore-analyser/CHANGELOG.md"
|
59
|
+
Changelog = "https://github.com/IBM/javacore-analyser/blob/main/CHANGELOG.md"
|
60
60
|
Source = "https://github.com/IBM/javacore-analyser"
|
61
61
|
|
62
62
|
[tool.hatch.version]
|
@@ -0,0 +1,43 @@
|
|
1
|
+
#
|
2
|
+
# Copyright IBM Corp. 2024 - 2024
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
4
|
+
#
|
5
|
+
import argparse
|
6
|
+
|
7
|
+
from javacore_analyser import javacore_analyser_batch, constants, javacore_analyser_web
|
8
|
+
|
9
|
+
|
10
|
+
def main():
|
11
|
+
parser = argparse.ArgumentParser(prog="python -m javacore_analyser")
|
12
|
+
subparsers = parser.add_subparsers(dest="type", help="Application type", required=True)
|
13
|
+
|
14
|
+
batch = subparsers.add_parser("batch", description="Run batch application")
|
15
|
+
batch.add_argument("input", help="Input file(s) or directory")
|
16
|
+
batch.add_argument("output", help="Destination report directory")
|
17
|
+
batch.add_argument("--separator", default=constants.DEFAULT_FILE_DELIMITER)
|
18
|
+
|
19
|
+
web = subparsers.add_parser("web", description="Run web application")
|
20
|
+
web.add_argument("--debug", help="Debug mode. Use True only for app development", default=False)
|
21
|
+
web.add_argument("--port", help="Application port", default=constants.DEFAULT_PORT)
|
22
|
+
web.add_argument("--reports-dir", help="Directory to store reports data",
|
23
|
+
default=constants.DEFAULT_REPORTS_DIR)
|
24
|
+
|
25
|
+
args = parser.parse_args()
|
26
|
+
|
27
|
+
app_type: str = args.type
|
28
|
+
|
29
|
+
if app_type.lower() == "web":
|
30
|
+
print("Running web application")
|
31
|
+
javacore_analyser_web.run_web(args.debug, args.port, args.reports_dir)
|
32
|
+
elif app_type.lower() == "batch":
|
33
|
+
print("Running batch application")
|
34
|
+
javacore_analyser_batch.batch_process(args.input, args.output, args.separator)
|
35
|
+
else:
|
36
|
+
print('Invalid application type. Available types: "batch" or "web"')
|
37
|
+
|
38
|
+
|
39
|
+
if __name__ == '__main__':
|
40
|
+
# This is the code to be able to run the app from command line.
|
41
|
+
# Try this:
|
42
|
+
# python -m javacore_analyser -h
|
43
|
+
main()
|
@@ -59,7 +59,7 @@ class AbstractSnapshotCollection(abc.ABC):
|
|
59
59
|
self.thread_snapshots.append(snapshot)
|
60
60
|
|
61
61
|
def index_of(self, snapshot):
|
62
|
-
for i in range(len(self.
|
62
|
+
for i in range(len(self.thread_snapshots)):
|
63
63
|
if self.thread_snapshots[i] == snapshot: return i
|
64
64
|
return -1
|
65
65
|
|
@@ -142,7 +142,7 @@ class AbstractSnapshotCollection(abc.ABC):
|
|
142
142
|
result = 0
|
143
143
|
for i in self.thread_snapshots:
|
144
144
|
el = i.get_java_stack_depth()
|
145
|
-
if el>result:
|
145
|
+
if el > result:
|
146
146
|
result = el
|
147
147
|
return result
|
148
148
|
|
@@ -30,10 +30,11 @@ ENCODING = '1TICHARSET'
|
|
30
30
|
DATA_OUTPUT_SUBDIR = '/data/'
|
31
31
|
DEFAULT_FILE_DELIMITER = ';'
|
32
32
|
|
33
|
-
MIN_JAVACORE_SIZE = 5 * 1024
|
33
|
+
MIN_JAVACORE_SIZE = 5 * 1024 # Minimal Javacore size in bytes
|
34
34
|
|
35
35
|
DATE_FORMAT = "%Y-%m-%d %H:%M:%S"
|
36
36
|
|
37
37
|
# Web application constants
|
38
38
|
DEFAULT_REPORTS_DIR = "reports"
|
39
39
|
DEFAULT_PORT = 5000
|
40
|
+
TEMP_DIR = "temp_data" # Folder to store temporary data for creating reports
|
@@ -0,0 +1,17 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
|
3
|
+
<!--
|
4
|
+
# Copyright IBM Corp. 2024 - 2024
|
5
|
+
# SPDX-License-Identifier: Apache-2.0
|
6
|
+
-->
|
7
|
+
|
8
|
+
<html lang="en">
|
9
|
+
<head>
|
10
|
+
<meta http-equiv="refresh" content="30" /> <!-- Refresh this page every 30s until generated page appears -->
|
11
|
+
<meta charset="UTF-8">
|
12
|
+
<title>The page is being generated</title>
|
13
|
+
</head>
|
14
|
+
<body>
|
15
|
+
<h1>The page is being generated. Once it is ready, it will appear here.</h1>
|
16
|
+
</body>
|
17
|
+
</html>
|
{javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/search.js
RENAMED
@@ -49,10 +49,32 @@ $(function() {
|
|
49
49
|
searchInNode(rootNode, searchTerm);
|
50
50
|
}
|
51
51
|
|
52
|
+
function processChild(child) {
|
53
|
+
try {
|
54
|
+
if (isDomNode(child) && child.classList.contains('toggle_expand')) {
|
55
|
+
for (i = 0; i < child.childNodes.length; ++i) {
|
56
|
+
grandchild = child.childNodes[i];
|
57
|
+
if (isDomNode(grandchild) && grandchild.text == '[+] Expand') {
|
58
|
+
grandchild.text = '[-] Collapse';
|
59
|
+
}
|
60
|
+
}
|
61
|
+
}
|
62
|
+
} catch(err) {
|
63
|
+
console.log(err);
|
64
|
+
}
|
65
|
+
}
|
66
|
+
|
52
67
|
function searchInNode(node, searchTerm) {
|
53
68
|
if (!isDomNode(node)) return;
|
54
69
|
if (node.textContent.toUpperCase().match(searchTerm.toUpperCase())) {
|
55
70
|
// expand the node here
|
71
|
+
if (!node.classList.contains('show-all')) {
|
72
|
+
node.classList.add('show-all');
|
73
|
+
for (i = 0; i < node.childNodes.length; ++i) {
|
74
|
+
child = node.childNodes[i];
|
75
|
+
processChild(child);
|
76
|
+
}
|
77
|
+
}
|
56
78
|
if (node.getAttribute('style') && node.style.display == "none") {
|
57
79
|
node.style.display = "";
|
58
80
|
}
|
{javacore_analyser-2.0rc1 → javacore_analyser-2.1}/src/javacore_analyser/data/jquery/wait2scripts.js
RENAMED
@@ -99,7 +99,9 @@ const loadChartGC = function() {
|
|
99
99
|
}
|
100
100
|
|
101
101
|
const sysResourceE3Elem = document.getElementById('systemresources_myChartGC');
|
102
|
-
sysResourceE3Elem
|
102
|
+
if (sysResourceE3Elem) {
|
103
|
+
sysResourceE3Elem.classList.remove('hide');
|
104
|
+
}
|
103
105
|
|
104
106
|
const ctx = document.getElementById('myChartGC');
|
105
107
|
|
@@ -125,7 +127,7 @@ const loadChartGC = function() {
|
|
125
127
|
startingPoint = timestamp;
|
126
128
|
|
127
129
|
if(endingPoint < timestamp)
|
128
|
-
endingPoint
|
130
|
+
endingPoint = timestamp;
|
129
131
|
}
|
130
132
|
|
131
133
|
coresTimeRange['startTime'] = startingPoint;
|
@@ -145,12 +147,34 @@ const loadChartGC = function() {
|
|
145
147
|
});
|
146
148
|
|
147
149
|
// 3. find the HEAP_SIZE
|
148
|
-
const MB_SIZE = Math.pow(1024, 2)
|
150
|
+
const MB_SIZE = Math.pow(1024, 2);
|
151
|
+
let heapAsString = document.getElementById('sys_info_table').rows[2].cells[1].innerHTML;
|
149
152
|
let HEAP_SIZE;
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
153
|
+
let heapUnit = heapAsString.slice(-1).toLowerCase();
|
154
|
+
|
155
|
+
if(!isNaN(Number(heapUnit))) {
|
156
|
+
HEAP_SIZE = Number(heapAsString);
|
157
|
+
}
|
158
|
+
else {
|
159
|
+
|
160
|
+
switch (heapUnit) {
|
161
|
+
case "g":
|
162
|
+
HEAP_SIZE =
|
163
|
+
Number(heapAsString.slice(0, -1)) * MB_SIZE * 1024;
|
164
|
+
break;
|
165
|
+
case "m":
|
166
|
+
HEAP_SIZE =
|
167
|
+
Number(heapAsString.slice(0, -1)) * MB_SIZE;
|
168
|
+
break;
|
169
|
+
case "k":
|
170
|
+
HEAP_SIZE =
|
171
|
+
Number(heapAsString.slice(0, -1)) * 1024;
|
172
|
+
break;
|
173
|
+
default:
|
174
|
+
console.log("Hmm, what now .. heap unit undefined!");
|
175
|
+
break;
|
176
|
+
}
|
177
|
+
}
|
154
178
|
|
155
179
|
// 4. create input data for GC chart
|
156
180
|
// start with gc collection done after the first javacore creation
|