mirror of
https://github.com/openjdk/jdk.git
synced 2026-02-09 01:48:34 +00:00
8297164: Update troff man pages and CheckManPageOptions.java
Reviewed-by: dholmes
This commit is contained in:
parent
f12710e938
commit
5a45c25151
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -19,39 +19,49 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "RMIREGISTRY" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "RMIREGISTRY" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
rmiregistry \- create and start a remote object registry on the
|
||||
specified port on the current host
|
||||
rmiregistry - create and start a remote object registry on the specified
|
||||
port on the current host
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]rmiregistry\f[R] [\f[I]options\f[R]] [\f[I]port\f[R]]
|
||||
\f[V]rmiregistry\f[R] [\f[I]options\f[R]] [\f[I]port\f[R]]
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
This represents the option for the \f[CB]rmiregistry\f[R] command.
|
||||
\f[I]options\f[R]
|
||||
This represents the option for the \f[V]rmiregistry\f[R] command.
|
||||
See \f[B]Options\f[R]
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]port\f[R]
|
||||
\f[I]port\f[R]
|
||||
The number of a port on the current host at which to start the remote
|
||||
object registry.
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]rmiregistry\f[R] command creates and starts a remote object
|
||||
The \f[V]rmiregistry\f[R] command creates and starts a remote object
|
||||
registry on the specified port on the current host.
|
||||
If the port is omitted, then the registry is started on port 1099.
|
||||
The \f[CB]rmiregistry\f[R] command produces no output and is typically run
|
||||
in the background, for example:
|
||||
The \f[V]rmiregistry\f[R] command produces no output and is typically
|
||||
run in the background, for example:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]rmiregistry\ &\f[R]
|
||||
\f[V]rmiregistry &\f[R]
|
||||
.RE
|
||||
.PP
|
||||
A remote object registry is a bootstrap naming service that\[aq]s used
|
||||
@ -61,14 +71,14 @@ make remote method invocations.
|
||||
.PP
|
||||
The registry is typically used to locate the first remote object on
|
||||
which an application needs to call methods.
|
||||
That object then provides application\-specific support for finding
|
||||
other objects.
|
||||
That object then provides application-specific support for finding other
|
||||
objects.
|
||||
.PP
|
||||
The methods of the \f[CB]java.rmi.registry.LocateRegistry\f[R] class are
|
||||
The methods of the \f[V]java.rmi.registry.LocateRegistry\f[R] class are
|
||||
used to get a registry operating on the local host or local host and
|
||||
port.
|
||||
.PP
|
||||
The URL\-based methods of the \f[CB]java.rmi.Naming\f[R] class operate on
|
||||
The URL-based methods of the \f[V]java.rmi.Naming\f[R] class operate on
|
||||
a registry and can be used to:
|
||||
.IP \[bu] 2
|
||||
Bind the specified name to a remote object
|
||||
@ -84,9 +94,7 @@ Destroy the binding for the specified name that\[aq]s associated with a
|
||||
remote object
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.B \f[CB]\-J\f[R]\f[I]option\f[R]
|
||||
\f[V]-J\f[R]\f[I]option\f[R]
|
||||
Used with any Java option to pass the \f[I]option\f[R] following the
|
||||
\f[CB]\-J\f[R] (no spaces between the \f[CB]\-J\f[R] and the option) to the
|
||||
\f[V]-J\f[R] (no spaces between the \f[V]-J\f[R] and the option) to the
|
||||
Java interpreter.
|
||||
.RS
|
||||
.RE
|
||||
|
||||
@ -19,13 +19,27 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JRUNSCRIPT" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JRUNSCRIPT" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jrunscript \- run a command\-line script shell that supports interactive
|
||||
jrunscript - run a command-line script shell that supports interactive
|
||||
and batch modes
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
@ -33,143 +47,119 @@ and batch modes
|
||||
.PP
|
||||
This tool is \f[B]experimental\f[R] and unsupported.
|
||||
.PP
|
||||
\f[CB]jrunscript\f[R] [\f[I]options\f[R]] [\f[I]arguments\f[R]]
|
||||
\f[V]jrunscript\f[R] [\f[I]options\f[R]] [\f[I]arguments\f[R]]
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
This represents the \f[CB]jrunscript\f[R] command\-line options that can
|
||||
\f[I]options\f[R]
|
||||
This represents the \f[V]jrunscript\f[R] command-line options that can
|
||||
be used.
|
||||
See \f[B]Options for the jrunscript Command\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]arguments\f[R]
|
||||
\f[I]arguments\f[R]
|
||||
Arguments, when used, follow immediately after options or the command
|
||||
name.
|
||||
See \f[B]Arguments\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jrunscript\f[R] command is a language\-independent command\-line
|
||||
The \f[V]jrunscript\f[R] command is a language-independent command-line
|
||||
script shell.
|
||||
The \f[CB]jrunscript\f[R] command supports both an interactive
|
||||
(read\-eval\-print) mode and a batch (\f[CB]\-f\f[R] option) mode of
|
||||
script execution.
|
||||
By default, JavaScript is the language used, but the \f[CB]\-l\f[R] option
|
||||
The \f[V]jrunscript\f[R] command supports both an interactive
|
||||
(read-eval-print) mode and a batch (\f[V]-f\f[R] option) mode of script
|
||||
execution.
|
||||
By default, JavaScript is the language used, but the \f[V]-l\f[R] option
|
||||
can be used to specify a different language.
|
||||
By using Java to scripting language communication, the
|
||||
\f[CB]jrunscript\f[R] command supports an exploratory programming style.
|
||||
\f[V]jrunscript\f[R] command supports an exploratory programming style.
|
||||
.PP
|
||||
If JavaScript is used, then before it evaluates a user defined script,
|
||||
the \f[CB]jrunscript\f[R] command initializes certain built\-in functions
|
||||
the \f[V]jrunscript\f[R] command initializes certain built-in functions
|
||||
and objects, which are documented in the API Specification for
|
||||
\f[CB]jrunscript\f[R] JavaScript built\-in functions.
|
||||
\f[V]jrunscript\f[R] JavaScript built-in functions.
|
||||
.SH OPTIONS FOR THE JRUNSCRIPT COMMAND
|
||||
.TP
|
||||
.B \f[CB]\-cp\f[R] \f[I]path\f[R] or \f[CB]\-classpath\f[R] \f[I]path\f[R]
|
||||
\f[V]-cp\f[R] \f[I]path\f[R] or \f[V]-classpath\f[R] \f[I]path\f[R]
|
||||
Indicates where any class files are that the script needs to access.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-D\f[R]\f[I]name\f[R]\f[CB]=\f[R]\f[I]value\f[R]
|
||||
\f[V]-D\f[R]\f[I]name\f[R]\f[V]=\f[R]\f[I]value\f[R]
|
||||
Sets a Java system property.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-J\f[R]\f[I]flag\f[R]
|
||||
\f[V]-J\f[R]\f[I]flag\f[R]
|
||||
Passes \f[I]flag\f[R] directly to the Java Virtual Machine where the
|
||||
\f[CB]jrunscript\f[R] command is running.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]jrunscript\f[R] command is running.
|
||||
.TP
|
||||
.B \f[CB]\-l\f[R] \f[I]language\f[R]
|
||||
\f[V]-l\f[R] \f[I]language\f[R]
|
||||
Uses the specified scripting language.
|
||||
By default, JavaScript is used.
|
||||
To use other scripting languages, you must specify the corresponding
|
||||
script engine\[aq]s JAR file with the \f[CB]\-cp\f[R] or
|
||||
\f[CB]\-classpath\f[R] option.
|
||||
.RS
|
||||
.RE
|
||||
script engine\[aq]s JAR file with the \f[V]-cp\f[R] or
|
||||
\f[V]-classpath\f[R] option.
|
||||
.TP
|
||||
.B \f[CB]\-e\f[R] \f[I]script\f[R]
|
||||
\f[V]-e\f[R] \f[I]script\f[R]
|
||||
Evaluates the specified script.
|
||||
This option can be used to run one\-line scripts that are specified
|
||||
This option can be used to run one-line scripts that are specified
|
||||
completely on the command line.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-encoding\f[R] \f[I]encoding\f[R]
|
||||
\f[V]-encoding\f[R] \f[I]encoding\f[R]
|
||||
Specifies the character encoding used to read script files.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-f\f[R] \f[I]script\-file\f[R]
|
||||
\f[V]-f\f[R] \f[I]script-file\f[R]
|
||||
Evaluates the specified script file (batch mode).
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-f\ \-\f[R]
|
||||
\f[V]-f -\f[R]
|
||||
Enters interactive mode to read and evaluate a script from standard
|
||||
input.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-help\f[R] or \f[CB]\-?\f[R]
|
||||
\f[V]-help\f[R] or \f[V]-?\f[R]
|
||||
Displays a help message and exits.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-q\f[R]
|
||||
\f[V]-q\f[R]
|
||||
Lists all script engines available and exits.
|
||||
.RS
|
||||
.RE
|
||||
.SH ARGUMENTS
|
||||
.PP
|
||||
If arguments are present and if no \f[CB]\-e\f[R] or \f[CB]\-f\f[R] option
|
||||
If arguments are present and if no \f[V]-e\f[R] or \f[V]-f\f[R] option
|
||||
is used, then the first argument is the script file and the rest of the
|
||||
arguments, if any, are passed as script arguments.
|
||||
If arguments and the \f[CB]\-e\f[R] or the \f[CB]\-f\f[R] option are used,
|
||||
If arguments and the \f[V]-e\f[R] or the \f[V]-f\f[R] option are used,
|
||||
then all arguments are passed as script arguments.
|
||||
If arguments \f[CB]\-e\f[R] and \f[CB]\-f\f[R] are missing, then the
|
||||
If arguments \f[V]-e\f[R] and \f[V]-f\f[R] are missing, then the
|
||||
interactive mode is used.
|
||||
.SH EXAMPLE OF EXECUTING INLINE SCRIPTS
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jrunscript\ \-e\ "print(\[aq]hello\ world\[aq])"\f[R]
|
||||
\f[V]jrunscript -e \[dq]print(\[aq]hello world\[aq])\[dq]\f[R]
|
||||
.RE
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jrunscript\ \-e\ "cat(\[aq]http://www.example.com\[aq])"\f[R]
|
||||
\f[V]jrunscript -e \[dq]cat(\[aq]http://www.example.com\[aq])\[dq]\f[R]
|
||||
.RE
|
||||
.SH EXAMPLE OF USING SPECIFIED LANGUAGE AND EVALUATE THE SCRIPT FILE
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jrunscript\ \-l\ js\ \-f\ test.js\f[R]
|
||||
\f[V]jrunscript -l js -f test.js\f[R]
|
||||
.RE
|
||||
.SH EXAMPLE OF INTERACTIVE MODE
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jrunscript
|
||||
js>\ print(\[aq]Hello\ World\\n\[aq]);
|
||||
Hello\ World
|
||||
js>\ 34\ +\ 55
|
||||
js> print(\[aq]Hello World\[rs]n\[aq]);
|
||||
Hello World
|
||||
js> 34 + 55
|
||||
89.0
|
||||
js>\ t\ =\ new\ java.lang.Thread(function()\ {\ print(\[aq]Hello\ World\\n\[aq]);\ })
|
||||
Thread[Thread\-0,5,main]
|
||||
js>\ t.start()
|
||||
js>\ Hello\ World
|
||||
js> t = new java.lang.Thread(function() { print(\[aq]Hello World\[rs]n\[aq]); })
|
||||
Thread[Thread-0,5,main]
|
||||
js> t.start()
|
||||
js> Hello World
|
||||
|
||||
js>
|
||||
\f[R]
|
||||
.fi
|
||||
.SH RUN SCRIPT FILE WITH SCRIPT ARGUMENTS
|
||||
.PP
|
||||
In this example, the \f[CB]test.js\f[R] file is the script file.
|
||||
The \f[CB]arg1\f[R], \f[CB]arg2\f[R], and \f[CB]arg3\f[R] arguments are passed
|
||||
to the script.
|
||||
In this example, the \f[V]test.js\f[R] file is the script file.
|
||||
The \f[V]arg1\f[R], \f[V]arg2\f[R], and \f[V]arg3\f[R] arguments are
|
||||
passed to the script.
|
||||
The script can access these arguments with an arguments array.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jrunscript\ test.js\ arg1\ arg2\ arg3\f[R]
|
||||
\f[V]jrunscript test.js arg1 arg2 arg3\f[R]
|
||||
.RE
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -19,66 +19,72 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "SERIALVER" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "SERIALVER" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
serialver \- return the \f[CB]serialVersionUID\f[R] for one or more
|
||||
serialver - return the \f[V]serialVersionUID\f[R] for one or more
|
||||
classes in a form suitable for copying into an evolving class
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]serialver\f[R] [\f[I]options\f[R]] [\f[I]classnames\f[R]]
|
||||
\f[V]serialver\f[R] [\f[I]options\f[R]] [\f[I]classnames\f[R]]
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
This represents the command\-line options for the \f[CB]serialver\f[R]
|
||||
\f[I]options\f[R]
|
||||
This represents the command-line options for the \f[V]serialver\f[R]
|
||||
command.
|
||||
See \f[B]Options for serialver\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]classnames\f[R]
|
||||
The classes for which \f[CB]serialVersionUID\f[R] is to be returned.
|
||||
.RS
|
||||
.RE
|
||||
\f[I]classnames\f[R]
|
||||
The classes for which \f[V]serialVersionUID\f[R] is to be returned.
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]serialver\f[R] command returns the \f[CB]serialVersionUID\f[R] for
|
||||
one or more classes in a form suitable for copying into an evolving
|
||||
The \f[V]serialver\f[R] command returns the \f[V]serialVersionUID\f[R]
|
||||
for one or more classes in a form suitable for copying into an evolving
|
||||
class.
|
||||
When called with no arguments, the \f[CB]serialver\f[R] command prints a
|
||||
When called with no arguments, the \f[V]serialver\f[R] command prints a
|
||||
usage line.
|
||||
.SH OPTIONS FOR SERIALVER
|
||||
.TP
|
||||
.B \f[CB]\-classpath\f[R] \f[I]path\-files\f[R]
|
||||
\f[V]-classpath\f[R] \f[I]path-files\f[R]
|
||||
Sets the search path for application classes and resources.
|
||||
Separate classes and resources with a colon (:).
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-J\f[R]\f[I]option\f[R]
|
||||
\f[V]-J\f[R]\f[I]option\f[R]
|
||||
Passes the specified \f[I]option\f[R] to the Java Virtual Machine, where
|
||||
\f[I]option\f[R] is one of the options described on the reference page
|
||||
for the Java application launcher.
|
||||
For example, \f[CB]\-J\-Xms48m\f[R] sets the startup memory to 48 MB.
|
||||
.RS
|
||||
.RE
|
||||
For example, \f[V]-J-Xms48m\f[R] sets the startup memory to 48 MB.
|
||||
.SH NOTES
|
||||
.PP
|
||||
The \f[CB]serialver\f[R] command loads and initializes the specified
|
||||
The \f[V]serialver\f[R] command loads and initializes the specified
|
||||
classes in its virtual machine, and by default, it doesn\[aq]t set a
|
||||
security manager.
|
||||
If the \f[CB]serialver\f[R] command is to be run with untrusted classes,
|
||||
If the \f[V]serialver\f[R] command is to be run with untrusted classes,
|
||||
then a security manager can be set with the following option:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]\-J\-Djava.security.manager\f[R]
|
||||
\f[V]-J-Djava.security.manager\f[R]
|
||||
.RE
|
||||
.PP
|
||||
When necessary, a security policy can be specified with the following
|
||||
option:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]\-J\-Djava.security.policy=\f[R]\f[I]policy_file\f[R]
|
||||
\f[V]-J-Djava.security.policy=\f[R]\f[I]policy_file\f[R]
|
||||
.RE
|
||||
|
||||
@ -19,242 +19,196 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JHSDB" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JHSDB" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jhsdb \- attach to a Java process or launch a postmortem debugger to
|
||||
jhsdb - attach to a Java process or launch a postmortem debugger to
|
||||
analyze the content of a core dump from a crashed Java Virtual Machine
|
||||
(JVM)
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]jhsdb\f[R] \f[CB]clhsdb\f[R] [\f[CB]\-\-pid\f[R] \f[I]pid\f[R] |
|
||||
\f[CB]\-\-exe\f[R] \f[I]executable\f[R] \f[CB]\-\-core\f[R]
|
||||
\f[V]jhsdb\f[R] \f[V]clhsdb\f[R] [\f[V]--pid\f[R] \f[I]pid\f[R] |
|
||||
\f[V]--exe\f[R] \f[I]executable\f[R] \f[V]--core\f[R]
|
||||
\f[I]coredump\f[R]]
|
||||
.PP
|
||||
\f[CB]jhsdb\f[R] \f[CB]hsdb\f[R] [\f[CB]\-\-pid\f[R] \f[I]pid\f[R] |
|
||||
\f[CB]\-\-exe\f[R] \f[I]executable\f[R] \f[CB]\-\-core\f[R]
|
||||
\f[V]jhsdb\f[R] \f[V]hsdb\f[R] [\f[V]--pid\f[R] \f[I]pid\f[R] |
|
||||
\f[V]--exe\f[R] \f[I]executable\f[R] \f[V]--core\f[R]
|
||||
\f[I]coredump\f[R]]
|
||||
.PP
|
||||
\f[CB]jhsdb\f[R] \f[CB]debugd\f[R] (\f[CB]\-\-pid\f[R] \f[I]pid\f[R] |
|
||||
\f[CB]\-\-exe\f[R] \f[I]executable\f[R] \f[CB]\-\-core\f[R]
|
||||
\f[V]jhsdb\f[R] \f[V]debugd\f[R] (\f[V]--pid\f[R] \f[I]pid\f[R] |
|
||||
\f[V]--exe\f[R] \f[I]executable\f[R] \f[V]--core\f[R]
|
||||
\f[I]coredump\f[R]) [\f[I]options\f[R]]
|
||||
.PP
|
||||
\f[CB]jhsdb\f[R] \f[CB]jstack\f[R] (\f[CB]\-\-pid\f[R] \f[I]pid\f[R] |
|
||||
\f[CB]\-\-exe\f[R] \f[I]executable\f[R] \f[CB]\-\-core\f[R] \f[I]coredump\f[R]
|
||||
| \f[CB]\-\-connect\f[R] \f[I][server\-id\@]debugd\-host\f[R])
|
||||
\f[V]jhsdb\f[R] \f[V]jstack\f[R] (\f[V]--pid\f[R] \f[I]pid\f[R] |
|
||||
\f[V]--exe\f[R] \f[I]executable\f[R] \f[V]--core\f[R] \f[I]coredump\f[R]
|
||||
| \f[V]--connect\f[R] \f[I][server-id\[at]]debugd-host\f[R])
|
||||
[\f[I]options\f[R]]
|
||||
.PP
|
||||
\f[CB]jhsdb\f[R] \f[CB]jmap\f[R] (\f[CB]\-\-pid\f[R] \f[I]pid\f[R] |
|
||||
\f[CB]\-\-exe\f[R] \f[I]executable\f[R] \f[CB]\-\-core\f[R] \f[I]coredump\f[R]
|
||||
| \f[CB]\-\-connect\f[R] \f[I][server\-id\@]debugd\-host\f[R])
|
||||
\f[V]jhsdb\f[R] \f[V]jmap\f[R] (\f[V]--pid\f[R] \f[I]pid\f[R] |
|
||||
\f[V]--exe\f[R] \f[I]executable\f[R] \f[V]--core\f[R] \f[I]coredump\f[R]
|
||||
| \f[V]--connect\f[R] \f[I][server-id\[at]]debugd-host\f[R])
|
||||
[\f[I]options\f[R]]
|
||||
.PP
|
||||
\f[CB]jhsdb\f[R] \f[CB]jinfo\f[R] (\f[CB]\-\-pid\f[R] \f[I]pid\f[R] |
|
||||
\f[CB]\-\-exe\f[R] \f[I]executable\f[R] \f[CB]\-\-core\f[R] \f[I]coredump\f[R]
|
||||
| \f[CB]\-\-connect\f[R] \f[I][server\-id\@]debugd\-host\f[R])
|
||||
\f[V]jhsdb\f[R] \f[V]jinfo\f[R] (\f[V]--pid\f[R] \f[I]pid\f[R] |
|
||||
\f[V]--exe\f[R] \f[I]executable\f[R] \f[V]--core\f[R] \f[I]coredump\f[R]
|
||||
| \f[V]--connect\f[R] \f[I][server-id\[at]]debugd-host\f[R])
|
||||
[\f[I]options\f[R]]
|
||||
.PP
|
||||
\f[CB]jhsdb\f[R] \f[CB]jsnap\f[R] (\f[CB]\-\-pid\f[R] \f[I]pid\f[R] |
|
||||
\f[CB]\-\-exe\f[R] \f[I]executable\f[R] \f[CB]\-\-core\f[R] \f[I]coredump\f[R]
|
||||
| \f[CB]\-\-connect\f[R] \f[I][server\-id\@]debugd\-host\f[R])
|
||||
\f[V]jhsdb\f[R] \f[V]jsnap\f[R] (\f[V]--pid\f[R] \f[I]pid\f[R] |
|
||||
\f[V]--exe\f[R] \f[I]executable\f[R] \f[V]--core\f[R] \f[I]coredump\f[R]
|
||||
| \f[V]--connect\f[R] \f[I][server-id\[at]]debugd-host\f[R])
|
||||
[\f[I]options\f[R]]
|
||||
.TP
|
||||
.B \f[I]pid\f[R]
|
||||
The process ID to which the \f[CB]jhsdb\f[R] tool should attach.
|
||||
\f[I]pid\f[R]
|
||||
The process ID to which the \f[V]jhsdb\f[R] tool should attach.
|
||||
The process must be a Java process.
|
||||
To get a list of Java processes running on a machine, use the
|
||||
\f[CB]ps\f[R] command or, if the JVM processes are not running in a
|
||||
\f[V]ps\f[R] command or, if the JVM processes are not running in a
|
||||
separate docker instance, the \f[B]jps\f[R] command.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]executable\f[R]
|
||||
\f[I]executable\f[R]
|
||||
The Java executable file from which the core dump was produced.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]coredump\f[R]
|
||||
The core file to which the \f[CB]jhsdb\f[R] tool should attach.
|
||||
.RS
|
||||
.RE
|
||||
\f[I]coredump\f[R]
|
||||
The core file to which the \f[V]jhsdb\f[R] tool should attach.
|
||||
.TP
|
||||
.B \f[I][server\-id\@]debugd\-host\f[R]
|
||||
\f[I][server-id\[at]]debugd-host\f[R]
|
||||
An optional server ID and the address of the remote debug server
|
||||
(debugd).
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
The command\-line options for a \f[CB]jhsdb\f[R] mode.
|
||||
\f[I]options\f[R]
|
||||
The command-line options for a \f[V]jhsdb\f[R] mode.
|
||||
See \f[B]Options for the debugd Mode\f[R], \f[B]Options for the jstack
|
||||
Mode\f[R], \f[B]Options for the jmap Mode\f[R], \f[B]Options for the jinfo
|
||||
Mode\f[R], and \f[B]Options for the jsnap Mode\f[R].
|
||||
.RS
|
||||
.RE
|
||||
Mode\f[R], \f[B]Options for the jmap Mode\f[R], \f[B]Options for the
|
||||
jinfo Mode\f[R], and \f[B]Options for the jsnap Mode\f[R].
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
Either the \f[I]pid\f[R] or the pair of \f[I]executable\f[R] and
|
||||
\f[I]core\f[R] files or the \f[I][server\-id\@]debugd\-host\f[R] must be
|
||||
provided for \f[CB]debugd\f[R], \f[CB]jstack\f[R], \f[CB]jmap\f[R],
|
||||
\f[CB]jinfo\f[R] and \f[CB]jsnap\f[R] modes.
|
||||
\f[I]core\f[R] files or the \f[I][server-id\[at]]debugd-host\f[R] must
|
||||
be provided for \f[V]debugd\f[R], \f[V]jstack\f[R], \f[V]jmap\f[R],
|
||||
\f[V]jinfo\f[R] and \f[V]jsnap\f[R] modes.
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
You can use the \f[CB]jhsdb\f[R] tool to attach to a Java process or to
|
||||
launch a postmortem debugger to analyze the content of a core\-dump from
|
||||
You can use the \f[V]jhsdb\f[R] tool to attach to a Java process or to
|
||||
launch a postmortem debugger to analyze the content of a core-dump from
|
||||
a crashed Java Virtual Machine (JVM).
|
||||
This command is experimental and unsupported.
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
Attaching the \f[CB]jhsdb\f[R] tool to a live process will cause the
|
||||
Attaching the \f[V]jhsdb\f[R] tool to a live process will cause the
|
||||
process to hang and the process will probably crash when the debugger
|
||||
detaches.
|
||||
.PP
|
||||
The \f[CB]jhsdb\f[R] tool can be launched in any one of the following
|
||||
The \f[V]jhsdb\f[R] tool can be launched in any one of the following
|
||||
modes:
|
||||
.TP
|
||||
.B \f[CB]jhsdb\ clhsdb\f[R]
|
||||
Starts the interactive command\-line debugger.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]jhsdb clhsdb\f[R]
|
||||
Starts the interactive command-line debugger.
|
||||
.TP
|
||||
.B \f[CB]jhsdb\ hsdb\f[R]
|
||||
\f[V]jhsdb hsdb\f[R]
|
||||
Starts the interactive GUI debugger.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]jhsdb\ debugd\f[R]
|
||||
\f[V]jhsdb debugd\f[R]
|
||||
Starts the remote debug server.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]jhsdb\ jstack\f[R]
|
||||
\f[V]jhsdb jstack\f[R]
|
||||
Prints stack and locks information.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]jhsdb\ jmap\f[R]
|
||||
\f[V]jhsdb jmap\f[R]
|
||||
Prints heap information.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]jhsdb\ jinfo\f[R]
|
||||
\f[V]jhsdb jinfo\f[R]
|
||||
Prints basic JVM information.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]jhsdb\ jsnap\f[R]
|
||||
\f[V]jhsdb jsnap\f[R]
|
||||
Prints performance counter information.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]jhsdb\f[R] \f[I]command\f[R] \f[CB]\-\-help\f[R]
|
||||
\f[V]jhsdb\f[R] \f[I]command\f[R] \f[V]--help\f[R]
|
||||
Displays the options available for the \f[I]command\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.SH OPTIONS FOR THE DEBUGD MODE
|
||||
.TP
|
||||
.B \f[CB]\-\-serverid\f[R] \f[I]server\-id\f[R]
|
||||
\f[V]--serverid\f[R] \f[I]server-id\f[R]
|
||||
An optional unique ID for this debug server.
|
||||
This is required if multiple debug servers are run on the same machine.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-rmiport\f[R] \f[I]port\f[R]
|
||||
\f[V]--rmiport\f[R] \f[I]port\f[R]
|
||||
Sets the port number to which the RMI connector is bound.
|
||||
If not specified a random available port is used.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-registryport\f[R] \f[I]port\f[R]
|
||||
\f[V]--registryport\f[R] \f[I]port\f[R]
|
||||
Sets the RMI registry port.
|
||||
This option overrides the system property
|
||||
\[aq]sun.jvm.hotspot.rmi.port\[aq].
|
||||
If not specified, the system property is used.
|
||||
If the system property is not set, the default port 1099 is used.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-hostname\f[R] \f[I]hostname\f[R]
|
||||
\f[V]--hostname\f[R] \f[I]hostname\f[R]
|
||||
Sets the hostname the RMI connector is bound.
|
||||
The value could be a hostname or an IPv4/IPv6 address.
|
||||
This option overrides the system property
|
||||
\[aq]java.rmi.server.hostname\[aq].
|
||||
If not specified, the system property is used.
|
||||
If the system property is not set, a system hostname is used.
|
||||
.RS
|
||||
.RE
|
||||
.SH OPTIONS FOR THE JINFO MODE
|
||||
.TP
|
||||
.B \f[CB]\-\-flags\f[R]
|
||||
\f[V]--flags\f[R]
|
||||
Prints the VM flags.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-sysprops\f[R]
|
||||
\f[V]--sysprops\f[R]
|
||||
Prints the Java system properties.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B no option
|
||||
no option
|
||||
Prints the VM flags and the Java system properties.
|
||||
.RS
|
||||
.RE
|
||||
.SH OPTIONS FOR THE JMAP MODE
|
||||
.TP
|
||||
.B no option
|
||||
Prints the same information as Solaris \f[CB]pmap\f[R].
|
||||
.RS
|
||||
.RE
|
||||
no option
|
||||
Prints the same information as Solaris \f[V]pmap\f[R].
|
||||
.TP
|
||||
.B \f[CB]\-\-heap\f[R]
|
||||
Prints the \f[CB]java\f[R] heap summary.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--heap\f[R]
|
||||
Prints the \f[V]java\f[R] heap summary.
|
||||
.TP
|
||||
.B \f[CB]\-\-binaryheap\f[R]
|
||||
Dumps the \f[CB]java\f[R] heap in \f[CB]hprof\f[R] binary format.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--binaryheap\f[R]
|
||||
Dumps the \f[V]java\f[R] heap in \f[V]hprof\f[R] binary format.
|
||||
.TP
|
||||
.B \f[CB]\-\-dumpfile\f[R] \f[I]name\f[R]
|
||||
\f[V]--dumpfile\f[R] \f[I]name\f[R]
|
||||
The name of the dumpfile.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-histo\f[R]
|
||||
Prints the histogram of \f[CB]java\f[R] object heap.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--histo\f[R]
|
||||
Prints the histogram of \f[V]java\f[R] object heap.
|
||||
.TP
|
||||
.B \f[CB]\-\-clstats\f[R]
|
||||
\f[V]--clstats\f[R]
|
||||
Prints the class loader statistics.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-finalizerinfo\f[R]
|
||||
\f[V]--finalizerinfo\f[R]
|
||||
Prints the information on objects awaiting finalization.
|
||||
.RS
|
||||
.RE
|
||||
.SH OPTIONS FOR THE JSTACK MODE
|
||||
.TP
|
||||
.B \f[CB]\-\-locks\f[R]
|
||||
Prints the \f[CB]java.util.concurrent\f[R] locks information.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--locks\f[R]
|
||||
Prints the \f[V]java.util.concurrent\f[R] locks information.
|
||||
.TP
|
||||
.B \f[CB]\-\-mixed\f[R]
|
||||
Attempts to print both \f[CB]java\f[R] and native frames if the platform
|
||||
\f[V]--mixed\f[R]
|
||||
Attempts to print both \f[V]java\f[R] and native frames if the platform
|
||||
allows it.
|
||||
.RS
|
||||
.RE
|
||||
.SH OPTIONS FOR THE JSNAP MODE
|
||||
.TP
|
||||
.B \f[CB]\-\-all\f[R]
|
||||
\f[V]--all\f[R]
|
||||
Prints all performance counters.
|
||||
.RS
|
||||
.RE
|
||||
|
||||
@ -19,32 +19,44 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JWEBSERVER" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JWEBSERVER" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jwebserver \- launch the Java Simple Web Server
|
||||
jwebserver - launch the Java Simple Web Server
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]jwebserver\f[R] [\f[I]options\f[R]]
|
||||
\f[V]jwebserver\f[R] [\f[I]options\f[R]]
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
Command\-line options.
|
||||
\f[I]options\f[R]
|
||||
Command-line options.
|
||||
For a detailed description of the options, see \f[B]Options\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jwebserver\f[R] tool provides a minimal HTTP server, designed to
|
||||
be used for prototyping, testing, and debugging.
|
||||
The \f[V]jwebserver\f[R] tool provides a minimal HTTP server, designed
|
||||
to be used for prototyping, testing, and debugging.
|
||||
It serves a single directory hierarchy, and only serves static files.
|
||||
Only HTTP/1.1 is supported; HTTP/2 and HTTPS are not supported.
|
||||
.PP
|
||||
Only idempotent HEAD and GET requests are served.
|
||||
Any other requests receive a \f[CB]501\ \-\ Not\ Implemented\f[R] or a
|
||||
\f[CB]405\ \-\ Not\ Allowed\f[R] response.
|
||||
Any other requests receive a \f[V]501 - Not Implemented\f[R] or a
|
||||
\f[V]405 - Not Allowed\f[R] response.
|
||||
GET requests are mapped to the directory being served, as follows:
|
||||
.IP \[bu] 2
|
||||
If the requested resource is a file, its content is served.
|
||||
@ -56,103 +68,88 @@ Otherwise, the names of all files and subdirectories of the directory
|
||||
are listed.
|
||||
Symbolic links and hidden files are not listed or served.
|
||||
.PP
|
||||
MIME types are configured automatically, using the built\-in table.
|
||||
For example, \f[CB]\&.html\f[R] files are served as \f[CB]text/html\f[R] and
|
||||
\f[CB]\&.java\f[R] files are served as \f[CB]text/plain\f[R].
|
||||
MIME types are configured automatically, using the built-in table.
|
||||
For example, \f[V].html\f[R] files are served as \f[V]text/html\f[R] and
|
||||
\f[V].java\f[R] files are served as \f[V]text/plain\f[R].
|
||||
.PP
|
||||
\f[CB]jwebserver\f[R] is located in the jdk.httpserver module, and can
|
||||
alternatively be started with \f[CB]java\ \-m\ jdk.httpserver\f[R].
|
||||
\f[V]jwebserver\f[R] is located in the jdk.httpserver module, and can
|
||||
alternatively be started with \f[V]java -m jdk.httpserver\f[R].
|
||||
It is based on the web server implementation in the
|
||||
\f[CB]com.sun.net.httpserver\f[R] package.
|
||||
The \f[CB]com.sun.net.httpserver.SimpleFileServer\f[R] class provides a
|
||||
\f[V]com.sun.net.httpserver\f[R] package.
|
||||
The \f[V]com.sun.net.httpserver.SimpleFileServer\f[R] class provides a
|
||||
programmatic way to retrieve the server and its components for reuse and
|
||||
extension.
|
||||
.SH USAGE
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jwebserver\ [\-b\ bind\ address]\ [\-p\ port]\ [\-d\ directory]
|
||||
\ \ \ \ \ \ \ \ \ \ \ [\-o\ none|info|verbose]\ [\-h\ to\ show\ options]
|
||||
\ \ \ \ \ \ \ \ \ \ \ [\-version\ to\ show\ version\ information]
|
||||
jwebserver [-b bind address] [-p port] [-d directory]
|
||||
[-o none|info|verbose] [-h to show options]
|
||||
[-version to show version information]
|
||||
\f[R]
|
||||
.fi
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.B \f[CB]\-h\f[R] or \f[CB]\-?\f[R] or \f[CB]\-\-help\f[R]
|
||||
\f[V]-h\f[R] or \f[V]-?\f[R] or \f[V]--help\f[R]
|
||||
Prints the help message and exits.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-b\f[R] \f[I]addr\f[R] or \f[CB]\-\-bind\-address\f[R] \f[I]addr\f[R]
|
||||
\f[V]-b\f[R] \f[I]addr\f[R] or \f[V]--bind-address\f[R] \f[I]addr\f[R]
|
||||
Specifies the address to bind to.
|
||||
Default: 127.0.0.1 or ::1 (loopback).
|
||||
For all interfaces use \f[CB]\-b\ 0.0.0.0\f[R] or \f[CB]\-b\ ::\f[R].
|
||||
.RS
|
||||
.RE
|
||||
For all interfaces use \f[V]-b 0.0.0.0\f[R] or \f[V]-b ::\f[R].
|
||||
.TP
|
||||
.B \f[CB]\-d\f[R] \f[I]dir\f[R] or \f[CB]\-\-directory\f[R] \f[I]dir\f[R]
|
||||
\f[V]-d\f[R] \f[I]dir\f[R] or \f[V]--directory\f[R] \f[I]dir\f[R]
|
||||
Specifies the directory to serve.
|
||||
Default: current directory.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-o\f[R] \f[I]level\f[R] or \f[CB]\-\-output\f[R] \f[I]level\f[R]
|
||||
\f[V]-o\f[R] \f[I]level\f[R] or \f[V]--output\f[R] \f[I]level\f[R]
|
||||
Specifies the output format.
|
||||
\f[CB]none\f[R] | \f[CB]info\f[R] | \f[CB]verbose\f[R].
|
||||
Default: \f[CB]info\f[R].
|
||||
.RS
|
||||
.RE
|
||||
\f[V]none\f[R] | \f[V]info\f[R] | \f[V]verbose\f[R].
|
||||
Default: \f[V]info\f[R].
|
||||
.TP
|
||||
.B \f[CB]\-p\f[R] \f[I]port\f[R] or \f[CB]\-\-port\f[R] \f[I]port\f[R]
|
||||
\f[V]-p\f[R] \f[I]port\f[R] or \f[V]--port\f[R] \f[I]port\f[R]
|
||||
Specifies the port to listen on.
|
||||
Default: 8000.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-version\f[R] or \f[CB]\-\-version\f[R]
|
||||
\f[V]-version\f[R] or \f[V]--version\f[R]
|
||||
Prints the version information and exits.
|
||||
.RS
|
||||
.RE
|
||||
.PP
|
||||
To stop the server, press \f[CB]Ctrl\ +\ C\f[R].
|
||||
To stop the server, press \f[V]Ctrl + C\f[R].
|
||||
.SH STARTING THE SERVER
|
||||
.PP
|
||||
The following command starts the Simple Web Server:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
$\ jwebserver
|
||||
$ jwebserver
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
If startup is successful, the server prints a message to
|
||||
\f[CB]System.out\f[R] listing the local address and the absolute path of
|
||||
\f[V]System.out\f[R] listing the local address and the absolute path of
|
||||
the directory being served.
|
||||
For example:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
$\ jwebserver
|
||||
Binding\ to\ loopback\ by\ default.\ For\ all\ interfaces\ use\ "\-b\ 0.0.0.0"\ or\ "\-b\ ::".
|
||||
Serving\ /cwd\ and\ subdirectories\ on\ 127.0.0.1\ port\ 8000
|
||||
URL\ http://127.0.0.1:8000/
|
||||
$ jwebserver
|
||||
Binding to loopback by default. For all interfaces use \[dq]-b 0.0.0.0\[dq] or \[dq]-b ::\[dq].
|
||||
Serving /cwd and subdirectories on 127.0.0.1 port 8000
|
||||
URL http://127.0.0.1:8000/
|
||||
\f[R]
|
||||
.fi
|
||||
.SH CONFIGURATION
|
||||
.PP
|
||||
By default, the server runs in the foreground and binds to the loopback
|
||||
address and port 8000.
|
||||
This can be changed with the \f[CB]\-b\f[R] and \f[CB]\-p\f[R] options.
|
||||
.PD 0
|
||||
.P
|
||||
.PD
|
||||
This can be changed with the \f[V]-b\f[R] and \f[V]-p\f[R] options.
|
||||
For example, to bind the Simple Web Server to all interfaces, use:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
$\ jwebserver\ \-b\ 0.0.0.0
|
||||
Serving\ /cwd\ and\ subdirectories\ on\ 0.0.0.0\ (all\ interfaces)\ port\ 8000
|
||||
URL\ http://123.456.7.891:8000/
|
||||
$ jwebserver -b 0.0.0.0
|
||||
Serving /cwd and subdirectories on 0.0.0.0 (all interfaces) port 8000
|
||||
URL http://123.456.7.891:8000/
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
@ -165,32 +162,32 @@ As another example, use the following command to run on port 9000:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
$\ jwebserver\ \-p\ 9000
|
||||
$ jwebserver -p 9000
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
By default, the files of the current directory are served.
|
||||
A different directory can be specified with the \f[CB]\-d\f[R] option.
|
||||
A different directory can be specified with the \f[V]-d\f[R] option.
|
||||
.PP
|
||||
By default, every request is logged on the console.
|
||||
The output looks like this:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
127.0.0.1\ \-\ \-\ [10/Feb/2021:14:34:11\ +0000]\ "GET\ /some/subdirectory/\ HTTP/1.1"\ 200\ \-
|
||||
127.0.0.1 - - [10/Feb/2021:14:34:11 +0000] \[dq]GET /some/subdirectory/ HTTP/1.1\[dq] 200 -
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
Logging output can be changed with the \f[CB]\-o\f[R] option.
|
||||
The default setting is \f[CB]info\f[R].
|
||||
The \f[CB]verbose\f[R] setting additionally includes the request and
|
||||
Logging output can be changed with the \f[V]-o\f[R] option.
|
||||
The default setting is \f[V]info\f[R].
|
||||
The \f[V]verbose\f[R] setting additionally includes the request and
|
||||
response headers as well as the absolute path of the requested resource.
|
||||
.SH STOPPING THE SERVER
|
||||
.PP
|
||||
Once started successfully, the server runs until it is stopped.
|
||||
On Unix platforms, the server can be stopped by sending it a
|
||||
\f[CB]SIGINT\f[R] signal (\f[CB]Ctrl+C\f[R] in a terminal window).
|
||||
\f[V]SIGINT\f[R] signal (\f[V]Ctrl+C\f[R] in a terminal window).
|
||||
.SH HELP OPTION
|
||||
.PP
|
||||
The \f[CB]\-h\f[R] option displays a help message describing the usage and
|
||||
the options of the \f[CB]jwebserver\f[R].
|
||||
The \f[V]-h\f[R] option displays a help message describing the usage and
|
||||
the options of the \f[V]jwebserver\f[R].
|
||||
|
||||
@ -19,30 +19,46 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JAR" "1" "2022" "JDK 20\-internal" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JAR" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jar \- create an archive for classes and resources, and manipulate or
|
||||
jar - create an archive for classes and resources, and manipulate or
|
||||
restore individual classes or resources from an archive
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]jar\f[R] [\f[I]OPTION\f[R] ...] [ [\f[CB]\-\-release\f[R]
|
||||
\f[I]VERSION\f[R]] [\f[CB]\-C\f[R] \f[I]dir\f[R]] \f[I]files\f[R]] ...
|
||||
\f[V]jar\f[R] [\f[I]OPTION\f[R] ...]
|
||||
[ [\f[V]--release\f[R] \f[I]VERSION\f[R]] [\f[V]-C\f[R] \f[I]dir\f[R]]
|
||||
\f[I]files\f[R]] ...
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jar\f[R] command is a general\-purpose archiving and compression
|
||||
The \f[V]jar\f[R] command is a general-purpose archiving and compression
|
||||
tool, based on the ZIP and ZLIB compression formats.
|
||||
Initially, the \f[CB]jar\f[R] command was designed to package Java applets
|
||||
(not supported since JDK 11) or applications; however, beginning with
|
||||
JDK 9, users can use the \f[CB]jar\f[R] command to create modular JARs.
|
||||
Initially, the \f[V]jar\f[R] command was designed to package Java
|
||||
applets (not supported since JDK 11) or applications; however, beginning
|
||||
with JDK 9, users can use the \f[V]jar\f[R] command to create modular
|
||||
JARs.
|
||||
For transportation and deployment, it\[aq]s usually more convenient to
|
||||
package modules as modular JARs.
|
||||
.PP
|
||||
The syntax for the \f[CB]jar\f[R] command resembles the syntax for the
|
||||
\f[CB]tar\f[R] command.
|
||||
The syntax for the \f[V]jar\f[R] command resembles the syntax for the
|
||||
\f[V]tar\f[R] command.
|
||||
It has several main operation modes, defined by one of the mandatory
|
||||
operation arguments.
|
||||
Other arguments are either options that modify the behavior of the
|
||||
@ -53,25 +69,25 @@ sounds) are combined into a single archive, they can be downloaded by a
|
||||
Java agent (such as a browser) in a single HTTP transaction, rather than
|
||||
requiring a new connection for each piece.
|
||||
This dramatically improves download times.
|
||||
The \f[CB]jar\f[R] command also compresses files, which further improves
|
||||
The \f[V]jar\f[R] command also compresses files, which further improves
|
||||
download time.
|
||||
The \f[CB]jar\f[R] command also enables individual entries in a file to be
|
||||
signed so that their origin can be authenticated.
|
||||
The \f[V]jar\f[R] command also enables individual entries in a file to
|
||||
be signed so that their origin can be authenticated.
|
||||
A JAR file can be used as a class path entry, whether or not it\[aq]s
|
||||
compressed.
|
||||
.PP
|
||||
An archive becomes a modular JAR when you include a module descriptor,
|
||||
\f[CB]module\-info.class\f[R], in the root of the given directories or in
|
||||
the root of the \f[CB]\&.jar\f[R] archive.
|
||||
\f[V]module-info.class\f[R], in the root of the given directories or in
|
||||
the root of the \f[V].jar\f[R] archive.
|
||||
The following operations described in \f[B]Operation Modifiers Valid
|
||||
Only in Create and Update Modes\f[R] are valid only when creating or
|
||||
updating a modular jar or updating an existing non\-modular jar:
|
||||
updating a modular jar or updating an existing non-modular jar:
|
||||
.IP \[bu] 2
|
||||
\f[CB]\-\-module\-version\f[R]
|
||||
\f[V]--module-version\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]\-\-hash\-modules\f[R]
|
||||
\f[V]--hash-modules\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]\-\-module\-path\f[R]
|
||||
\f[V]--module-path\f[R]
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
@ -79,285 +95,245 @@ All mandatory or optional arguments for long options are also mandatory
|
||||
or optional for any corresponding short options.
|
||||
.SH MAIN OPERATION MODES
|
||||
.PP
|
||||
When using the \f[CB]jar\f[R] command, you must specify the operation for
|
||||
When using the \f[V]jar\f[R] command, you must specify the operation for
|
||||
it to perform.
|
||||
You specify the operation mode for the \f[CB]jar\f[R] command by including
|
||||
the appropriate operation arguments described in this section.
|
||||
You can mix an operation argument with other one\-letter options.
|
||||
You specify the operation mode for the \f[V]jar\f[R] command by
|
||||
including the appropriate operation arguments described in this section.
|
||||
You can mix an operation argument with other one-letter options.
|
||||
Generally the operation argument is the first argument specified on the
|
||||
command line.
|
||||
.TP
|
||||
.B \f[CB]\-c\f[R] or \f[CB]\-\-create\f[R]
|
||||
\f[V]-c\f[R] or \f[V]--create\f[R]
|
||||
Creates the archive.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-i\f[R] \f[I]FILE\f[R] or \f[CB]\-\-generate\-index=\f[R]\f[I]FILE\f[R]
|
||||
\f[V]-i\f[R] \f[I]FILE\f[R] or \f[V]--generate-index=\f[R]\f[I]FILE\f[R]
|
||||
Generates index information for the specified JAR file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-t\f[R] or \f[CB]\-\-list\f[R]
|
||||
\f[V]-t\f[R] or \f[V]--list\f[R]
|
||||
Lists the table of contents for the archive.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-u\f[R] or \f[CB]\-\-update\f[R]
|
||||
\f[V]-u\f[R] or \f[V]--update\f[R]
|
||||
Updates an existing JAR file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-x\f[R] or \f[CB]\-\-extract\f[R]
|
||||
\f[V]-x\f[R] or \f[V]--extract\f[R]
|
||||
Extracts the named (or all) files from the archive.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-d\f[R] or \f[CB]\-\-describe\-module\f[R]
|
||||
\f[V]-d\f[R] or \f[V]--describe-module\f[R]
|
||||
Prints the module descriptor or automatic module name.
|
||||
.RS
|
||||
.RE
|
||||
.SH OPERATION MODIFIERS VALID IN ANY MODE
|
||||
.PP
|
||||
You can use the following options to customize the actions of any
|
||||
operation mode included in the \f[CB]jar\f[R] command.
|
||||
operation mode included in the \f[V]jar\f[R] command.
|
||||
.TP
|
||||
.B \f[CB]\-C\f[R] \f[I]DIR\f[R]
|
||||
\f[V]-C\f[R] \f[I]DIR\f[R]
|
||||
Changes the specified directory and includes the \f[I]files\f[R]
|
||||
specified at the end of the command line.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jar\f[R] [\f[I]OPTION\f[R] ...] [ [\f[CB]\-\-release\f[R]
|
||||
\f[I]VERSION\f[R]] [\f[CB]\-C\f[R] \f[I]dir\f[R]] \f[I]files\f[R]]
|
||||
\f[V]jar\f[R] [\f[I]OPTION\f[R] ...]
|
||||
[ [\f[V]--release\f[R] \f[I]VERSION\f[R]] [\f[V]-C\f[R] \f[I]dir\f[R]]
|
||||
\f[I]files\f[R]]
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-f\f[R] \f[I]FILE\f[R] or \f[CB]\-\-file=\f[R]\f[I]FILE\f[R]
|
||||
\f[V]-f\f[R] \f[I]FILE\f[R] or \f[V]--file=\f[R]\f[I]FILE\f[R]
|
||||
Specifies the archive file name.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-release\f[R] \f[I]VERSION\f[R]
|
||||
\f[V]--release\f[R] \f[I]VERSION\f[R]
|
||||
Creates a multirelease JAR file.
|
||||
Places all files specified after the option into a versioned directory
|
||||
of the JAR file named
|
||||
\f[CB]META\-INF/versions/\f[R]\f[I]VERSION\f[R]\f[CB]/\f[R], where
|
||||
\f[V]META-INF/versions/\f[R]\f[I]VERSION\f[R]\f[V]/\f[R], where
|
||||
\f[I]VERSION\f[R] must be must be a positive integer whose value is 9 or
|
||||
greater.
|
||||
.RS
|
||||
.PP
|
||||
At run time, where more than one version of a class exists in the JAR,
|
||||
the JDK will use the first one it finds, searching initially in the
|
||||
directory tree whose \f[I]VERSION\f[R] number matches the JDK\[aq]s major
|
||||
version number.
|
||||
directory tree whose \f[I]VERSION\f[R] number matches the JDK\[aq]s
|
||||
major version number.
|
||||
It will then look in directories with successively lower
|
||||
\f[I]VERSION\f[R] numbers, and finally look in the root of the JAR.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-v\f[R] or \f[CB]\-\-verbose\f[R]
|
||||
\f[V]-v\f[R] or \f[V]--verbose\f[R]
|
||||
Sends or prints verbose output to standard output.
|
||||
.RS
|
||||
.RE
|
||||
.SH OPERATION MODIFIERS VALID ONLY IN CREATE AND UPDATE MODES
|
||||
.PP
|
||||
You can use the following options to customize the actions of the create
|
||||
and the update main operation modes:
|
||||
.TP
|
||||
.B \f[CB]\-e\f[R] \f[I]CLASSNAME\f[R] or \f[CB]\-\-main\-class=\f[R]\f[I]CLASSNAME\f[R]
|
||||
\f[V]-e\f[R] \f[I]CLASSNAME\f[R] or \f[V]--main-class=\f[R]\f[I]CLASSNAME\f[R]
|
||||
Specifies the application entry point for standalone applications
|
||||
bundled into a modular or executable modular JAR file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-m\f[R] \f[I]FILE\f[R] or \f[CB]\-\-manifest=\f[R]\f[I]FILE\f[R]
|
||||
\f[V]-m\f[R] \f[I]FILE\f[R] or \f[V]--manifest=\f[R]\f[I]FILE\f[R]
|
||||
Includes the manifest information from the given manifest file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-M\f[R] or \f[CB]\-\-no\-manifest\f[R]
|
||||
\f[V]-M\f[R] or \f[V]--no-manifest\f[R]
|
||||
Doesn\[aq]t create a manifest file for the entries.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-module\-version=\f[R]\f[I]VERSION\f[R]
|
||||
\f[V]--module-version=\f[R]\f[I]VERSION\f[R]
|
||||
Specifies the module version, when creating or updating a modular JAR
|
||||
file, or updating a non\-modular JAR file.
|
||||
.RS
|
||||
.RE
|
||||
file, or updating a non-modular JAR file.
|
||||
.TP
|
||||
.B \f[CB]\-\-hash\-modules=\f[R]\f[I]PATTERN\f[R]
|
||||
\f[V]--hash-modules=\f[R]\f[I]PATTERN\f[R]
|
||||
Computes and records the hashes of modules matched by the given pattern
|
||||
and that depend upon directly or indirectly on a modular JAR file being
|
||||
created or a non\-modular JAR file being updated.
|
||||
.RS
|
||||
.RE
|
||||
created or a non-modular JAR file being updated.
|
||||
.TP
|
||||
.B \f[CB]\-p\f[R] or \f[CB]\-\-module\-path\f[R]
|
||||
\f[V]-p\f[R] or \f[V]--module-path\f[R]
|
||||
Specifies the location of module dependence for generating the hash.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\@\f[R]\f[I]file\f[R]
|
||||
Reads \f[CB]jar\f[R] options and file names from a text file.
|
||||
.RS
|
||||
.RE
|
||||
.SH OPERATION MODIFIERS VALID ONLY IN CREATE, UPDATE, AND
|
||||
GENERATE\-INDEX MODES
|
||||
\f[V]\[at]\f[R]\f[I]file\f[R]
|
||||
Reads \f[V]jar\f[R] options and file names from a text file.
|
||||
.SH OPERATION MODIFIERS VALID ONLY IN CREATE, UPDATE, AND GENERATE-INDEX MODES
|
||||
.PP
|
||||
You can use the following options to customize the actions of the create
|
||||
(\f[CB]\-c\f[R] or \f[CB]\-\-create\f[R]) the update (\f[CB]\-u\f[R] or
|
||||
\f[CB]\-\-update\f[R] ) and the generate\-index (\f[CB]\-i\f[R] or
|
||||
\f[CB]\-\-generate\-index=\f[R]\f[I]FILE\f[R]) main operation modes:
|
||||
(\f[V]-c\f[R] or \f[V]--create\f[R]) the update (\f[V]-u\f[R] or
|
||||
\f[V]--update\f[R] ) and the generate-index (\f[V]-i\f[R] or
|
||||
\f[V]--generate-index=\f[R]\f[I]FILE\f[R]) main operation modes:
|
||||
.TP
|
||||
.B \f[CB]\-0\f[R] or \f[CB]\-\-no\-compress\f[R]
|
||||
\f[V]-0\f[R] or \f[V]--no-compress\f[R]
|
||||
Stores without using ZIP compression.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-date=\f[R]\f[I]TIMESTAMP\f[R]
|
||||
The timestamp in ISO\-8601 extended offset date\-time with optional
|
||||
time\-zone format, to use for the timestamp of the entries, e.g.
|
||||
"2022\-02\-12T12:30:00\-05:00".
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--date=\f[R]\f[I]TIMESTAMP\f[R]
|
||||
The timestamp in ISO-8601 extended offset date-time with optional
|
||||
time-zone format, to use for the timestamp of the entries, e.g.
|
||||
\[dq]2022-02-12T12:30:00-05:00\[dq].
|
||||
.SH OTHER OPTIONS
|
||||
.PP
|
||||
The following options are recognized by the \f[CB]jar\f[R] command and not
|
||||
used with operation modes:
|
||||
The following options are recognized by the \f[V]jar\f[R] command and
|
||||
not used with operation modes:
|
||||
.TP
|
||||
.B \f[CB]\-h\f[R] or \f[CB]\-\-help\f[R][\f[CB]:compat\f[R]]
|
||||
Displays the command\-line help for the \f[CB]jar\f[R] command or
|
||||
\f[V]-h\f[R] or \f[V]--help\f[R][\f[V]:compat\f[R]]
|
||||
Displays the command-line help for the \f[V]jar\f[R] command or
|
||||
optionally the compatibility help.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-help\-extra\f[R]
|
||||
\f[V]--help-extra\f[R]
|
||||
Displays help on extra options.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-version\f[R]
|
||||
\f[V]--version\f[R]
|
||||
Prints the program version.
|
||||
.RS
|
||||
.RE
|
||||
.SH EXAMPLES OF JAR COMMAND SYNTAX
|
||||
.IP \[bu] 2
|
||||
Create an archive, \f[CB]classes.jar\f[R], that contains two class files,
|
||||
\f[CB]Foo.class\f[R] and \f[CB]Bar.class\f[R].
|
||||
Create an archive, \f[V]classes.jar\f[R], that contains two class files,
|
||||
\f[V]Foo.class\f[R] and \f[V]Bar.class\f[R].
|
||||
.RS 2
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jar\ \-\-create\ \-\-file\ classes.jar\ Foo.class\ Bar.class\f[R]
|
||||
\f[V]jar --create --file classes.jar Foo.class Bar.class\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.IP \[bu] 2
|
||||
Create an archive, \f[CB]classes.jar\f[R], that contains two class files,
|
||||
\f[CB]Foo.class\f[R] and \f[CB]Bar.class\f[R] setting the last modified date
|
||||
and time to \f[CB]2021\ Jan\ 6\ 12:36:00\f[R].
|
||||
Create an archive, \f[V]classes.jar\f[R], that contains two class files,
|
||||
\f[V]Foo.class\f[R] and \f[V]Bar.class\f[R] setting the last modified
|
||||
date and time to \f[V]2021 Jan 6 12:36:00\f[R].
|
||||
.RS 2
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jar\ \-\-create\ \-\-date="2021\-01\-06T14:36:00+02:00"\ \-\-file=classes.jar\ Foo.class\ Bar.class\f[R]
|
||||
\f[V]jar --create --date=\[dq]2021-01-06T14:36:00+02:00\[dq] --file=classes.jar Foo.class Bar.class\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.IP \[bu] 2
|
||||
Create an archive, \f[CB]classes.jar\f[R], by using an existing manifest,
|
||||
\f[CB]mymanifest\f[R], that contains all of the files in the directory
|
||||
\f[CB]foo/\f[R].
|
||||
Create an archive, \f[V]classes.jar\f[R], by using an existing manifest,
|
||||
\f[V]mymanifest\f[R], that contains all of the files in the directory
|
||||
\f[V]foo/\f[R].
|
||||
.RS 2
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jar\ \-\-create\ \-\-file\ classes.jar\ \-\-manifest\ mymanifest\ \-C\ foo/\f[R]
|
||||
\f[V]jar --create --file classes.jar --manifest mymanifest -C foo/\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.IP \[bu] 2
|
||||
Create a modular JAR archive,\f[CB]foo.jar\f[R], where the module
|
||||
descriptor is located in \f[CB]classes/module\-info.class\f[R].
|
||||
Create a modular JAR archive,\f[V]foo.jar\f[R], where the module
|
||||
descriptor is located in \f[V]classes/module-info.class\f[R].
|
||||
.RS 2
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jar\ \-\-create\ \-\-file\ foo.jar\ \-\-main\-class\ com.foo.Main\ \-\-module\-version\ 1.0\ \-C\ foo/classes\ resources\f[R]
|
||||
\f[V]jar --create --file foo.jar --main-class com.foo.Main --module-version 1.0 -C foo/classes resources\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.IP \[bu] 2
|
||||
Update an existing non\-modular JAR, \f[CB]foo.jar\f[R], to a modular JAR
|
||||
Update an existing non-modular JAR, \f[V]foo.jar\f[R], to a modular JAR
|
||||
file.
|
||||
.RS 2
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jar\ \-\-update\ \-\-file\ foo.jar\ \-\-main\-class\ com.foo.Main\ \-\-module\-version\ 1.0\ \-C\ foo/module\-info.class\f[R]
|
||||
\f[V]jar --update --file foo.jar --main-class com.foo.Main --module-version 1.0 -C foo/module-info.class\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.IP \[bu] 2
|
||||
Create a versioned or multi\-release JAR, \f[CB]foo.jar\f[R], that places
|
||||
the files in the \f[CB]classes\f[R] directory at the root of the JAR, and
|
||||
the files in the \f[CB]classes\-10\f[R] directory in the
|
||||
\f[CB]META\-INF/versions/10\f[R] directory of the JAR.
|
||||
Create a versioned or multi-release JAR, \f[V]foo.jar\f[R], that places
|
||||
the files in the \f[V]classes\f[R] directory at the root of the JAR, and
|
||||
the files in the \f[V]classes-10\f[R] directory in the
|
||||
\f[V]META-INF/versions/10\f[R] directory of the JAR.
|
||||
.RS 2
|
||||
.PP
|
||||
In this example, the \f[CB]classes/com/foo\f[R] directory contains two
|
||||
classes, \f[CB]com.foo.Hello\f[R] (the entry point class) and
|
||||
\f[CB]com.foo.NameProvider\f[R], both compiled for JDK 8.
|
||||
The \f[CB]classes\-10/com/foo\f[R] directory contains a different version
|
||||
of the \f[CB]com.foo.NameProvider\f[R] class, this one containing JDK 10
|
||||
In this example, the \f[V]classes/com/foo\f[R] directory contains two
|
||||
classes, \f[V]com.foo.Hello\f[R] (the entry point class) and
|
||||
\f[V]com.foo.NameProvider\f[R], both compiled for JDK 8.
|
||||
The \f[V]classes-10/com/foo\f[R] directory contains a different version
|
||||
of the \f[V]com.foo.NameProvider\f[R] class, this one containing JDK 10
|
||||
specific code and compiled for JDK 10.
|
||||
.PP
|
||||
Given this setup, create a multirelease JAR file \f[CB]foo.jar\f[R] by
|
||||
Given this setup, create a multirelease JAR file \f[V]foo.jar\f[R] by
|
||||
running the following command from the directory containing the
|
||||
directories \f[CB]classes\f[R] and \f[CB]classes\-10\f[R] .
|
||||
directories \f[V]classes\f[R] and \f[V]classes-10\f[R] .
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jar\ \-\-create\ \-\-file\ foo.jar\ \-\-main\-class\ com.foo.Hello\ \-C\ classes\ .\ \-\-release\ 10\ \-C\ classes\-10\ .\f[R]
|
||||
\f[V]jar --create --file foo.jar --main-class com.foo.Hello -C classes . --release 10 -C classes-10 .\f[R]
|
||||
.RE
|
||||
.PP
|
||||
The JAR file \f[CB]foo.jar\f[R] now contains:
|
||||
The JAR file \f[V]foo.jar\f[R] now contains:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
%\ jar\ \-tf\ foo.jar
|
||||
% jar -tf foo.jar
|
||||
|
||||
META\-INF/
|
||||
META\-INF/MANIFEST.MF
|
||||
META-INF/
|
||||
META-INF/MANIFEST.MF
|
||||
com/
|
||||
com/foo/
|
||||
com/foo/Hello.class
|
||||
com/foo/NameProvider.class
|
||||
META\-INF/versions/10/com/
|
||||
META\-INF/versions/10/com/foo/
|
||||
META\-INF/versions/10/com/foo/NameProvider.class
|
||||
META-INF/versions/10/com/
|
||||
META-INF/versions/10/com/foo/
|
||||
META-INF/versions/10/com/foo/NameProvider.class
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
As well as other information, the file \f[CB]META\-INF/MANIFEST.MF\f[R],
|
||||
As well as other information, the file \f[V]META-INF/MANIFEST.MF\f[R],
|
||||
will contain the following lines to indicate that this is a multirelease
|
||||
JAR file with an entry point of \f[CB]com.foo.Hello\f[R].
|
||||
JAR file with an entry point of \f[V]com.foo.Hello\f[R].
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
\&...
|
||||
Main\-Class:\ com.foo.Hello
|
||||
Multi\-Release:\ true
|
||||
Main-Class: com.foo.Hello
|
||||
Multi-Release: true
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
Assuming that the \f[CB]com.foo.Hello\f[R] class calls a method on the
|
||||
\f[CB]com.foo.NameProvider\f[R] class, running the program using JDK 10
|
||||
will ensure that the \f[CB]com.foo.NameProvider\f[R] class is the one in
|
||||
\f[CB]META\-INF/versions/10/com/foo/\f[R].
|
||||
Assuming that the \f[V]com.foo.Hello\f[R] class calls a method on the
|
||||
\f[V]com.foo.NameProvider\f[R] class, running the program using JDK 10
|
||||
will ensure that the \f[V]com.foo.NameProvider\f[R] class is the one in
|
||||
\f[V]META-INF/versions/10/com/foo/\f[R].
|
||||
Running the program using JDK 8 will ensure that the
|
||||
\f[CB]com.foo.NameProvider\f[R] class is the one at the root of the JAR,
|
||||
in \f[CB]com/foo\f[R].
|
||||
\f[V]com.foo.NameProvider\f[R] class is the one at the root of the JAR,
|
||||
in \f[V]com/foo\f[R].
|
||||
.RE
|
||||
.IP \[bu] 2
|
||||
Create an archive, \f[CB]my.jar\f[R], by reading options and lists of
|
||||
class files from the file \f[CB]classes.list\f[R].
|
||||
Create an archive, \f[V]my.jar\f[R], by reading options and lists of
|
||||
class files from the file \f[V]classes.list\f[R].
|
||||
.RS 2
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
To shorten or simplify the \f[CB]jar\f[R] command, you can specify
|
||||
arguments in a separate text file and pass it to the \f[CB]jar\f[R]
|
||||
command with the at sign (\f[CB]\@\f[R]) as a prefix.
|
||||
To shorten or simplify the \f[V]jar\f[R] command, you can specify
|
||||
arguments in a separate text file and pass it to the \f[V]jar\f[R]
|
||||
command with the at sign (\f[V]\[at]\f[R]) as a prefix.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jar\ \-\-create\ \-\-file\ my.jar\ \@classes.list\f[R]
|
||||
\f[V]jar --create --file my.jar \[at]classes.list\f[R]
|
||||
.RE
|
||||
.RE
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -19,87 +19,85 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JINFO" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JINFO" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jinfo \- generate Java configuration information for a specified Java
|
||||
jinfo - generate Java configuration information for a specified Java
|
||||
process
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[B]Note:\f[R] This command is experimental and unsupported.
|
||||
.PP
|
||||
\f[CB]jinfo\f[R] [\f[I]option\f[R]] \f[I]pid\f[R]
|
||||
\f[V]jinfo\f[R] [\f[I]option\f[R]] \f[I]pid\f[R]
|
||||
.TP
|
||||
.B \f[I]option\f[R]
|
||||
This represents the \f[CB]jinfo\f[R] command\-line options.
|
||||
\f[I]option\f[R]
|
||||
This represents the \f[V]jinfo\f[R] command-line options.
|
||||
See \f[B]Options for the jinfo Command\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]pid\f[R]
|
||||
\f[I]pid\f[R]
|
||||
The process ID for which the configuration information is to be printed.
|
||||
The process must be a Java process.
|
||||
To get a list of Java processes running on a machine, use either the
|
||||
\f[CB]ps\f[R] command or, if the JVM processes are not running in a
|
||||
\f[V]ps\f[R] command or, if the JVM processes are not running in a
|
||||
separate docker instance, the \f[B]jps\f[R] command.
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jinfo\f[R] command prints Java configuration information for a
|
||||
The \f[V]jinfo\f[R] command prints Java configuration information for a
|
||||
specified Java process.
|
||||
The configuration information includes Java system properties and JVM
|
||||
command\-line flags.
|
||||
If the specified process is running on a 64\-bit JVM, then you might
|
||||
need to specify the \f[CB]\-J\-d64\f[R] option, for example:
|
||||
command-line flags.
|
||||
If the specified process is running on a 64-bit JVM, then you might need
|
||||
to specify the \f[V]-J-d64\f[R] option, for example:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jinfo\ \-J\-d64\ \-sysprops\f[R] \f[I]pid\f[R]
|
||||
\f[V]jinfo -J-d64 -sysprops\f[R] \f[I]pid\f[R]
|
||||
.RE
|
||||
.PP
|
||||
This command is unsupported and might not be available in future
|
||||
releases of the JDK.
|
||||
In Windows Systems where \f[CB]dbgeng.dll\f[R] is not present, the
|
||||
In Windows Systems where \f[V]dbgeng.dll\f[R] is not present, the
|
||||
Debugging Tools for Windows must be installed to have these tools work.
|
||||
The \f[CB]PATH\f[R] environment variable should contain the location of
|
||||
the \f[CB]jvm.dll\f[R] that\[aq]s used by the target process or the
|
||||
The \f[V]PATH\f[R] environment variable should contain the location of
|
||||
the \f[V]jvm.dll\f[R] that\[aq]s used by the target process or the
|
||||
location from which the core dump file was produced.
|
||||
.SH OPTIONS FOR THE JINFO COMMAND
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
If none of the following options are used, both the command\-line flags
|
||||
and the system property name\-value pairs are printed.
|
||||
If none of the following options are used, both the command-line flags
|
||||
and the system property name-value pairs are printed.
|
||||
.TP
|
||||
.B \f[CB]\-flag\f[R] \f[I]name\f[R]
|
||||
Prints the name and value of the specified command\-line flag.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]-flag\f[R] \f[I]name\f[R]
|
||||
Prints the name and value of the specified command-line flag.
|
||||
.TP
|
||||
.B \f[CB]\-flag\f[R] [\f[CB]+\f[R]|\f[CB]\-\f[R]]\f[I]name\f[R]
|
||||
Enables or disables the specified Boolean command\-line flag.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]-flag\f[R] [\f[V]+\f[R]|\f[V]-\f[R]]\f[I]name\f[R]
|
||||
Enables or disables the specified Boolean command-line flag.
|
||||
.TP
|
||||
.B \f[CB]\-flag\f[R] \f[I]name\f[R]\f[CB]=\f[R]\f[I]value\f[R]
|
||||
Sets the specified command\-line flag to the specified value.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]-flag\f[R] \f[I]name\f[R]\f[V]=\f[R]\f[I]value\f[R]
|
||||
Sets the specified command-line flag to the specified value.
|
||||
.TP
|
||||
.B \f[CB]\-flags\f[R]
|
||||
Prints command\-line flags passed to the JVM.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]-flags\f[R]
|
||||
Prints command-line flags passed to the JVM.
|
||||
.TP
|
||||
.B \f[CB]\-sysprops\f[R]
|
||||
Prints Java system properties as name\-value pairs.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]-sysprops\f[R]
|
||||
Prints Java system properties as name-value pairs.
|
||||
.TP
|
||||
.B \f[CB]\-h\f[R] or \f[CB]\-help\f[R]
|
||||
\f[V]-h\f[R] or \f[V]-help\f[R]
|
||||
Prints a help message.
|
||||
.RS
|
||||
.RE
|
||||
|
||||
@ -19,83 +19,88 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JMAP" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JMAP" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jmap \- print details of a specified process
|
||||
jmap - print details of a specified process
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[B]Note:\f[R] This command is experimental and unsupported.
|
||||
.PP
|
||||
\f[CB]jmap\f[R] [\f[I]options\f[R]] \f[I]pid\f[R]
|
||||
\f[V]jmap\f[R] [\f[I]options\f[R]] \f[I]pid\f[R]
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
This represents the \f[CB]jmap\f[R] command\-line options.
|
||||
\f[I]options\f[R]
|
||||
This represents the \f[V]jmap\f[R] command-line options.
|
||||
See \f[B]Options for the jmap Command\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]pid\f[R]
|
||||
\f[I]pid\f[R]
|
||||
The process ID for which the information specified by the
|
||||
\f[I]options\f[R] is to be printed.
|
||||
The process must be a Java process.
|
||||
To get a list of Java processes running on a machine, use either the
|
||||
\f[CB]ps\f[R] command or, if the JVM processes are not running in a
|
||||
\f[V]ps\f[R] command or, if the JVM processes are not running in a
|
||||
separate docker instance, the \f[B]jps\f[R] command.
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jmap\f[R] command prints details of a specified running process.
|
||||
The \f[V]jmap\f[R] command prints details of a specified running
|
||||
process.
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
This command is unsupported and might not be available in future
|
||||
releases of the JDK.
|
||||
On Windows Systems where the \f[CB]dbgeng.dll\f[R] file isn\[aq]t present,
|
||||
the Debugging Tools for Windows must be installed to make these tools
|
||||
work.
|
||||
The \f[CB]PATH\f[R] environment variable should contain the location of
|
||||
the \f[CB]jvm.dll\f[R] file that\[aq]s used by the target process or the
|
||||
On Windows Systems where the \f[V]dbgeng.dll\f[R] file isn\[aq]t
|
||||
present, the Debugging Tools for Windows must be installed to make these
|
||||
tools work.
|
||||
The \f[V]PATH\f[R] environment variable should contain the location of
|
||||
the \f[V]jvm.dll\f[R] file that\[aq]s used by the target process or the
|
||||
location from which the core dump file was produced.
|
||||
.SH OPTIONS FOR THE JMAP COMMAND
|
||||
.TP
|
||||
.B \f[CB]\-clstats\f[R] \f[I]pid\f[R]
|
||||
\f[V]-clstats\f[R] \f[I]pid\f[R]
|
||||
Connects to a running process and prints class loader statistics of Java
|
||||
heap.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-finalizerinfo\f[R] \f[I]pid\f[R]
|
||||
\f[V]-finalizerinfo\f[R] \f[I]pid\f[R]
|
||||
Connects to a running process and prints information on objects awaiting
|
||||
finalization.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-histo\f[R][\f[CB]:live\f[R]] \f[I]pid\f[R]
|
||||
\f[V]-histo\f[R][\f[V]:live\f[R]] \f[I]pid\f[R]
|
||||
Connects to a running process and prints a histogram of the Java object
|
||||
heap.
|
||||
If the \f[CB]live\f[R] suboption is specified, it then counts only live
|
||||
If the \f[V]live\f[R] suboption is specified, it then counts only live
|
||||
objects.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-dump:\f[R]\f[I]dump_options\f[R] \f[I]pid\f[R]
|
||||
\f[V]-dump:\f[R]\f[I]dump_options\f[R] \f[I]pid\f[R]
|
||||
Connects to a running process and dumps the Java heap.
|
||||
The \f[I]dump_options\f[R] include:
|
||||
.RS
|
||||
.IP \[bu] 2
|
||||
\f[CB]live\f[R] \-\-\- When specified, dumps only the live objects; if not
|
||||
\f[V]live\f[R] --- When specified, dumps only the live objects; if not
|
||||
specified, then dumps all objects in the heap.
|
||||
.IP \[bu] 2
|
||||
\f[CB]format=b\f[R] \-\-\- Dumps the Java heap in \f[CB]hprof\f[R] binary
|
||||
\f[V]format=b\f[R] --- Dumps the Java heap in \f[V]hprof\f[R] binary
|
||||
format
|
||||
.IP \[bu] 2
|
||||
\f[CB]file=\f[R]\f[I]filename\f[R] \-\-\- Dumps the heap to
|
||||
\f[V]file=\f[R]\f[I]filename\f[R] --- Dumps the heap to
|
||||
\f[I]filename\f[R]
|
||||
.PP
|
||||
Example: \f[CB]jmap\ \-dump:live,format=b,file=heap.bin\f[R] \f[I]pid\f[R]
|
||||
Example: \f[V]jmap -dump:live,format=b,file=heap.bin\f[R] \f[I]pid\f[R]
|
||||
.RE
|
||||
|
||||
@ -19,215 +19,217 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JPS" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JPS" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jps \- list the instrumented JVMs on the target system
|
||||
jps - list the instrumented JVMs on the target system
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[B]Note:\f[R] This command is experimental and unsupported.
|
||||
.PP
|
||||
\f[CB]jps\f[R] [\f[CB]\-q\f[R]] [\f[CB]\-mlvV\f[R]] [\f[I]hostid\f[R]]
|
||||
\f[V]jps\f[R] [\f[V]-q\f[R]] [\f[V]-mlvV\f[R]] [\f[I]hostid\f[R]]
|
||||
.PP
|
||||
\f[CB]jps\f[R] [\f[CB]\-help\f[R]]
|
||||
\f[V]jps\f[R] [\f[V]-help\f[R]]
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.B \f[CB]\-q\f[R]
|
||||
\f[V]-q\f[R]
|
||||
Suppresses the output of the class name, JAR file name, and arguments
|
||||
passed to the \f[CB]main\f[R] method, producing a list of only local JVM
|
||||
passed to the \f[V]main\f[R] method, producing a list of only local JVM
|
||||
identifiers.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-mlvV\f[R]
|
||||
\f[V]-mlvV\f[R]
|
||||
You can specify any combination of these options.
|
||||
.RS
|
||||
.IP \[bu] 2
|
||||
\f[CB]\-m\f[R] displays the arguments passed to the \f[CB]main\f[R] method.
|
||||
The output may be \f[CB]null\f[R] for embedded JVMs.
|
||||
\f[V]-m\f[R] displays the arguments passed to the \f[V]main\f[R] method.
|
||||
The output may be \f[V]null\f[R] for embedded JVMs.
|
||||
.IP \[bu] 2
|
||||
\f[CB]\-l\f[R] displays the full package name for the application\[aq]s
|
||||
\f[CB]main\f[R] class or the full path name to the application\[aq]s JAR
|
||||
\f[V]-l\f[R] displays the full package name for the application\[aq]s
|
||||
\f[V]main\f[R] class or the full path name to the application\[aq]s JAR
|
||||
file.
|
||||
.IP \[bu] 2
|
||||
\f[CB]\-v\f[R] displays the arguments passed to the JVM.
|
||||
\f[V]-v\f[R] displays the arguments passed to the JVM.
|
||||
.IP \[bu] 2
|
||||
\f[CB]\-V\f[R] suppresses the output of the class name, JAR file name, and
|
||||
arguments passed to the \f[CB]main\f[R] method, producing a list of only
|
||||
\f[V]-V\f[R] suppresses the output of the class name, JAR file name, and
|
||||
arguments passed to the \f[V]main\f[R] method, producing a list of only
|
||||
local JVM identifiers.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]hostid\f[R]
|
||||
\f[I]hostid\f[R]
|
||||
The identifier of the host for which the process report should be
|
||||
generated.
|
||||
The \f[CB]hostid\f[R] can include optional components that indicate the
|
||||
The \f[V]hostid\f[R] can include optional components that indicate the
|
||||
communications protocol, port number, and other implementation specific
|
||||
data.
|
||||
See \f[B]Host Identifier\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-help\f[R]
|
||||
Displays the help message for the \f[CB]jps\f[R] command.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]-help\f[R]
|
||||
Displays the help message for the \f[V]jps\f[R] command.
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jps\f[R] command lists the instrumented Java HotSpot VMs on the
|
||||
The \f[V]jps\f[R] command lists the instrumented Java HotSpot VMs on the
|
||||
target system.
|
||||
The command is limited to reporting information on JVMs for which it has
|
||||
the access permissions.
|
||||
.PP
|
||||
If the \f[CB]jps\f[R] command is run without specifying a \f[CB]hostid\f[R],
|
||||
then it searches for instrumented JVMs on the local host.
|
||||
If started with a \f[CB]hostid\f[R], then it searches for JVMs on the
|
||||
If the \f[V]jps\f[R] command is run without specifying a
|
||||
\f[V]hostid\f[R], then it searches for instrumented JVMs on the local
|
||||
host.
|
||||
If started with a \f[V]hostid\f[R], then it searches for JVMs on the
|
||||
indicated host, using the specified protocol and port.
|
||||
A \f[CB]jstatd\f[R] process is assumed to be running on the target host.
|
||||
A \f[V]jstatd\f[R] process is assumed to be running on the target host.
|
||||
.PP
|
||||
The \f[CB]jps\f[R] command reports the local JVM identifier, or
|
||||
\f[CB]lvmid\f[R], for each instrumented JVM found on the target system.
|
||||
The \f[CB]lvmid\f[R] is typically, but not necessarily, the operating
|
||||
The \f[V]jps\f[R] command reports the local JVM identifier, or
|
||||
\f[V]lvmid\f[R], for each instrumented JVM found on the target system.
|
||||
The \f[V]lvmid\f[R] is typically, but not necessarily, the operating
|
||||
system\[aq]s process identifier for the JVM process.
|
||||
With no options, the \f[CB]jps\f[R] command lists each Java
|
||||
application\[aq]s \f[CB]lvmid\f[R] followed by the short form of the
|
||||
With no options, the \f[V]jps\f[R] command lists each Java
|
||||
application\[aq]s \f[V]lvmid\f[R] followed by the short form of the
|
||||
application\[aq]s class name or jar file name.
|
||||
The short form of the class name or JAR file name omits the class\[aq]s
|
||||
package information or the JAR files path information.
|
||||
.PP
|
||||
The \f[CB]jps\f[R] command uses the Java launcher to find the class name
|
||||
The \f[V]jps\f[R] command uses the Java launcher to find the class name
|
||||
and arguments passed to the main method.
|
||||
If the target JVM is started with a custom launcher, then the class or
|
||||
JAR file name, and the arguments to the \f[CB]main\f[R] method aren\[aq]t
|
||||
JAR file name, and the arguments to the \f[V]main\f[R] method aren\[aq]t
|
||||
available.
|
||||
In this case, the \f[CB]jps\f[R] command outputs the string
|
||||
\f[CB]Unknown\f[R] for the class name, or JAR file name, and for the
|
||||
arguments to the \f[CB]main\f[R] method.
|
||||
In this case, the \f[V]jps\f[R] command outputs the string
|
||||
\f[V]Unknown\f[R] for the class name, or JAR file name, and for the
|
||||
arguments to the \f[V]main\f[R] method.
|
||||
.PP
|
||||
The list of JVMs produced by the \f[CB]jps\f[R] command can be limited by
|
||||
The list of JVMs produced by the \f[V]jps\f[R] command can be limited by
|
||||
the permissions granted to the principal running the command.
|
||||
The command lists only the JVMs for which the principal has access
|
||||
rights as determined by operating system\-specific access control
|
||||
rights as determined by operating system-specific access control
|
||||
mechanisms.
|
||||
.SH HOST IDENTIFIER
|
||||
.PP
|
||||
The host identifier, or \f[CB]hostid\f[R], is a string that indicates the
|
||||
The host identifier, or \f[V]hostid\f[R], is a string that indicates the
|
||||
target system.
|
||||
The syntax of the \f[CB]hostid\f[R] string corresponds to the syntax of a
|
||||
The syntax of the \f[V]hostid\f[R] string corresponds to the syntax of a
|
||||
URI:
|
||||
.RS
|
||||
.PP
|
||||
[\f[I]protocol\f[R]\f[CB]:\f[R]][[\f[CB]//\f[R]]\f[I]hostname\f[R]][\f[CB]:\f[R]\f[I]port\f[R]][\f[CB]/\f[R]\f[I]servername\f[R]]
|
||||
[\f[I]protocol\f[R]\f[V]:\f[R]][[\f[V]//\f[R]]\f[I]hostname\f[R]][\f[V]:\f[R]\f[I]port\f[R]][\f[V]/\f[R]\f[I]servername\f[R]]
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]protocol\f[R]
|
||||
\f[I]protocol\f[R]
|
||||
The communications protocol.
|
||||
If the \f[I]protocol\f[R] is omitted and a \f[I]hostname\f[R] isn\[aq]t
|
||||
specified, then the default protocol is a platform\-specific, optimized,
|
||||
specified, then the default protocol is a platform-specific, optimized,
|
||||
local protocol.
|
||||
If the protocol is omitted and a host name is specified, then the
|
||||
default protocol is \f[CB]rmi\f[R].
|
||||
.RS
|
||||
.RE
|
||||
default protocol is \f[V]rmi\f[R].
|
||||
.TP
|
||||
.B \f[I]hostname\f[R]
|
||||
\f[I]hostname\f[R]
|
||||
A host name or IP address that indicates the target host.
|
||||
If you omit the \f[I]hostname\f[R] parameter, then the target host is the
|
||||
local host.
|
||||
.RS
|
||||
.RE
|
||||
If you omit the \f[I]hostname\f[R] parameter, then the target host is
|
||||
the local host.
|
||||
.TP
|
||||
.B \f[I]port\f[R]
|
||||
\f[I]port\f[R]
|
||||
The default port for communicating with the remote server.
|
||||
If the \f[I]hostname\f[R] parameter is omitted or the \f[I]protocol\f[R]
|
||||
parameter specifies an optimized, local protocol, then the \f[I]port\f[R]
|
||||
parameter is ignored.
|
||||
parameter specifies an optimized, local protocol, then the
|
||||
\f[I]port\f[R] parameter is ignored.
|
||||
Otherwise, treatment of the \f[I]port\f[R] parameter is
|
||||
implementation\-specific.
|
||||
For the default \f[CB]rmi\f[R] protocol, the \f[I]port\f[R] parameter
|
||||
indicates the port number for the \f[CB]rmiregistry\f[R] on the remote
|
||||
implementation-specific.
|
||||
For the default \f[V]rmi\f[R] protocol, the \f[I]port\f[R] parameter
|
||||
indicates the port number for the \f[V]rmiregistry\f[R] on the remote
|
||||
host.
|
||||
If the \f[I]port\f[R] parameter is omitted, and the \f[I]protocol\f[R]
|
||||
parameter indicates \f[CB]rmi\f[R], then the default \f[CB]rmiregistry\f[R]
|
||||
port (\f[CB]1099\f[R]) is used.
|
||||
.RS
|
||||
.RE
|
||||
parameter indicates \f[V]rmi\f[R], then the default
|
||||
\f[V]rmiregistry\f[R] port (\f[V]1099\f[R]) is used.
|
||||
.TP
|
||||
.B \f[I]servername\f[R]
|
||||
\f[I]servername\f[R]
|
||||
The treatment of this parameter depends on the implementation.
|
||||
For the optimized, local protocol, this field is ignored.
|
||||
For the \f[CB]rmi\f[R] protocol, this parameter is a string that
|
||||
For the \f[V]rmi\f[R] protocol, this parameter is a string that
|
||||
represents the name of the RMI remote object on the remote host.
|
||||
See the \f[B]jstatd\f[R] command \f[CB]\-n\f[R] option.
|
||||
.RS
|
||||
.RE
|
||||
See the \f[B]jstatd\f[R] command \f[V]-n\f[R] option.
|
||||
.SH OUTPUT FORMAT OF THE JPS COMMAND
|
||||
.PP
|
||||
The output of the \f[CB]jps\f[R] command has the following pattern:
|
||||
The output of the \f[V]jps\f[R] command has the following pattern:
|
||||
.RS
|
||||
.PP
|
||||
\f[I]lvmid\f[R] [ [ \f[I]classname\f[R] | \f[I]JARfilename\f[R] |
|
||||
\f[CB]"Unknown"\f[R]] [ \f[I]arg\f[R]* ] [ \f[I]jvmarg\f[R]* ] ]
|
||||
\f[V]\[dq]Unknown\[dq]\f[R]] [ \f[I]arg\f[R]* ] [ \f[I]jvmarg\f[R]* ] ]
|
||||
.RE
|
||||
.PP
|
||||
All output tokens are separated by white space.
|
||||
An \f[CB]arg\f[R] value that includes embedded white space introduces
|
||||
An \f[V]arg\f[R] value that includes embedded white space introduces
|
||||
ambiguity when attempting to map arguments to their actual positional
|
||||
parameters.
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
It\[aq]s recommended that you don\[aq]t write scripts to parse
|
||||
\f[CB]jps\f[R] output because the format might change in future releases.
|
||||
If you write scripts that parse \f[CB]jps\f[R] output, then expect to
|
||||
\f[V]jps\f[R] output because the format might change in future releases.
|
||||
If you write scripts that parse \f[V]jps\f[R] output, then expect to
|
||||
modify them for future releases of this tool.
|
||||
.SH EXAMPLES
|
||||
.PP
|
||||
This section provides examples of the \f[CB]jps\f[R] command.
|
||||
This section provides examples of the \f[V]jps\f[R] command.
|
||||
.PP
|
||||
List the instrumented JVMs on the local host:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jps
|
||||
18027\ Java2Demo.JAR
|
||||
18032\ jps
|
||||
18005\ jstat
|
||||
18027 Java2Demo.JAR
|
||||
18032 jps
|
||||
18005 jstat
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
The following example lists the instrumented JVMs on a remote host.
|
||||
This example assumes that the \f[CB]jstat\f[R] server and either the its
|
||||
internal RMI registry or a separate external \f[CB]rmiregistry\f[R]
|
||||
This example assumes that the \f[V]jstat\f[R] server and either the its
|
||||
internal RMI registry or a separate external \f[V]rmiregistry\f[R]
|
||||
process are running on the remote host on the default port (port
|
||||
\f[CB]1099\f[R]).
|
||||
\f[V]1099\f[R]).
|
||||
It also assumes that the local host has appropriate permissions to
|
||||
access the remote host.
|
||||
This example includes the \f[CB]\-l\f[R] option to output the long form of
|
||||
This example includes the \f[V]-l\f[R] option to output the long form of
|
||||
the class names or JAR file names.
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jps\ \-l\ remote.domain
|
||||
3002\ /opt/jdk1.7.0/demo/jfc/Java2D/Java2Demo.JAR
|
||||
2857\ sun.tools.jstatd.jstatd
|
||||
jps -l remote.domain
|
||||
3002 /opt/jdk1.7.0/demo/jfc/Java2D/Java2Demo.JAR
|
||||
2857 sun.tools.jstatd.jstatd
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
The following example lists the instrumented JVMs on a remote host with
|
||||
a nondefault port for the RMI registry.
|
||||
This example assumes that the \f[CB]jstatd\f[R] server, with an internal
|
||||
RMI registry bound to port \f[CB]2002\f[R], is running on the remote host.
|
||||
This example also uses the \f[CB]\-m\f[R] option to include the arguments
|
||||
passed to the \f[CB]main\f[R] method of each of the listed Java
|
||||
This example assumes that the \f[V]jstatd\f[R] server, with an internal
|
||||
RMI registry bound to port \f[V]2002\f[R], is running on the remote
|
||||
host.
|
||||
This example also uses the \f[V]-m\f[R] option to include the arguments
|
||||
passed to the \f[V]main\f[R] method of each of the listed Java
|
||||
applications.
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jps\ \-m\ remote.domain:2002
|
||||
3002\ /opt/jdk1.7.0/demo/jfc/Java2D/Java2Demo.JAR
|
||||
3102\ sun.tools.jstatd.jstatd\ \-p\ 2002
|
||||
jps -m remote.domain:2002
|
||||
3002 /opt/jdk1.7.0/demo/jfc/Java2D/Java2Demo.JAR
|
||||
3102 sun.tools.jstatd.jstatd -p 2002
|
||||
\f[R]
|
||||
.fi
|
||||
|
||||
@ -19,65 +19,71 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JSTACK" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JSTACK" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jstack \- print Java stack traces of Java threads for a specified Java
|
||||
jstack - print Java stack traces of Java threads for a specified Java
|
||||
process
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[B]Note:\f[R] This command is experimental and unsupported.
|
||||
.PP
|
||||
\f[CB]jstack\f[R] [\f[I]options\f[R]] \f[I]pid\f[R]
|
||||
\f[V]jstack\f[R] [\f[I]options\f[R]] \f[I]pid\f[R]
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
This represents the \f[CB]jstack\f[R] command\-line options.
|
||||
\f[I]options\f[R]
|
||||
This represents the \f[V]jstack\f[R] command-line options.
|
||||
See \f[B]Options for the jstack Command\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]pid\f[R]
|
||||
\f[I]pid\f[R]
|
||||
The process ID for which the stack trace is printed.
|
||||
The process must be a Java process.
|
||||
To get a list of Java processes running on a machine, use either the
|
||||
\f[CB]ps\f[R] command or, if the JVM processes are not running in a
|
||||
\f[V]ps\f[R] command or, if the JVM processes are not running in a
|
||||
separate docker instance, the \f[B]jps\f[R] command.
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jstack\f[R] command prints Java stack traces of Java threads for
|
||||
a specified Java process.
|
||||
The \f[V]jstack\f[R] command prints Java stack traces of Java threads
|
||||
for a specified Java process.
|
||||
For each Java frame, the full class name, method name, byte code index
|
||||
(BCI), and line number, when available, are printed.
|
||||
C++ mangled names aren\[aq]t demangled.
|
||||
To demangle C++ names, the output of this command can be piped to
|
||||
\f[CB]c++filt\f[R].
|
||||
When the specified process is running on a 64\-bit JVM, you might need
|
||||
to specify the \f[CB]\-J\-d64\f[R] option, for example:
|
||||
\f[CB]jstack\ \-J\-d64\f[R] \f[I]pid\f[R].
|
||||
\f[V]c++filt\f[R].
|
||||
When the specified process is running on a 64-bit JVM, you might need to
|
||||
specify the \f[V]-J-d64\f[R] option, for example:
|
||||
\f[V]jstack -J-d64\f[R] \f[I]pid\f[R].
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
This command is unsupported and might not be available in future
|
||||
releases of the JDK.
|
||||
In Windows Systems where the \f[CB]dbgeng.dll\f[R] file isn\[aq]t present,
|
||||
the Debugging Tools for Windows must be installed so that these tools
|
||||
work.
|
||||
The \f[CB]PATH\f[R] environment variable needs to contain the location of
|
||||
the \f[CB]jvm.dll\f[R] that is used by the target process, or the location
|
||||
from which the core dump file was produced.
|
||||
In Windows Systems where the \f[V]dbgeng.dll\f[R] file isn\[aq]t
|
||||
present, the Debugging Tools for Windows must be installed so that these
|
||||
tools work.
|
||||
The \f[V]PATH\f[R] environment variable needs to contain the location of
|
||||
the \f[V]jvm.dll\f[R] that is used by the target process, or the
|
||||
location from which the core dump file was produced.
|
||||
.SH OPTIONS FOR THE JSTACK COMMAND
|
||||
.TP
|
||||
.B \f[CB]\-l\f[R]
|
||||
\f[V]-l\f[R]
|
||||
The long listing option prints additional information about locks.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-h\f[R] or \f[CB]\-help\f[R]
|
||||
\f[V]-h\f[R] or \f[V]-help\f[R]
|
||||
Prints a help message.
|
||||
.RS
|
||||
.RE
|
||||
|
||||
@ -19,86 +19,87 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JSTAT" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JSTAT" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jstat \- monitor JVM statistics
|
||||
jstat - monitor JVM statistics
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[B]Note:\f[R] This command is experimental and unsupported.
|
||||
.PP
|
||||
\f[CB]jstat\f[R] \f[I]generalOptions\f[R]
|
||||
\f[V]jstat\f[R] \f[I]generalOptions\f[R]
|
||||
.PP
|
||||
\f[CB]jstat\f[R] \f[I]outputOptions\f[R] [\f[CB]\-t\f[R]] [\f[CB]\-h\f[R]
|
||||
\f[V]jstat\f[R] \f[I]outputOptions\f[R] [\f[V]-t\f[R]] [\f[V]-h\f[R]
|
||||
\f[I]lines\f[R]] \f[I]vmid\f[R] [\f[I]interval\f[R] [\f[I]count\f[R]]]
|
||||
.TP
|
||||
.B \f[I]generalOptions\f[R]
|
||||
A single general command\-line option.
|
||||
\f[I]generalOptions\f[R]
|
||||
A single general command-line option.
|
||||
See \f[B]General Options\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]outputOptions\f[R]
|
||||
An option reported by the \f[CB]\-options\f[R] option.
|
||||
One or more output options that consist of a single \f[CB]statOption\f[R],
|
||||
plus any of the \f[CB]\-t\f[R], \f[CB]\-h\f[R], and \f[CB]\-J\f[R] options.
|
||||
\f[I]outputOptions\f[R]
|
||||
An option reported by the \f[V]-options\f[R] option.
|
||||
One or more output options that consist of a single
|
||||
\f[V]statOption\f[R], plus any of the \f[V]-t\f[R], \f[V]-h\f[R], and
|
||||
\f[V]-J\f[R] options.
|
||||
See \f[B]Output Options for the jstat Command\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-t\f[R]
|
||||
Displays a time\-stamp column as the first column of output.
|
||||
\f[V]-t\f[R]
|
||||
Displays a time-stamp column as the first column of output.
|
||||
The time stamp is the time since the start time of the target JVM.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-h\f[R] \f[I]n\f[R]
|
||||
\f[V]-h\f[R] \f[I]n\f[R]
|
||||
Displays a column header every \f[I]n\f[R] samples (output rows), where
|
||||
\f[I]n\f[R] is a positive integer.
|
||||
The default value is \f[CB]0\f[R], which displays the column header of the
|
||||
first row of data.
|
||||
.RS
|
||||
.RE
|
||||
The default value is \f[V]0\f[R], which displays the column header of
|
||||
the first row of data.
|
||||
.TP
|
||||
.B \f[I]vmid\f[R]
|
||||
\f[I]vmid\f[R]
|
||||
A virtual machine identifier, which is a string that indicates the
|
||||
target JVM.
|
||||
See \f[B]Virtual Machine Identifier\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]interval\f[R]
|
||||
\f[I]interval\f[R]
|
||||
The sampling interval in the specified units, seconds (s) or
|
||||
milliseconds (ms).
|
||||
Default units are milliseconds.
|
||||
This must be a positive integer.
|
||||
When specified, the \f[CB]jstat\f[R] command produces its output at each
|
||||
When specified, the \f[V]jstat\f[R] command produces its output at each
|
||||
interval.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]count\f[R]
|
||||
\f[I]count\f[R]
|
||||
The number of samples to display.
|
||||
The default value is infinity, which causes the \f[CB]jstat\f[R] command
|
||||
The default value is infinity, which causes the \f[V]jstat\f[R] command
|
||||
to display statistics until the target JVM terminates or the
|
||||
\f[CB]jstat\f[R] command is terminated.
|
||||
\f[V]jstat\f[R] command is terminated.
|
||||
This value must be a positive integer.
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jstat\f[R] command displays performance statistics for an
|
||||
The \f[V]jstat\f[R] command displays performance statistics for an
|
||||
instrumented Java HotSpot VM.
|
||||
The target JVM is identified by its virtual machine identifier, or
|
||||
\f[CB]vmid\f[R] option.
|
||||
\f[V]vmid\f[R] option.
|
||||
.PP
|
||||
The \f[CB]jstat\f[R] command supports two types of options, general
|
||||
The \f[V]jstat\f[R] command supports two types of options, general
|
||||
options and output options.
|
||||
General options cause the \f[CB]jstat\f[R] command to display simple usage
|
||||
and version information.
|
||||
General options cause the \f[V]jstat\f[R] command to display simple
|
||||
usage and version information.
|
||||
Output options determine the content and format of the statistical
|
||||
output.
|
||||
.PP
|
||||
@ -109,36 +110,32 @@ future releases.
|
||||
If you specify one of the general options, then you can\[aq]t specify
|
||||
any other option or parameter.
|
||||
.TP
|
||||
.B \f[CB]\-help\f[R]
|
||||
\f[V]-help\f[R]
|
||||
Displays a help message.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-options\f[R]
|
||||
\f[V]-options\f[R]
|
||||
Displays a list of static options.
|
||||
See \f[B]Output Options for the jstat Command\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.SH OUTPUT OPTIONS FOR THE JSTAT COMMAND
|
||||
.PP
|
||||
If you don\[aq]t specify a general option, then you can specify output
|
||||
options.
|
||||
Output options determine the content and format of the \f[CB]jstat\f[R]
|
||||
command\[aq]s output, and consist of a single \f[CB]statOption\f[R], plus
|
||||
any of the other output options (\f[CB]\-h\f[R], \f[CB]\-t\f[R], and
|
||||
\f[CB]\-J\f[R]).
|
||||
The \f[CB]statOption\f[R] must come first.
|
||||
Output options determine the content and format of the \f[V]jstat\f[R]
|
||||
command\[aq]s output, and consist of a single \f[V]statOption\f[R], plus
|
||||
any of the other output options (\f[V]-h\f[R], \f[V]-t\f[R], and
|
||||
\f[V]-J\f[R]).
|
||||
The \f[V]statOption\f[R] must come first.
|
||||
.PP
|
||||
Output is formatted as a table, with columns that are separated by
|
||||
spaces.
|
||||
A header row with titles describes the columns.
|
||||
Use the \f[CB]\-h\f[R] option to set the frequency at which the header is
|
||||
Use the \f[V]-h\f[R] option to set the frequency at which the header is
|
||||
displayed.
|
||||
Column header names are consistent among the different options.
|
||||
In general, if two options provide a column with the same name, then the
|
||||
data source for the two columns is the same.
|
||||
.PP
|
||||
Use the \f[CB]\-t\f[R] option to display a time\-stamp column, labeled
|
||||
Use the \f[V]-t\f[R] option to display a time-stamp column, labeled
|
||||
Timestamp as the first column of output.
|
||||
The Timestamp column contains the elapsed time, in seconds, since the
|
||||
target JVM started.
|
||||
@ -147,448 +144,438 @@ subject to variation due to delayed thread scheduling on heavily loaded
|
||||
systems.
|
||||
.PP
|
||||
Use the interval and count parameters to determine how frequently and
|
||||
how many times, respectively, the \f[CB]jstat\f[R] command displays its
|
||||
how many times, respectively, the \f[V]jstat\f[R] command displays its
|
||||
output.
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
Don\[aq]t write scripts to parse the \f[CB]jstat\f[R] command\[aq]s output
|
||||
because the format might change in future releases.
|
||||
If you write scripts that parse the \f[CB]jstat\f[R] command output, then
|
||||
Don\[aq]t write scripts to parse the \f[V]jstat\f[R] command\[aq]s
|
||||
output because the format might change in future releases.
|
||||
If you write scripts that parse the \f[V]jstat\f[R] command output, then
|
||||
expect to modify them for future releases of this tool.
|
||||
.TP
|
||||
.B \f[CB]\-statOption\f[R]
|
||||
Determines the statistics information that the \f[CB]jstat\f[R] command
|
||||
\f[V]-statOption\f[R]
|
||||
Determines the statistics information that the \f[V]jstat\f[R] command
|
||||
displays.
|
||||
The following lists the available options.
|
||||
Use the \f[CB]\-options\f[R] general option to display the list of options
|
||||
Use the \f[V]-options\f[R] general option to display the list of options
|
||||
for a particular platform installation.
|
||||
See \f[B]Stat Options and Output\f[R].
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]class\f[R]: Displays statistics about the behavior of the class
|
||||
\f[V]class\f[R]: Displays statistics about the behavior of the class
|
||||
loader.
|
||||
.PP
|
||||
\f[CB]compiler\f[R]: Displays statistics about the behavior of the Java
|
||||
HotSpot VM Just\-in\-Time compiler.
|
||||
\f[V]compiler\f[R]: Displays statistics about the behavior of the Java
|
||||
HotSpot VM Just-in-Time compiler.
|
||||
.PP
|
||||
\f[CB]gc\f[R]: Displays statistics about the behavior of the garbage
|
||||
\f[V]gc\f[R]: Displays statistics about the behavior of the garbage
|
||||
collected heap.
|
||||
.PP
|
||||
\f[CB]gccapacity\f[R]: Displays statistics about the capacities of the
|
||||
\f[V]gccapacity\f[R]: Displays statistics about the capacities of the
|
||||
generations and their corresponding spaces.
|
||||
.PP
|
||||
\f[CB]gccause\f[R]: Displays a summary about garbage collection statistics
|
||||
(same as \f[CB]\-gcutil\f[R]), with the cause of the last and current
|
||||
(when applicable) garbage collection events.
|
||||
\f[V]gccause\f[R]: Displays a summary about garbage collection
|
||||
statistics (same as \f[V]-gcutil\f[R]), with the cause of the last and
|
||||
current (when applicable) garbage collection events.
|
||||
.PP
|
||||
\f[CB]gcnew\f[R]: Displays statistics about the behavior of the new
|
||||
\f[V]gcnew\f[R]: Displays statistics about the behavior of the new
|
||||
generation.
|
||||
.PP
|
||||
\f[CB]gcnewcapacity\f[R]: Displays statistics about the sizes of the new
|
||||
\f[V]gcnewcapacity\f[R]: Displays statistics about the sizes of the new
|
||||
generations and their corresponding spaces.
|
||||
.PP
|
||||
\f[CB]gcold\f[R]: Displays statistics about the behavior of the old
|
||||
\f[V]gcold\f[R]: Displays statistics about the behavior of the old
|
||||
generation and metaspace statistics.
|
||||
.PP
|
||||
\f[CB]gcoldcapacity\f[R]: Displays statistics about the sizes of the old
|
||||
\f[V]gcoldcapacity\f[R]: Displays statistics about the sizes of the old
|
||||
generation.
|
||||
.PP
|
||||
\f[CB]gcmetacapacity\f[R]: Displays statistics about the sizes of the
|
||||
\f[V]gcmetacapacity\f[R]: Displays statistics about the sizes of the
|
||||
metaspace.
|
||||
.PP
|
||||
\f[CB]gcutil\f[R]: Displays a summary about garbage collection statistics.
|
||||
\f[V]gcutil\f[R]: Displays a summary about garbage collection
|
||||
statistics.
|
||||
.PP
|
||||
\f[CB]printcompilation\f[R]: Displays Java HotSpot VM compilation method
|
||||
\f[V]printcompilation\f[R]: Displays Java HotSpot VM compilation method
|
||||
statistics.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-J\f[R]\f[I]javaOption\f[R]
|
||||
\f[V]-J\f[R]\f[I]javaOption\f[R]
|
||||
Passes \f[I]javaOption\f[R] to the Java application launcher.
|
||||
For example, \f[CB]\-J\-Xms48m\f[R] sets the startup memory to 48 MB.
|
||||
For example, \f[V]-J-Xms48m\f[R] sets the startup memory to 48 MB.
|
||||
For a complete list of options, see \f[B]java\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.SH STAT OPTIONS AND OUTPUT
|
||||
.PP
|
||||
The following information summarizes the columns that the \f[CB]jstat\f[R]
|
||||
command outputs for each \f[I]statOption\f[R].
|
||||
The following information summarizes the columns that the
|
||||
\f[V]jstat\f[R] command outputs for each \f[I]statOption\f[R].
|
||||
.TP
|
||||
.B \f[CB]\-class\f[R] \f[I]option\f[R]
|
||||
\f[V]-class\f[R] \f[I]option\f[R]
|
||||
Class loader statistics.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]Loaded\f[R]: Number of classes loaded.
|
||||
\f[V]Loaded\f[R]: Number of classes loaded.
|
||||
.PP
|
||||
\f[CB]Bytes\f[R]: Number of KB loaded.
|
||||
\f[V]Bytes\f[R]: Number of KB loaded.
|
||||
.PP
|
||||
\f[CB]Unloaded\f[R]: Number of classes unloaded.
|
||||
\f[V]Unloaded\f[R]: Number of classes unloaded.
|
||||
.PP
|
||||
\f[CB]Bytes\f[R]: Number of KB unloaded.
|
||||
\f[V]Bytes\f[R]: Number of KB unloaded.
|
||||
.PP
|
||||
\f[CB]Time\f[R]: Time spent performing class loading and unloading
|
||||
\f[V]Time\f[R]: Time spent performing class loading and unloading
|
||||
operations.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-compiler\f[R] \f[I]option\f[R]
|
||||
Java HotSpot VM Just\-in\-Time compiler statistics.
|
||||
\f[V]-compiler\f[R] \f[I]option\f[R]
|
||||
Java HotSpot VM Just-in-Time compiler statistics.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]Compiled\f[R]: Number of compilation tasks performed.
|
||||
\f[V]Compiled\f[R]: Number of compilation tasks performed.
|
||||
.PP
|
||||
\f[CB]Failed\f[R]: Number of compilations tasks failed.
|
||||
\f[V]Failed\f[R]: Number of compilations tasks failed.
|
||||
.PP
|
||||
\f[CB]Invalid\f[R]: Number of compilation tasks that were invalidated.
|
||||
\f[V]Invalid\f[R]: Number of compilation tasks that were invalidated.
|
||||
.PP
|
||||
\f[CB]Time\f[R]: Time spent performing compilation tasks.
|
||||
\f[V]Time\f[R]: Time spent performing compilation tasks.
|
||||
.PP
|
||||
\f[CB]FailedType\f[R]: Compile type of the last failed compilation.
|
||||
\f[V]FailedType\f[R]: Compile type of the last failed compilation.
|
||||
.PP
|
||||
\f[CB]FailedMethod\f[R]: Class name and method of the last failed
|
||||
\f[V]FailedMethod\f[R]: Class name and method of the last failed
|
||||
compilation.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-gc\f[R] \f[I]option\f[R]
|
||||
\f[V]-gc\f[R] \f[I]option\f[R]
|
||||
Garbage collected heap statistics.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]S0C\f[R]: Current survivor space 0 capacity (KB).
|
||||
\f[V]S0C\f[R]: Current survivor space 0 capacity (KB).
|
||||
.PP
|
||||
\f[CB]S1C\f[R]: Current survivor space 1 capacity (KB).
|
||||
\f[V]S1C\f[R]: Current survivor space 1 capacity (KB).
|
||||
.PP
|
||||
\f[CB]S0U\f[R]: Survivor space 0 utilization (KB).
|
||||
\f[V]S0U\f[R]: Survivor space 0 utilization (KB).
|
||||
.PP
|
||||
\f[CB]S1U\f[R]: Survivor space 1 utilization (KB).
|
||||
\f[V]S1U\f[R]: Survivor space 1 utilization (KB).
|
||||
.PP
|
||||
\f[CB]EC\f[R]: Current eden space capacity (KB).
|
||||
\f[V]EC\f[R]: Current eden space capacity (KB).
|
||||
.PP
|
||||
\f[CB]EU\f[R]: Eden space utilization (KB).
|
||||
\f[V]EU\f[R]: Eden space utilization (KB).
|
||||
.PP
|
||||
\f[CB]OC\f[R]: Current old space capacity (KB).
|
||||
\f[V]OC\f[R]: Current old space capacity (KB).
|
||||
.PP
|
||||
\f[CB]OU\f[R]: Old space utilization (KB).
|
||||
\f[V]OU\f[R]: Old space utilization (KB).
|
||||
.PP
|
||||
\f[CB]MC\f[R]: Metaspace Committed Size (KB).
|
||||
\f[V]MC\f[R]: Metaspace Committed Size (KB).
|
||||
.PP
|
||||
\f[CB]MU\f[R]: Metaspace utilization (KB).
|
||||
\f[V]MU\f[R]: Metaspace utilization (KB).
|
||||
.PP
|
||||
\f[CB]CCSC\f[R]: Compressed class committed size (KB).
|
||||
\f[V]CCSC\f[R]: Compressed class committed size (KB).
|
||||
.PP
|
||||
\f[CB]CCSU\f[R]: Compressed class space used (KB).
|
||||
\f[V]CCSU\f[R]: Compressed class space used (KB).
|
||||
.PP
|
||||
\f[CB]YGC\f[R]: Number of young generation garbage collection (GC) events.
|
||||
\f[V]YGC\f[R]: Number of young generation garbage collection (GC)
|
||||
events.
|
||||
.PP
|
||||
\f[CB]YGCT\f[R]: Young generation garbage collection time.
|
||||
\f[V]YGCT\f[R]: Young generation garbage collection time.
|
||||
.PP
|
||||
\f[CB]FGC\f[R]: Number of full GC events.
|
||||
\f[V]FGC\f[R]: Number of full GC events.
|
||||
.PP
|
||||
\f[CB]FGCT\f[R]: Full garbage collection time.
|
||||
\f[V]FGCT\f[R]: Full garbage collection time.
|
||||
.PP
|
||||
\f[CB]GCT\f[R]: Total garbage collection time.
|
||||
\f[V]GCT\f[R]: Total garbage collection time.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-gccapacity\f[R] \f[I]option\f[R]
|
||||
\f[V]-gccapacity\f[R] \f[I]option\f[R]
|
||||
Memory pool generation and space capacities.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]NGCMN\f[R]: Minimum new generation capacity (KB).
|
||||
\f[V]NGCMN\f[R]: Minimum new generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]NGCMX\f[R]: Maximum new generation capacity (KB).
|
||||
\f[V]NGCMX\f[R]: Maximum new generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]NGC\f[R]: Current new generation capacity (KB).
|
||||
\f[V]NGC\f[R]: Current new generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]S0C\f[R]: Current survivor space 0 capacity (KB).
|
||||
\f[V]S0C\f[R]: Current survivor space 0 capacity (KB).
|
||||
.PP
|
||||
\f[CB]S1C\f[R]: Current survivor space 1 capacity (KB).
|
||||
\f[V]S1C\f[R]: Current survivor space 1 capacity (KB).
|
||||
.PP
|
||||
\f[CB]EC\f[R]: Current eden space capacity (KB).
|
||||
\f[V]EC\f[R]: Current eden space capacity (KB).
|
||||
.PP
|
||||
\f[CB]OGCMN\f[R]: Minimum old generation capacity (KB).
|
||||
\f[V]OGCMN\f[R]: Minimum old generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]OGCMX\f[R]: Maximum old generation capacity (KB).
|
||||
\f[V]OGCMX\f[R]: Maximum old generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]OGC\f[R]: Current old generation capacity (KB).
|
||||
\f[V]OGC\f[R]: Current old generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]OC\f[R]: Current old space capacity (KB).
|
||||
\f[V]OC\f[R]: Current old space capacity (KB).
|
||||
.PP
|
||||
\f[CB]MCMN\f[R]: Minimum metaspace capacity (KB).
|
||||
\f[V]MCMN\f[R]: Minimum metaspace capacity (KB).
|
||||
.PP
|
||||
\f[CB]MCMX\f[R]: Maximum metaspace capacity (KB).
|
||||
\f[V]MCMX\f[R]: Maximum metaspace capacity (KB).
|
||||
.PP
|
||||
\f[CB]MC\f[R]: Metaspace Committed Size (KB).
|
||||
\f[V]MC\f[R]: Metaspace Committed Size (KB).
|
||||
.PP
|
||||
\f[CB]CCSMN\f[R]: Compressed class space minimum capacity (KB).
|
||||
\f[V]CCSMN\f[R]: Compressed class space minimum capacity (KB).
|
||||
.PP
|
||||
\f[CB]CCSMX\f[R]: Compressed class space maximum capacity (KB).
|
||||
\f[V]CCSMX\f[R]: Compressed class space maximum capacity (KB).
|
||||
.PP
|
||||
\f[CB]CCSC\f[R]: Compressed class committed size (KB).
|
||||
\f[V]CCSC\f[R]: Compressed class committed size (KB).
|
||||
.PP
|
||||
\f[CB]YGC\f[R]: Number of young generation GC events.
|
||||
\f[V]YGC\f[R]: Number of young generation GC events.
|
||||
.PP
|
||||
\f[CB]FGC\f[R]: Number of full GC events.
|
||||
\f[V]FGC\f[R]: Number of full GC events.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-gccause\f[R] \f[I]option\f[R]
|
||||
\f[V]-gccause\f[R] \f[I]option\f[R]
|
||||
This option displays the same summary of garbage collection statistics
|
||||
as the \f[CB]\-gcutil\f[R] option, but includes the causes of the last
|
||||
as the \f[V]-gcutil\f[R] option, but includes the causes of the last
|
||||
garbage collection event and (when applicable), the current garbage
|
||||
collection event.
|
||||
In addition to the columns listed for \f[CB]\-gcutil\f[R], this option
|
||||
In addition to the columns listed for \f[V]-gcutil\f[R], this option
|
||||
adds the following columns:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]LGCC\f[R]: Cause of last garbage collection
|
||||
\f[V]LGCC\f[R]: Cause of last garbage collection
|
||||
.PP
|
||||
\f[CB]GCC\f[R]: Cause of current garbage collection
|
||||
\f[V]GCC\f[R]: Cause of current garbage collection
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-gcnew\f[R] \f[I]option\f[R]
|
||||
\f[V]-gcnew\f[R] \f[I]option\f[R]
|
||||
New generation statistics.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]S0C\f[R]: Current survivor space 0 capacity (KB).
|
||||
\f[V]S0C\f[R]: Current survivor space 0 capacity (KB).
|
||||
.PP
|
||||
\f[CB]S1C\f[R]: Current survivor space 1 capacity (KB).
|
||||
\f[V]S1C\f[R]: Current survivor space 1 capacity (KB).
|
||||
.PP
|
||||
\f[CB]S0U\f[R]: Survivor space 0 utilization (KB).
|
||||
\f[V]S0U\f[R]: Survivor space 0 utilization (KB).
|
||||
.PP
|
||||
\f[CB]S1U\f[R]: Survivor space 1 utilization (KB).
|
||||
\f[V]S1U\f[R]: Survivor space 1 utilization (KB).
|
||||
.PP
|
||||
\f[CB]TT\f[R]: Tenuring threshold.
|
||||
\f[V]TT\f[R]: Tenuring threshold.
|
||||
.PP
|
||||
\f[CB]MTT\f[R]: Maximum tenuring threshold.
|
||||
\f[V]MTT\f[R]: Maximum tenuring threshold.
|
||||
.PP
|
||||
\f[CB]DSS\f[R]: Desired survivor size (KB).
|
||||
\f[V]DSS\f[R]: Desired survivor size (KB).
|
||||
.PP
|
||||
\f[CB]EC\f[R]: Current eden space capacity (KB).
|
||||
\f[V]EC\f[R]: Current eden space capacity (KB).
|
||||
.PP
|
||||
\f[CB]EU\f[R]: Eden space utilization (KB).
|
||||
\f[V]EU\f[R]: Eden space utilization (KB).
|
||||
.PP
|
||||
\f[CB]YGC\f[R]: Number of young generation GC events.
|
||||
\f[V]YGC\f[R]: Number of young generation GC events.
|
||||
.PP
|
||||
\f[CB]YGCT\f[R]: Young generation garbage collection time.
|
||||
\f[V]YGCT\f[R]: Young generation garbage collection time.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-gcnewcapacity\f[R] \f[I]option\f[R]
|
||||
\f[V]-gcnewcapacity\f[R] \f[I]option\f[R]
|
||||
New generation space size statistics.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]NGCMN\f[R]: Minimum new generation capacity (KB).
|
||||
\f[V]NGCMN\f[R]: Minimum new generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]NGCMX\f[R]: Maximum new generation capacity (KB).
|
||||
\f[V]NGCMX\f[R]: Maximum new generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]NGC\f[R]: Current new generation capacity (KB).
|
||||
\f[V]NGC\f[R]: Current new generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]S0CMX\f[R]: Maximum survivor space 0 capacity (KB).
|
||||
\f[V]S0CMX\f[R]: Maximum survivor space 0 capacity (KB).
|
||||
.PP
|
||||
\f[CB]S0C\f[R]: Current survivor space 0 capacity (KB).
|
||||
\f[V]S0C\f[R]: Current survivor space 0 capacity (KB).
|
||||
.PP
|
||||
\f[CB]S1CMX\f[R]: Maximum survivor space 1 capacity (KB).
|
||||
\f[V]S1CMX\f[R]: Maximum survivor space 1 capacity (KB).
|
||||
.PP
|
||||
\f[CB]S1C\f[R]: Current survivor space 1 capacity (KB).
|
||||
\f[V]S1C\f[R]: Current survivor space 1 capacity (KB).
|
||||
.PP
|
||||
\f[CB]ECMX\f[R]: Maximum eden space capacity (KB).
|
||||
\f[V]ECMX\f[R]: Maximum eden space capacity (KB).
|
||||
.PP
|
||||
\f[CB]EC\f[R]: Current eden space capacity (KB).
|
||||
\f[V]EC\f[R]: Current eden space capacity (KB).
|
||||
.PP
|
||||
\f[CB]YGC\f[R]: Number of young generation GC events.
|
||||
\f[V]YGC\f[R]: Number of young generation GC events.
|
||||
.PP
|
||||
\f[CB]FGC\f[R]: Number of full GC events.
|
||||
\f[V]FGC\f[R]: Number of full GC events.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-gcold\f[R] \f[I]option\f[R]
|
||||
\f[V]-gcold\f[R] \f[I]option\f[R]
|
||||
Old generation size statistics.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]MC\f[R]: Metaspace Committed Size (KB).
|
||||
\f[V]MC\f[R]: Metaspace Committed Size (KB).
|
||||
.PP
|
||||
\f[CB]MU\f[R]: Metaspace utilization (KB).
|
||||
\f[V]MU\f[R]: Metaspace utilization (KB).
|
||||
.PP
|
||||
\f[CB]CCSC\f[R]: Compressed class committed size (KB).
|
||||
\f[V]CCSC\f[R]: Compressed class committed size (KB).
|
||||
.PP
|
||||
\f[CB]CCSU\f[R]: Compressed class space used (KB).
|
||||
\f[V]CCSU\f[R]: Compressed class space used (KB).
|
||||
.PP
|
||||
\f[CB]OC\f[R]: Current old space capacity (KB).
|
||||
\f[V]OC\f[R]: Current old space capacity (KB).
|
||||
.PP
|
||||
\f[CB]OU\f[R]: Old space utilization (KB).
|
||||
\f[V]OU\f[R]: Old space utilization (KB).
|
||||
.PP
|
||||
\f[CB]YGC\f[R]: Number of young generation GC events.
|
||||
\f[V]YGC\f[R]: Number of young generation GC events.
|
||||
.PP
|
||||
\f[CB]FGC\f[R]: Number of full GC events.
|
||||
\f[V]FGC\f[R]: Number of full GC events.
|
||||
.PP
|
||||
\f[CB]FGCT\f[R]: Full garbage collection time.
|
||||
\f[V]FGCT\f[R]: Full garbage collection time.
|
||||
.PP
|
||||
\f[CB]GCT\f[R]: Total garbage collection time.
|
||||
\f[V]GCT\f[R]: Total garbage collection time.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-gcoldcapacity\f[R] \f[I]option\f[R]
|
||||
\f[V]-gcoldcapacity\f[R] \f[I]option\f[R]
|
||||
Old generation statistics.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]OGCMN\f[R]: Minimum old generation capacity (KB).
|
||||
\f[V]OGCMN\f[R]: Minimum old generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]OGCMX\f[R]: Maximum old generation capacity (KB).
|
||||
\f[V]OGCMX\f[R]: Maximum old generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]OGC\f[R]: Current old generation capacity (KB).
|
||||
\f[V]OGC\f[R]: Current old generation capacity (KB).
|
||||
.PP
|
||||
\f[CB]OC\f[R]: Current old space capacity (KB).
|
||||
\f[V]OC\f[R]: Current old space capacity (KB).
|
||||
.PP
|
||||
\f[CB]YGC\f[R]: Number of young generation GC events.
|
||||
\f[V]YGC\f[R]: Number of young generation GC events.
|
||||
.PP
|
||||
\f[CB]FGC\f[R]: Number of full GC events.
|
||||
\f[V]FGC\f[R]: Number of full GC events.
|
||||
.PP
|
||||
\f[CB]FGCT\f[R]: Full garbage collection time.
|
||||
\f[V]FGCT\f[R]: Full garbage collection time.
|
||||
.PP
|
||||
\f[CB]GCT\f[R]: Total garbage collection time.
|
||||
\f[V]GCT\f[R]: Total garbage collection time.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-gcmetacapacity\f[R] \f[I]option\f[R]
|
||||
\f[V]-gcmetacapacity\f[R] \f[I]option\f[R]
|
||||
Metaspace size statistics.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]MCMN\f[R]: Minimum metaspace capacity (KB).
|
||||
\f[V]MCMN\f[R]: Minimum metaspace capacity (KB).
|
||||
.PP
|
||||
\f[CB]MCMX\f[R]: Maximum metaspace capacity (KB).
|
||||
\f[V]MCMX\f[R]: Maximum metaspace capacity (KB).
|
||||
.PP
|
||||
\f[CB]MC\f[R]: Metaspace Committed Size (KB).
|
||||
\f[V]MC\f[R]: Metaspace Committed Size (KB).
|
||||
.PP
|
||||
\f[CB]CCSMN\f[R]: Compressed class space minimum capacity (KB).
|
||||
\f[V]CCSMN\f[R]: Compressed class space minimum capacity (KB).
|
||||
.PP
|
||||
\f[CB]CCSMX\f[R]: Compressed class space maximum capacity (KB).
|
||||
\f[V]CCSMX\f[R]: Compressed class space maximum capacity (KB).
|
||||
.PP
|
||||
\f[CB]YGC\f[R]: Number of young generation GC events.
|
||||
\f[V]YGC\f[R]: Number of young generation GC events.
|
||||
.PP
|
||||
\f[CB]FGC\f[R]: Number of full GC events.
|
||||
\f[V]FGC\f[R]: Number of full GC events.
|
||||
.PP
|
||||
\f[CB]FGCT\f[R]: Full garbage collection time.
|
||||
\f[V]FGCT\f[R]: Full garbage collection time.
|
||||
.PP
|
||||
\f[CB]GCT\f[R]: Total garbage collection time.
|
||||
\f[V]GCT\f[R]: Total garbage collection time.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-gcutil\f[R] \f[I]option\f[R]
|
||||
\f[V]-gcutil\f[R] \f[I]option\f[R]
|
||||
Summary of garbage collection statistics.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]S0\f[R]: Survivor space 0 utilization as a percentage of the
|
||||
\f[V]S0\f[R]: Survivor space 0 utilization as a percentage of the
|
||||
space\[aq]s current capacity.
|
||||
.PP
|
||||
\f[CB]S1\f[R]: Survivor space 1 utilization as a percentage of the
|
||||
\f[V]S1\f[R]: Survivor space 1 utilization as a percentage of the
|
||||
space\[aq]s current capacity.
|
||||
.PP
|
||||
\f[CB]E\f[R]: Eden space utilization as a percentage of the space\[aq]s
|
||||
\f[V]E\f[R]: Eden space utilization as a percentage of the space\[aq]s
|
||||
current capacity.
|
||||
.PP
|
||||
\f[CB]O\f[R]: Old space utilization as a percentage of the space\[aq]s
|
||||
\f[V]O\f[R]: Old space utilization as a percentage of the space\[aq]s
|
||||
current capacity.
|
||||
.PP
|
||||
\f[CB]M\f[R]: Metaspace utilization as a percentage of the space\[aq]s
|
||||
\f[V]M\f[R]: Metaspace utilization as a percentage of the space\[aq]s
|
||||
current capacity.
|
||||
.PP
|
||||
\f[CB]CCS\f[R]: Compressed class space utilization as a percentage.
|
||||
\f[V]CCS\f[R]: Compressed class space utilization as a percentage.
|
||||
.PP
|
||||
\f[CB]YGC\f[R]: Number of young generation GC events.
|
||||
\f[V]YGC\f[R]: Number of young generation GC events.
|
||||
.PP
|
||||
\f[CB]YGCT\f[R]: Young generation garbage collection time.
|
||||
\f[V]YGCT\f[R]: Young generation garbage collection time.
|
||||
.PP
|
||||
\f[CB]FGC\f[R]: Number of full GC events.
|
||||
\f[V]FGC\f[R]: Number of full GC events.
|
||||
.PP
|
||||
\f[CB]FGCT\f[R]: Full garbage collection time.
|
||||
\f[V]FGCT\f[R]: Full garbage collection time.
|
||||
.PP
|
||||
\f[CB]GCT\f[R]: Total garbage collection time.
|
||||
\f[V]GCT\f[R]: Total garbage collection time.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-printcompilation\f[R] \f[I]option\f[R]
|
||||
\f[V]-printcompilation\f[R] \f[I]option\f[R]
|
||||
Java HotSpot VM compiler method statistics.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]Compiled\f[R]: Number of compilation tasks performed by the most
|
||||
\f[V]Compiled\f[R]: Number of compilation tasks performed by the most
|
||||
recently compiled method.
|
||||
.PP
|
||||
\f[CB]Size\f[R]: Number of bytes of byte code of the most recently
|
||||
\f[V]Size\f[R]: Number of bytes of byte code of the most recently
|
||||
compiled method.
|
||||
.PP
|
||||
\f[CB]Type\f[R]: Compilation type of the most recently compiled method.
|
||||
\f[V]Type\f[R]: Compilation type of the most recently compiled method.
|
||||
.PP
|
||||
\f[CB]Method\f[R]: Class name and method name identifying the most
|
||||
\f[V]Method\f[R]: Class name and method name identifying the most
|
||||
recently compiled method.
|
||||
Class name uses a slash (/) instead of a dot (.) as a name space
|
||||
separator.
|
||||
Class name uses a slash (/) instead of a dot (.)
|
||||
as a name space separator.
|
||||
The method name is the method within the specified class.
|
||||
The format for these two fields is consistent with the HotSpot
|
||||
\f[CB]\-XX:+PrintCompilation\f[R] option.
|
||||
\f[V]-XX:+PrintCompilation\f[R] option.
|
||||
.RE
|
||||
.SH VIRTUAL MACHINE IDENTIFIER
|
||||
.PP
|
||||
The syntax of the \f[CB]vmid\f[R] string corresponds to the syntax of a
|
||||
The syntax of the \f[V]vmid\f[R] string corresponds to the syntax of a
|
||||
URI:
|
||||
.RS
|
||||
.PP
|
||||
[\f[I]protocol\f[R]\f[CB]:\f[R]][\f[CB]//\f[R]]\f[I]lvmid\f[R][\f[CB]\@\f[R]\f[I]hostname\f[R][\f[CB]:\f[R]\f[I]port\f[R]][\f[CB]/\f[R]\f[I]servername\f[R]]
|
||||
[\f[I]protocol\f[R]\f[V]:\f[R]][\f[V]//\f[R]]\f[I]lvmid\f[R][\f[V]\[at]\f[R]\f[I]hostname\f[R][\f[V]:\f[R]\f[I]port\f[R]][\f[V]/\f[R]\f[I]servername\f[R]]
|
||||
.RE
|
||||
.PP
|
||||
The syntax of the \f[CB]vmid\f[R] string corresponds to the syntax of a
|
||||
The syntax of the \f[V]vmid\f[R] string corresponds to the syntax of a
|
||||
URI.
|
||||
The \f[CB]vmid\f[R] string can vary from a simple integer that represents
|
||||
The \f[V]vmid\f[R] string can vary from a simple integer that represents
|
||||
a local JVM to a more complex construction that specifies a
|
||||
communications protocol, port number, and other implementation\-specific
|
||||
communications protocol, port number, and other implementation-specific
|
||||
values.
|
||||
.TP
|
||||
.B \f[I]protocol\f[R]
|
||||
\f[I]protocol\f[R]
|
||||
The communications protocol.
|
||||
If the \f[I]protocol\f[R] value is omitted and a host name isn\[aq]t
|
||||
specified, then the default protocol is a platform\-specific optimized
|
||||
specified, then the default protocol is a platform-specific optimized
|
||||
local protocol.
|
||||
If the \f[I]protocol\f[R] value is omitted and a host name is specified,
|
||||
then the default protocol is \f[CB]rmi\f[R].
|
||||
.RS
|
||||
.RE
|
||||
then the default protocol is \f[V]rmi\f[R].
|
||||
.TP
|
||||
.B \f[I]lvmid\f[R]
|
||||
\f[I]lvmid\f[R]
|
||||
The local virtual machine identifier for the target JVM.
|
||||
The \f[I]lvmid\f[R] is a platform\-specific value that uniquely
|
||||
The \f[I]lvmid\f[R] is a platform-specific value that uniquely
|
||||
identifies a JVM on a system.
|
||||
The \f[I]lvmid\f[R] is the only required component of a virtual machine
|
||||
identifier.
|
||||
The \f[I]lvmid\f[R] is typically, but not necessarily, the operating
|
||||
system\[aq]s process identifier for the target JVM process.
|
||||
You can use the \f[CB]jps\f[R] command to determine the \f[I]lvmid\f[R]
|
||||
You can use the \f[V]jps\f[R] command to determine the \f[I]lvmid\f[R]
|
||||
provided the JVM processes is not running in a separate docker instance.
|
||||
You can also determine the \f[I]lvmid\f[R] on Linux and OS X platforms
|
||||
with the \f[CB]ps\f[R] command, and on Windows with the Windows Task
|
||||
with the \f[V]ps\f[R] command, and on Windows with the Windows Task
|
||||
Manager.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]hostname\f[R]
|
||||
\f[I]hostname\f[R]
|
||||
A host name or IP address that indicates the target host.
|
||||
If the \f[I]hostname\f[R] value is omitted, then the target host is the
|
||||
local host.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]port\f[R]
|
||||
\f[I]port\f[R]
|
||||
The default port for communicating with the remote server.
|
||||
If the \f[I]hostname\f[R] value is omitted or the \f[I]protocol\f[R] value
|
||||
specifies an optimized, local protocol, then the \f[I]port\f[R] value is
|
||||
ignored.
|
||||
If the \f[I]hostname\f[R] value is omitted or the \f[I]protocol\f[R]
|
||||
value specifies an optimized, local protocol, then the \f[I]port\f[R]
|
||||
value is ignored.
|
||||
Otherwise, treatment of the \f[I]port\f[R] parameter is
|
||||
implementation\-specific.
|
||||
For the default \f[CB]rmi\f[R] protocol, the port value indicates the port
|
||||
number for the \f[CB]rmiregistry\f[R] on the remote host.
|
||||
implementation-specific.
|
||||
For the default \f[V]rmi\f[R] protocol, the port value indicates the
|
||||
port number for the \f[V]rmiregistry\f[R] on the remote host.
|
||||
If the \f[I]port\f[R] value is omitted and the \f[I]protocol\f[R] value
|
||||
indicates \f[CB]rmi\f[R], then the default rmiregistry port (1099) is
|
||||
indicates \f[V]rmi\f[R], then the default rmiregistry port (1099) is
|
||||
used.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]servername\f[R]
|
||||
\f[I]servername\f[R]
|
||||
The treatment of the \f[I]servername\f[R] parameter depends on
|
||||
implementation.
|
||||
For the optimized local protocol, this field is ignored.
|
||||
For the \f[CB]rmi\f[R] protocol, it represents the name of the RMI remote
|
||||
For the \f[V]rmi\f[R] protocol, it represents the name of the RMI remote
|
||||
object on the remote host.
|
||||
.RS
|
||||
.RE
|
||||
.SH EXAMPLES
|
||||
.PP
|
||||
This section presents some examples of monitoring a local JVM with an
|
||||
@ -597,7 +584,7 @@ This section presents some examples of monitoring a local JVM with an
|
||||
.PP
|
||||
This example attaches to lvmid 21891 and takes 7 samples at 250
|
||||
millisecond intervals and displays the output as specified by the
|
||||
\f[CB]\-gcutil\f[R] option.
|
||||
\f[V]-gcutil\f[R] option.
|
||||
.PP
|
||||
The output of this example shows that a young generation collection
|
||||
occurred between the third and fourth sample.
|
||||
@ -609,23 +596,23 @@ this collection it\[aq]s 91.03% utilized.
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jstat\ \-gcutil\ 21891\ 250\ 7
|
||||
\ \ S0\ \ \ \ \ S1\ \ \ \ \ E\ \ \ \ \ \ O\ \ \ \ \ \ M\ \ \ \ \ CCS\ \ \ \ YGC\ \ \ \ \ YGCT\ \ \ \ FGC\ \ \ \ FGCT\ \ \ \ \ GCT
|
||||
\ \ 0.00\ \ 97.02\ \ 70.31\ \ 66.80\ \ 95.52\ \ 89.14\ \ \ \ \ \ 7\ \ \ \ 0.300\ \ \ \ \ 0\ \ \ \ 0.000\ \ \ \ 0.300
|
||||
\ \ 0.00\ \ 97.02\ \ 86.23\ \ 66.80\ \ 95.52\ \ 89.14\ \ \ \ \ \ 7\ \ \ \ 0.300\ \ \ \ \ 0\ \ \ \ 0.000\ \ \ \ 0.300
|
||||
\ \ 0.00\ \ 97.02\ \ 96.53\ \ 66.80\ \ 95.52\ \ 89.14\ \ \ \ \ \ 7\ \ \ \ 0.300\ \ \ \ \ 0\ \ \ \ 0.000\ \ \ \ 0.300
|
||||
\ 91.03\ \ \ 0.00\ \ \ 1.98\ \ 68.19\ \ 95.89\ \ 91.24\ \ \ \ \ \ 8\ \ \ \ 0.378\ \ \ \ \ 0\ \ \ \ 0.000\ \ \ \ 0.378
|
||||
\ 91.03\ \ \ 0.00\ \ 15.82\ \ 68.19\ \ 95.89\ \ 91.24\ \ \ \ \ \ 8\ \ \ \ 0.378\ \ \ \ \ 0\ \ \ \ 0.000\ \ \ \ 0.378
|
||||
\ 91.03\ \ \ 0.00\ \ 17.80\ \ 68.19\ \ 95.89\ \ 91.24\ \ \ \ \ \ 8\ \ \ \ 0.378\ \ \ \ \ 0\ \ \ \ 0.000\ \ \ \ 0.378
|
||||
\ 91.03\ \ \ 0.00\ \ 17.80\ \ 68.19\ \ 95.89\ \ 91.24\ \ \ \ \ \ 8\ \ \ \ 0.378\ \ \ \ \ 0\ \ \ \ 0.000\ \ \ \ 0.378
|
||||
jstat -gcutil 21891 250 7
|
||||
S0 S1 E O M CCS YGC YGCT FGC FGCT GCT
|
||||
0.00 97.02 70.31 66.80 95.52 89.14 7 0.300 0 0.000 0.300
|
||||
0.00 97.02 86.23 66.80 95.52 89.14 7 0.300 0 0.000 0.300
|
||||
0.00 97.02 96.53 66.80 95.52 89.14 7 0.300 0 0.000 0.300
|
||||
91.03 0.00 1.98 68.19 95.89 91.24 8 0.378 0 0.000 0.378
|
||||
91.03 0.00 15.82 68.19 95.89 91.24 8 0.378 0 0.000 0.378
|
||||
91.03 0.00 17.80 68.19 95.89 91.24 8 0.378 0 0.000 0.378
|
||||
91.03 0.00 17.80 68.19 95.89 91.24 8 0.378 0 0.000 0.378
|
||||
\f[R]
|
||||
.fi
|
||||
.SH REPEAT THE COLUMN HEADER STRING
|
||||
.PP
|
||||
This example attaches to lvmid 21891 and takes samples at 250
|
||||
millisecond intervals and displays the output as specified by
|
||||
\f[CB]\-gcnew\f[R] option.
|
||||
In addition, it uses the \f[CB]\-h3\f[R] option to output the column
|
||||
\f[V]-gcnew\f[R] option.
|
||||
In addition, it uses the \f[V]-h3\f[R] option to output the column
|
||||
header after every 3 lines of data.
|
||||
.PP
|
||||
In addition to showing the repeating header string, this example shows
|
||||
@ -642,61 +629,61 @@ threshold to 31.
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jstat\ \-gcnew\ \-h3\ 21891\ 250
|
||||
\ S0C\ \ \ \ S1C\ \ \ \ S0U\ \ \ \ S1U\ \ \ TT\ MTT\ \ DSS\ \ \ \ \ \ EC\ \ \ \ \ \ \ EU\ \ \ \ \ YGC\ \ \ \ \ YGCT
|
||||
\ \ 64.0\ \ \ 64.0\ \ \ \ 0.0\ \ \ 31.7\ 31\ \ 31\ \ \ 32.0\ \ \ \ 512.0\ \ \ \ 178.6\ \ \ \ 249\ \ \ \ 0.203
|
||||
\ \ 64.0\ \ \ 64.0\ \ \ \ 0.0\ \ \ 31.7\ 31\ \ 31\ \ \ 32.0\ \ \ \ 512.0\ \ \ \ 355.5\ \ \ \ 249\ \ \ \ 0.203
|
||||
\ \ 64.0\ \ \ 64.0\ \ \ 35.4\ \ \ \ 0.0\ \ 2\ \ 31\ \ \ 32.0\ \ \ \ 512.0\ \ \ \ \ 21.9\ \ \ \ 250\ \ \ \ 0.204
|
||||
\ S0C\ \ \ \ S1C\ \ \ \ S0U\ \ \ \ S1U\ \ \ TT\ MTT\ \ DSS\ \ \ \ \ \ EC\ \ \ \ \ \ \ EU\ \ \ \ \ YGC\ \ \ \ \ YGCT
|
||||
\ \ 64.0\ \ \ 64.0\ \ \ 35.4\ \ \ \ 0.0\ \ 2\ \ 31\ \ \ 32.0\ \ \ \ 512.0\ \ \ \ 245.9\ \ \ \ 250\ \ \ \ 0.204
|
||||
\ \ 64.0\ \ \ 64.0\ \ \ 35.4\ \ \ \ 0.0\ \ 2\ \ 31\ \ \ 32.0\ \ \ \ 512.0\ \ \ \ 421.1\ \ \ \ 250\ \ \ \ 0.204
|
||||
\ \ 64.0\ \ \ 64.0\ \ \ \ 0.0\ \ \ 19.0\ 31\ \ 31\ \ \ 32.0\ \ \ \ 512.0\ \ \ \ \ 84.4\ \ \ \ 251\ \ \ \ 0.204
|
||||
\ S0C\ \ \ \ S1C\ \ \ \ S0U\ \ \ \ S1U\ \ \ TT\ MTT\ \ DSS\ \ \ \ \ \ EC\ \ \ \ \ \ \ EU\ \ \ \ \ YGC\ \ \ \ \ YGCT
|
||||
\ \ 64.0\ \ \ 64.0\ \ \ \ 0.0\ \ \ 19.0\ 31\ \ 31\ \ \ 32.0\ \ \ \ 512.0\ \ \ \ 306.7\ \ \ \ 251\ \ \ \ 0.204
|
||||
jstat -gcnew -h3 21891 250
|
||||
S0C S1C S0U S1U TT MTT DSS EC EU YGC YGCT
|
||||
64.0 64.0 0.0 31.7 31 31 32.0 512.0 178.6 249 0.203
|
||||
64.0 64.0 0.0 31.7 31 31 32.0 512.0 355.5 249 0.203
|
||||
64.0 64.0 35.4 0.0 2 31 32.0 512.0 21.9 250 0.204
|
||||
S0C S1C S0U S1U TT MTT DSS EC EU YGC YGCT
|
||||
64.0 64.0 35.4 0.0 2 31 32.0 512.0 245.9 250 0.204
|
||||
64.0 64.0 35.4 0.0 2 31 32.0 512.0 421.1 250 0.204
|
||||
64.0 64.0 0.0 19.0 31 31 32.0 512.0 84.4 251 0.204
|
||||
S0C S1C S0U S1U TT MTT DSS EC EU YGC YGCT
|
||||
64.0 64.0 0.0 19.0 31 31 32.0 512.0 306.7 251 0.204
|
||||
\f[R]
|
||||
.fi
|
||||
.SH INCLUDE A TIME STAMP FOR EACH SAMPLE
|
||||
.PP
|
||||
This example attaches to lvmid 21891 and takes 3 samples at 250
|
||||
millisecond intervals.
|
||||
The \f[CB]\-t\f[R] option is used to generate a time stamp for each sample
|
||||
The \f[V]-t\f[R] option is used to generate a time stamp for each sample
|
||||
in the first column.
|
||||
.PP
|
||||
The Timestamp column reports the elapsed time in seconds since the start
|
||||
of the target JVM.
|
||||
In addition, the \f[CB]\-gcoldcapacity\f[R] output shows the old
|
||||
In addition, the \f[V]-gcoldcapacity\f[R] output shows the old
|
||||
generation capacity (OGC) and the old space capacity (OC) increasing as
|
||||
the heap expands to meet allocation or promotion demands.
|
||||
The old generation capacity (OGC) has grown from 11,696 KB to 13,820 KB
|
||||
after the eighty\-first full garbage collection (FGC).
|
||||
after the eighty-first full garbage collection (FGC).
|
||||
The maximum capacity of the generation (and space) is 60,544 KB (OGCMX),
|
||||
so it still has room to expand.
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
Timestamp\ \ \ \ \ \ OGCMN\ \ \ \ OGCMX\ \ \ \ \ OGC\ \ \ \ \ \ \ OC\ \ \ \ \ \ \ YGC\ \ \ FGC\ \ \ \ FGCT\ \ \ \ GCT
|
||||
\ \ \ \ \ \ \ \ \ \ 150.1\ \ \ 1408.0\ \ 60544.0\ \ 11696.0\ \ 11696.0\ \ \ 194\ \ \ \ 80\ \ \ \ 2.874\ \ \ 3.799
|
||||
\ \ \ \ \ \ \ \ \ \ 150.4\ \ \ 1408.0\ \ 60544.0\ \ 13820.0\ \ 13820.0\ \ \ 194\ \ \ \ 81\ \ \ \ 2.938\ \ \ 3.863
|
||||
\ \ \ \ \ \ \ \ \ \ 150.7\ \ \ 1408.0\ \ 60544.0\ \ 13820.0\ \ 13820.0\ \ \ 194\ \ \ \ 81\ \ \ \ 2.938\ \ \ 3.863
|
||||
Timestamp OGCMN OGCMX OGC OC YGC FGC FGCT GCT
|
||||
150.1 1408.0 60544.0 11696.0 11696.0 194 80 2.874 3.799
|
||||
150.4 1408.0 60544.0 13820.0 13820.0 194 81 2.938 3.863
|
||||
150.7 1408.0 60544.0 13820.0 13820.0 194 81 2.938 3.863
|
||||
\f[R]
|
||||
.fi
|
||||
.SH MONITOR INSTRUMENTATION FOR A REMOTE JVM
|
||||
.PP
|
||||
This example attaches to lvmid 40496 on the system named
|
||||
\f[CB]remote.domain\f[R] using the \f[CB]\-gcutil\f[R] option, with samples
|
||||
\f[V]remote.domain\f[R] using the \f[V]-gcutil\f[R] option, with samples
|
||||
taken every second indefinitely.
|
||||
.PP
|
||||
The lvmid is combined with the name of the remote host to construct a
|
||||
vmid of \f[CB]40496\@remote.domain\f[R].
|
||||
This vmid results in the use of the \f[CB]rmi\f[R] protocol to communicate
|
||||
to the default \f[CB]jstatd\f[R] server on the remote host.
|
||||
The \f[CB]jstatd\f[R] server is located using the \f[CB]rmiregistry\f[R]
|
||||
command on \f[CB]remote.domain\f[R] that\[aq]s bound to the default port
|
||||
of the \f[CB]rmiregistry\f[R] command (port 1099).
|
||||
vmid of \f[V]40496\[at]remote.domain\f[R].
|
||||
This vmid results in the use of the \f[V]rmi\f[R] protocol to
|
||||
communicate to the default \f[V]jstatd\f[R] server on the remote host.
|
||||
The \f[V]jstatd\f[R] server is located using the \f[V]rmiregistry\f[R]
|
||||
command on \f[V]remote.domain\f[R] that\[aq]s bound to the default port
|
||||
of the \f[V]rmiregistry\f[R] command (port 1099).
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jstat\ \-gcutil\ 40496\@remote.domain\ 1000
|
||||
\&...\ output\ omitted
|
||||
jstat -gcutil 40496\[at]remote.domain 1000
|
||||
\&... output omitted
|
||||
\f[R]
|
||||
.fi
|
||||
|
||||
@ -19,84 +19,86 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JCONSOLE" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JCONSOLE" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jconsole \- start a graphical console to monitor and manage Java
|
||||
jconsole - start a graphical console to monitor and manage Java
|
||||
applications
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]jconsole\f[R] [\f[CB]\-interval=\f[R]\f[I]n\f[R]] [\f[CB]\-notile\f[R]]
|
||||
[\f[CB]\-plugin\f[R] \f[I]path\f[R]] [\f[CB]\-version\f[R]]
|
||||
\f[V]jconsole\f[R] [\f[V]-interval=\f[R]\f[I]n\f[R]] [\f[V]-notile\f[R]]
|
||||
[\f[V]-plugin\f[R] \f[I]path\f[R]] [\f[V]-version\f[R]]
|
||||
[\f[I]connection\f[R] ...
|
||||
] [\f[CB]\-J\f[R]\f[I]input_arguments\f[R]]
|
||||
] [\f[V]-J\f[R]\f[I]input_arguments\f[R]]
|
||||
.PP
|
||||
\f[CB]jconsole\f[R] \f[CB]\-help\f[R]
|
||||
\f[V]jconsole\f[R] \f[V]-help\f[R]
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.B \f[CB]\-interval\f[R]
|
||||
Sets the update interval to \f[CB]n\f[R] seconds (default is 4 seconds).
|
||||
.RS
|
||||
.RE
|
||||
\f[V]-interval\f[R]
|
||||
Sets the update interval to \f[V]n\f[R] seconds (default is 4 seconds).
|
||||
.TP
|
||||
.B \f[CB]\-notile\f[R]
|
||||
\f[V]-notile\f[R]
|
||||
Doesn\[aq]t tile the windows for two or more connections.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-pluginpath\f[R] \f[I]path\f[R]
|
||||
Specifies the path that \f[CB]jconsole\f[R] uses to look up plug\-ins.
|
||||
The plug\-in \f[I]path\f[R] should contain a provider\-configuration file
|
||||
named \f[CB]META\-INF/services/com.sun.tools.jconsole.JConsolePlugin\f[R]
|
||||
that contains one line for each plug\-in.
|
||||
\f[V]-pluginpath\f[R] \f[I]path\f[R]
|
||||
Specifies the path that \f[V]jconsole\f[R] uses to look up plug-ins.
|
||||
The plug-in \f[I]path\f[R] should contain a provider-configuration file
|
||||
named \f[V]META-INF/services/com.sun.tools.jconsole.JConsolePlugin\f[R]
|
||||
that contains one line for each plug-in.
|
||||
The line specifies the fully qualified class name of the class
|
||||
implementing the \f[CB]com.sun.tools.jconsole.JConsolePlugin\f[R] class.
|
||||
.RS
|
||||
.RE
|
||||
implementing the \f[V]com.sun.tools.jconsole.JConsolePlugin\f[R] class.
|
||||
.TP
|
||||
.B \f[CB]\-version\f[R]
|
||||
\f[V]-version\f[R]
|
||||
Prints the program version.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]connection\f[R] = \f[I]pid\f[R] | \f[I]host\f[R]\f[CB]:\f[R]\f[I]port\f[R] | \f[I]jmxURL\f[R]
|
||||
\f[I]connection\f[R] = \f[I]pid\f[R] | \f[I]host\f[R]\f[V]:\f[R]\f[I]port\f[R] | \f[I]jmxURL\f[R]
|
||||
A connection is described by either \f[I]pid\f[R],
|
||||
\f[I]host\f[R]\f[CB]:\f[R]\f[I]port\f[R] or \f[I]jmxURL\f[R].
|
||||
\f[I]host\f[R]\f[V]:\f[R]\f[I]port\f[R] or \f[I]jmxURL\f[R].
|
||||
.RS
|
||||
.IP \[bu] 2
|
||||
The \f[I]pid\f[R] value is the process ID of a target process.
|
||||
The JVM must be running with the same user ID as the user ID running the
|
||||
\f[CB]jconsole\f[R] command.
|
||||
\f[V]jconsole\f[R] command.
|
||||
.IP \[bu] 2
|
||||
The \f[I]host\f[R]\f[CB]:\f[R]\f[I]port\f[R] values are the name of the host
|
||||
system on which the JVM is running, and the port number specified by the
|
||||
system property \f[CB]com.sun.management.jmxremote.port\f[R] when the JVM
|
||||
was started.
|
||||
The \f[I]host\f[R]\f[V]:\f[R]\f[I]port\f[R] values are the name of the
|
||||
host system on which the JVM is running, and the port number specified
|
||||
by the system property \f[V]com.sun.management.jmxremote.port\f[R] when
|
||||
the JVM was started.
|
||||
.IP \[bu] 2
|
||||
The \f[I]jmxUrl\f[R] value is the address of the JMX agent to be
|
||||
connected to as described in JMXServiceURL.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-J\f[R]\f[I]input_arguments\f[R]
|
||||
\f[V]-J\f[R]\f[I]input_arguments\f[R]
|
||||
Passes \f[I]input_arguments\f[R] to the JVM on which the
|
||||
\f[CB]jconsole\f[R] command is run.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]jconsole\f[R] command is run.
|
||||
.TP
|
||||
.B \f[CB]\-help\f[R] or \f[CB]\-\-help\f[R]
|
||||
\f[V]-help\f[R] or \f[V]--help\f[R]
|
||||
Displays the help message for the command.
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jconsole\f[R] command starts a graphical console tool that lets
|
||||
The \f[V]jconsole\f[R] command starts a graphical console tool that lets
|
||||
you monitor and manage Java applications and virtual machines on a local
|
||||
or remote machine.
|
||||
.PP
|
||||
On Windows, the \f[CB]jconsole\f[R] command doesn\[aq]t associate with a
|
||||
On Windows, the \f[V]jconsole\f[R] command doesn\[aq]t associate with a
|
||||
console window.
|
||||
It does, however, display a dialog box with error information when the
|
||||
\f[CB]jconsole\f[R] command fails.
|
||||
\f[V]jconsole\f[R] command fails.
|
||||
|
||||
@ -19,24 +19,36 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JAVAP" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JAVAP" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
javap \- disassemble one or more class files
|
||||
javap - disassemble one or more class files
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]javap\f[R] [\f[I]options\f[R]] \f[I]classes\f[R]...
|
||||
\f[V]javap\f[R] [\f[I]options\f[R]] \f[I]classes\f[R]...
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
Specifies the command\-line options.
|
||||
\f[I]options\f[R]
|
||||
Specifies the command-line options.
|
||||
See \f[B]Options for javap\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]classes\f[R]
|
||||
\f[I]classes\f[R]
|
||||
Specifies one or more classes separated by spaces to be processed for
|
||||
annotations.
|
||||
You can specify a class that can be found in the class path by its file
|
||||
@ -46,144 +58,108 @@ name, URL, or by its fully qualified class name.
|
||||
Examples:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]path/to/MyClass.class\f[R]
|
||||
\f[V]path/to/MyClass.class\f[R]
|
||||
.RE
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jar:file:///path/to/MyJar.jar!/mypkg/MyClass.class\f[R]
|
||||
\f[V]jar:file:///path/to/MyJar.jar!/mypkg/MyClass.class\f[R]
|
||||
.RE
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]java.lang.Object\f[R]
|
||||
\f[V]java.lang.Object\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]javap\f[R] command disassembles one or more class files.
|
||||
The \f[V]javap\f[R] command disassembles one or more class files.
|
||||
The output depends on the options used.
|
||||
When no options are used, the \f[CB]javap\f[R] command prints the
|
||||
When no options are used, the \f[V]javap\f[R] command prints the
|
||||
protected and public fields, and methods of the classes passed to it.
|
||||
.PP
|
||||
The \f[CB]javap\f[R] command isn\[aq]t multirelease JAR aware.
|
||||
The \f[V]javap\f[R] command isn\[aq]t multirelease JAR aware.
|
||||
Using the class path form of the command results in viewing the base
|
||||
entry in all JAR files, multirelease or not.
|
||||
Using the URL form, you can use the URL form of an argument to specify a
|
||||
specific version of a class to be disassembled.
|
||||
.PP
|
||||
The \f[CB]javap\f[R] command prints its output to \f[CB]stdout\f[R].
|
||||
The \f[V]javap\f[R] command prints its output to \f[V]stdout\f[R].
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
In tools that support \f[CB]\-\-\f[R] style options, the GNU\-style
|
||||
options can use the equal sign (\f[CB]=\f[R]) instead of a white space to
|
||||
In tools that support \f[V]--\f[R] style options, the GNU-style options
|
||||
can use the equal sign (\f[V]=\f[R]) instead of a white space to
|
||||
separate the name of an option from its value.
|
||||
.SH OPTIONS FOR JAVAP
|
||||
.TP
|
||||
.B \f[CB]\-\-help\f[R], \f[CB]\-help\f[R] , \f[CB]\-h\f[R], or \f[CB]\-?\f[R]
|
||||
Prints a help message for the \f[CB]javap\f[R] command.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--help\f[R], \f[V]-help\f[R] , \f[V]-h\f[R], or \f[V]-?\f[R]
|
||||
Prints a help message for the \f[V]javap\f[R] command.
|
||||
.TP
|
||||
.B \f[CB]\-version\f[R]
|
||||
\f[V]-version\f[R]
|
||||
Prints release information.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-verbose\f[R] or \f[CB]\-v\f[R]
|
||||
\f[V]-verbose\f[R] or \f[V]-v\f[R]
|
||||
Prints additional information about the selected class.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-l\f[R]
|
||||
\f[V]-l\f[R]
|
||||
Prints line and local variable tables.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-public\f[R]
|
||||
\f[V]-public\f[R]
|
||||
Shows only public classes and members.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-protected\f[R]
|
||||
\f[V]-protected\f[R]
|
||||
Shows only protected and public classes and members.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-package\f[R]
|
||||
\f[V]-package\f[R]
|
||||
Shows package/protected/public classes and members (default).
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-private\f[R] or \f[CB]\-p\f[R]
|
||||
\f[V]-private\f[R] or \f[V]-p\f[R]
|
||||
Shows all classes and members.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-c\f[R]
|
||||
\f[V]-c\f[R]
|
||||
Prints disassembled code, for example, the instructions that comprise
|
||||
the Java bytecodes, for each of the methods in the class.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-s\f[R]
|
||||
\f[V]-s\f[R]
|
||||
Prints internal type signatures.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-sysinfo\f[R]
|
||||
Shows system information (path, size, date, SHA\-256 hash) of the class
|
||||
\f[V]-sysinfo\f[R]
|
||||
Shows system information (path, size, date, SHA-256 hash) of the class
|
||||
being processed.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-constants\f[R]
|
||||
Shows \f[CB]static\ final\f[R] constants.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]-constants\f[R]
|
||||
Shows \f[V]static final\f[R] constants.
|
||||
.TP
|
||||
.B \f[CB]\-\-module\f[R] \f[I]module\f[R] or \f[CB]\-m\f[R] \f[I]module\f[R]
|
||||
\f[V]--module\f[R] \f[I]module\f[R] or \f[V]-m\f[R] \f[I]module\f[R]
|
||||
Specifies the module containing classes to be disassembled.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-module\-path\f[R] \f[I]path\f[R]
|
||||
\f[V]--module-path\f[R] \f[I]path\f[R]
|
||||
Specifies where to find application modules.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-system\f[R] \f[I]jdk\f[R]
|
||||
\f[V]--system\f[R] \f[I]jdk\f[R]
|
||||
Specifies where to find system modules.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-class\-path\f[R] \f[I]path\f[R], \f[CB]\-classpath\f[R] \f[I]path\f[R], or \f[CB]\-cp\f[R] \f[I]path\f[R]
|
||||
Specifies the path that the \f[CB]javap\f[R] command uses to find user
|
||||
\f[V]--class-path\f[R] \f[I]path\f[R], \f[V]-classpath\f[R] \f[I]path\f[R], or \f[V]-cp\f[R] \f[I]path\f[R]
|
||||
Specifies the path that the \f[V]javap\f[R] command uses to find user
|
||||
class files.
|
||||
It overrides the default or the \f[CB]CLASSPATH\f[R] environment variable
|
||||
It overrides the default or the \f[V]CLASSPATH\f[R] environment variable
|
||||
when it\[aq]s set.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-bootclasspath\f[R] \f[I]path\f[R]
|
||||
\f[V]-bootclasspath\f[R] \f[I]path\f[R]
|
||||
Overrides the location of bootstrap class files.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-multi\-release\f[R] \f[I]version\f[R]
|
||||
Specifies the version to select in multi\-release JAR files.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--multi-release\f[R] \f[I]version\f[R]
|
||||
Specifies the version to select in multi-release JAR files.
|
||||
.TP
|
||||
.B \f[CB]\-J\f[R]\f[I]option\f[R]
|
||||
\f[V]-J\f[R]\f[I]option\f[R]
|
||||
Passes the specified option to the JVM.
|
||||
For example:
|
||||
.RS
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
javap\ \-J\-version
|
||||
javap -J-version
|
||||
|
||||
javap\ \-J\-Djava.security.manager\ \-J\-Djava.security.policy=MyPolicy\ MyClassName
|
||||
javap -J-Djava.security.manager -J-Djava.security.policy=MyPolicy MyClassName
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
@ -191,90 +167,90 @@ See \f[I]Overview of Java Options\f[R] in \f[B]java\f[R].
|
||||
.RE
|
||||
.SH JAVAP EXAMPLE
|
||||
.PP
|
||||
Compile the following \f[CB]HelloWorldFrame\f[R] class:
|
||||
Compile the following \f[V]HelloWorldFrame\f[R] class:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
import\ java.awt.Graphics;
|
||||
import java.awt.Graphics;
|
||||
|
||||
import\ javax.swing.JFrame;
|
||||
import\ javax.swing.JPanel;
|
||||
import javax.swing.JFrame;
|
||||
import javax.swing.JPanel;
|
||||
|
||||
public\ class\ HelloWorldFrame\ extends\ JFrame\ {
|
||||
public class HelloWorldFrame extends JFrame {
|
||||
|
||||
\ \ \ String\ message\ =\ "Hello\ World!";
|
||||
String message = \[dq]Hello World!\[dq];
|
||||
|
||||
\ \ \ public\ HelloWorldFrame(){
|
||||
\ \ \ \ \ \ \ \ setContentPane(new\ JPanel(){
|
||||
\ \ \ \ \ \ \ \ \ \ \ \ \@Override
|
||||
\ \ \ \ \ \ \ \ \ \ \ \ protected\ void\ paintComponent(Graphics\ g)\ {
|
||||
\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ g.drawString(message,\ 15,\ 30);
|
||||
\ \ \ \ \ \ \ \ \ \ \ \ }
|
||||
\ \ \ \ \ \ \ \ });
|
||||
\ \ \ \ \ \ \ \ setSize(100,\ 100);
|
||||
\ \ \ \ }
|
||||
\ \ \ \ public\ static\ void\ main(String[]\ args)\ {
|
||||
\ \ \ \ \ \ \ \ HelloWorldFrame\ frame\ =\ new\ HelloWorldFrame();
|
||||
\ \ \ \ \ \ \ \ frame.setVisible(true);
|
||||
public HelloWorldFrame(){
|
||||
setContentPane(new JPanel(){
|
||||
\[at]Override
|
||||
protected void paintComponent(Graphics g) {
|
||||
g.drawString(message, 15, 30);
|
||||
}
|
||||
});
|
||||
setSize(100, 100);
|
||||
}
|
||||
public static void main(String[] args) {
|
||||
HelloWorldFrame frame = new HelloWorldFrame();
|
||||
frame.setVisible(true);
|
||||
|
||||
\ \ \ \ }
|
||||
}
|
||||
|
||||
}
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
The output from the \f[CB]javap\ HelloWorldFrame.class\f[R] command yields
|
||||
The output from the \f[V]javap HelloWorldFrame.class\f[R] command yields
|
||||
the following:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
Compiled\ from\ "HelloWorldFrame.java"
|
||||
public\ class\ HelloWorldFrame\ extends\ javax.swing.JFrame\ {
|
||||
\ \ java.lang.String\ message;
|
||||
\ \ public\ HelloWorldFrame();
|
||||
\ \ public\ static\ void\ main(java.lang.String[]);
|
||||
Compiled from \[dq]HelloWorldFrame.java\[dq]
|
||||
public class HelloWorldFrame extends javax.swing.JFrame {
|
||||
java.lang.String message;
|
||||
public HelloWorldFrame();
|
||||
public static void main(java.lang.String[]);
|
||||
}
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
The output from the \f[CB]javap\ \-c\ HelloWorldFrame.class\f[R] command
|
||||
The output from the \f[V]javap -c HelloWorldFrame.class\f[R] command
|
||||
yields the following:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
Compiled\ from\ "HelloWorldFrame.java"
|
||||
public\ class\ HelloWorldFrame\ extends\ javax.swing.JFrame\ {
|
||||
\ \ java.lang.String\ message;
|
||||
Compiled from \[dq]HelloWorldFrame.java\[dq]
|
||||
public class HelloWorldFrame extends javax.swing.JFrame {
|
||||
java.lang.String message;
|
||||
|
||||
\ \ public\ HelloWorldFrame();
|
||||
\ \ \ \ Code:
|
||||
\ \ \ \ \ \ \ 0:\ aload_0
|
||||
\ \ \ \ \ \ \ 1:\ invokespecial\ #1\ \ \ \ \ \ \ \ //\ Method\ javax/swing/JFrame."<init>":()V
|
||||
\ \ \ \ \ \ \ 4:\ aload_0
|
||||
\ \ \ \ \ \ \ 5:\ ldc\ \ \ \ \ \ \ \ \ \ \ #2\ \ \ \ \ \ \ \ //\ String\ Hello\ World!
|
||||
\ \ \ \ \ \ \ 7:\ putfield\ \ \ \ \ \ #3\ \ \ \ \ \ \ \ //\ Field\ message:Ljava/lang/String;
|
||||
\ \ \ \ \ \ 10:\ aload_0
|
||||
\ \ \ \ \ \ 11:\ new\ \ \ \ \ \ \ \ \ \ \ #4\ \ \ \ \ \ \ \ //\ class\ HelloWorldFrame$1
|
||||
\ \ \ \ \ \ 14:\ dup
|
||||
\ \ \ \ \ \ 15:\ aload_0
|
||||
\ \ \ \ \ \ 16:\ invokespecial\ #5\ \ \ \ \ \ \ \ //\ Method\ HelloWorldFrame$1."<init>":(LHelloWorldFrame;)V
|
||||
\ \ \ \ \ \ 19:\ invokevirtual\ #6\ \ \ \ \ \ \ \ //\ Method\ setContentPane:(Ljava/awt/Container;)V
|
||||
\ \ \ \ \ \ 22:\ aload_0
|
||||
\ \ \ \ \ \ 23:\ bipush\ \ \ \ \ \ \ \ 100
|
||||
\ \ \ \ \ \ 25:\ bipush\ \ \ \ \ \ \ \ 100
|
||||
\ \ \ \ \ \ 27:\ invokevirtual\ #7\ \ \ \ \ \ \ \ //\ Method\ setSize:(II)V
|
||||
\ \ \ \ \ \ 30:\ return
|
||||
public HelloWorldFrame();
|
||||
Code:
|
||||
0: aload_0
|
||||
1: invokespecial #1 // Method javax/swing/JFrame.\[dq]<init>\[dq]:()V
|
||||
4: aload_0
|
||||
5: ldc #2 // String Hello World!
|
||||
7: putfield #3 // Field message:Ljava/lang/String;
|
||||
10: aload_0
|
||||
11: new #4 // class HelloWorldFrame$1
|
||||
14: dup
|
||||
15: aload_0
|
||||
16: invokespecial #5 // Method HelloWorldFrame$1.\[dq]<init>\[dq]:(LHelloWorldFrame;)V
|
||||
19: invokevirtual #6 // Method setContentPane:(Ljava/awt/Container;)V
|
||||
22: aload_0
|
||||
23: bipush 100
|
||||
25: bipush 100
|
||||
27: invokevirtual #7 // Method setSize:(II)V
|
||||
30: return
|
||||
|
||||
\ \ public\ static\ void\ main(java.lang.String[]);
|
||||
\ \ \ \ Code:
|
||||
\ \ \ \ \ \ \ 0:\ new\ \ \ \ \ \ \ \ \ \ \ #8\ \ \ \ \ \ \ \ //\ class\ HelloWorldFrame
|
||||
\ \ \ \ \ \ \ 3:\ dup
|
||||
\ \ \ \ \ \ \ 4:\ invokespecial\ #9\ \ \ \ \ \ \ \ //\ Method\ "<init>":()V
|
||||
\ \ \ \ \ \ \ 7:\ astore_1
|
||||
\ \ \ \ \ \ \ 8:\ aload_1
|
||||
\ \ \ \ \ \ \ 9:\ iconst_1
|
||||
\ \ \ \ \ \ 10:\ invokevirtual\ #10\ \ \ \ \ \ \ //\ Method\ setVisible:(Z)V
|
||||
\ \ \ \ \ \ 13:\ return
|
||||
public static void main(java.lang.String[]);
|
||||
Code:
|
||||
0: new #8 // class HelloWorldFrame
|
||||
3: dup
|
||||
4: invokespecial #9 // Method \[dq]<init>\[dq]:()V
|
||||
7: astore_1
|
||||
8: aload_1
|
||||
9: iconst_1
|
||||
10: invokevirtual #10 // Method setVisible:(Z)V
|
||||
13: return
|
||||
}
|
||||
\f[R]
|
||||
.fi
|
||||
|
||||
@ -19,26 +19,38 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JDEPRSCAN" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JDEPRSCAN" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jdeprscan \- static analysis tool that scans a jar file (or some other
|
||||
jdeprscan - static analysis tool that scans a jar file (or some other
|
||||
aggregation of class files) for uses of deprecated API elements
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]jdeprscan\f[R] [\f[I]options\f[R]]
|
||||
\f[V]jdeprscan\f[R] [\f[I]options\f[R]]
|
||||
{\f[I]dir\f[R]|\f[I]jar\f[R]|\f[I]class\f[R]}
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
\f[I]options\f[R]
|
||||
See \f[B]Options for the jdeprscan Command\f[R]
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]dir\f[R]|\f[I]jar\f[R]|\f[I]class\f[R]
|
||||
\f[CB]jdeprscan\f[R] command scans each argument for usages of deprecated
|
||||
\f[I]dir\f[R]|\f[I]jar\f[R]|\f[I]class\f[R]
|
||||
\f[V]jdeprscan\f[R] command scans each argument for usages of deprecated
|
||||
APIs.
|
||||
The arguments can be a:
|
||||
.RS
|
||||
@ -49,45 +61,45 @@ The arguments can be a:
|
||||
.IP \[bu] 2
|
||||
\f[I]class\f[R]: Class name or class file
|
||||
.PP
|
||||
The class name should use a dot (\f[CB]\&.\f[R]) as a separator.
|
||||
The class name should use a dot (\f[V].\f[R]) as a separator.
|
||||
For example:
|
||||
.PP
|
||||
\f[CB]java.lang.Thread\f[R]
|
||||
\f[V]java.lang.Thread\f[R]
|
||||
.PP
|
||||
For nested classes, the dollar sign \f[CB]$\f[R] separator character
|
||||
For nested classes, the dollar sign \f[V]$\f[R] separator character
|
||||
should be used.
|
||||
For example:
|
||||
.PP
|
||||
\f[CB]java.lang.Thread$State\f[R]
|
||||
\f[V]java.lang.Thread$State\f[R]
|
||||
.PP
|
||||
A class file can also be named.
|
||||
For example:
|
||||
.PP
|
||||
\f[CB]build/classes/java/lang/Thread$State.class\f[R]
|
||||
\f[V]build/classes/java/lang/Thread$State.class\f[R]
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jdeprscan\f[R] tool is a static analysis tool provided by the
|
||||
The \f[V]jdeprscan\f[R] tool is a static analysis tool provided by the
|
||||
JDK that scans a JAR file or some other aggregation of class files for
|
||||
uses of deprecated API elements.
|
||||
The deprecated APIs identified by the \f[CB]jdeprscan\f[R] tool are only
|
||||
The deprecated APIs identified by the \f[V]jdeprscan\f[R] tool are only
|
||||
those that are defined by Java SE.
|
||||
Deprecated APIs defined by third\-party libraries aren\[aq]t reported.
|
||||
Deprecated APIs defined by third-party libraries aren\[aq]t reported.
|
||||
.PP
|
||||
To scan a JAR file or a set of class files, you must first ensure that
|
||||
all of the classes that the scanned classes depend upon are present in
|
||||
the class path.
|
||||
Set the class path using the \f[CB]\-\-class\-path\f[R] option described
|
||||
in \f[B]Options for the jdeprscan Command\f[R].
|
||||
Set the class path using the \f[V]--class-path\f[R] option described in
|
||||
\f[B]Options for the jdeprscan Command\f[R].
|
||||
Typically, you would use the same class path as the one that you use
|
||||
when invoking your application.
|
||||
.PP
|
||||
If the \f[CB]jdeprscan\f[R] can\[aq]t find all the dependent classes, it
|
||||
If the \f[V]jdeprscan\f[R] can\[aq]t find all the dependent classes, it
|
||||
will generate an error message for each class that\[aq]s missing.
|
||||
These error messages are typically of the form:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]error:\ cannot\ find\ class\ ...\f[R]
|
||||
\f[V]error: cannot find class ...\f[R]
|
||||
.RE
|
||||
.PP
|
||||
If these errors occur, then you must adjust the class path so that it
|
||||
@ -96,83 +108,69 @@ includes all dependent classes.
|
||||
.PP
|
||||
The following options are available:
|
||||
.TP
|
||||
.B \f[CB]\-\-class\-path\f[R] \f[I]path\f[R]
|
||||
\f[V]--class-path\f[R] \f[I]path\f[R]
|
||||
Provides a search path for resolution of dependent classes.
|
||||
.RS
|
||||
.PP
|
||||
\f[I]path\f[R] can be a search path that consists of one or more
|
||||
directories separated by the system\-specific path separator.
|
||||
directories separated by the system-specific path separator.
|
||||
For example:
|
||||
.IP \[bu] 2
|
||||
\f[B]Linux and OS X:\f[R]
|
||||
.RS 2
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]\-\-class\-path\ /some/directory:/another/different/dir\f[R]
|
||||
\f[V]--class-path /some/directory:/another/different/dir\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
On Windows, use a semicolon (\f[CB];\f[R]) as the separator instead of a
|
||||
colon (\f[CB]:\f[R]).
|
||||
On Windows, use a semicolon (\f[V];\f[R]) as the separator instead of a
|
||||
colon (\f[V]:\f[R]).
|
||||
.IP \[bu] 2
|
||||
\f[B]Windows:\f[R]
|
||||
.RS 2
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]\-\-class\-path\ \\some\\directory;\\another\\different\\dir\f[R]
|
||||
\f[V]--class-path \[rs]some\[rs]directory;\[rs]another\[rs]different\[rs]dir\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-for\-removal\f[R]
|
||||
\f[V]--for-removal\f[R]
|
||||
Limits scanning or listing to APIs that are deprecated for removal.
|
||||
Can\[aq]t be used with a release value of 6, 7, or 8.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-full\-version\f[R]
|
||||
\f[V]--full-version\f[R]
|
||||
Prints out the full version string of the tool.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-help\f[R] or \f[CB]\-h\f[R]
|
||||
\f[V]--help\f[R] or \f[V]-h\f[R]
|
||||
Prints out a full help message.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-list\f[R] or \f[CB]\-l\f[R]
|
||||
\f[V]--list\f[R] or \f[V]-l\f[R]
|
||||
Prints the set of deprecated APIs.
|
||||
No scanning is done, so no directory, jar, or class arguments should be
|
||||
provided.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-release\f[R] \f[CB]6\f[R]|\f[CB]7\f[R]|\f[CB]8\f[R]|\f[CB]9\f[R]
|
||||
\f[V]--release\f[R] \f[V]6\f[R]|\f[V]7\f[R]|\f[V]8\f[R]|\f[V]9\f[R]
|
||||
Specifies the Java SE release that provides the set of deprecated APIs
|
||||
for scanning.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-verbose\f[R] or \f[CB]\-v\f[R]
|
||||
\f[V]--verbose\f[R] or \f[V]-v\f[R]
|
||||
Enables additional message output during processing.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-version\f[R]
|
||||
\f[V]--version\f[R]
|
||||
Prints out the abbreviated version string of the tool.
|
||||
.RS
|
||||
.RE
|
||||
.SH EXAMPLE OF JDEPRSCAN OUTPUT
|
||||
.PP
|
||||
The JAR file for this library will be named something similar to
|
||||
\f[CB]commons\-math3\-3.6.1.jar\f[R].
|
||||
\f[V]commons-math3-3.6.1.jar\f[R].
|
||||
To scan this JAR file for the use of deprecated APIs, run the following
|
||||
command:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jdeprscan\ commons\-math3\-3.6.1.jar\f[R]
|
||||
\f[V]jdeprscan commons-math3-3.6.1.jar\f[R]
|
||||
.RE
|
||||
.PP
|
||||
This command produces several lines of output.
|
||||
@ -180,29 +178,29 @@ For example, one line of output might be:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
class\ org/apache/commons/math3/util/MathUtils\ uses\ deprecated\ method\ java/lang/Double::<init>(D)V
|
||||
class org/apache/commons/math3/util/MathUtils uses deprecated method java/lang/Double::<init>(D)V
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
The class name is specified using the slash\-separated binary name as
|
||||
The class name is specified using the slash-separated binary name as
|
||||
described in JVMS 4.2.1.
|
||||
This is the form used internally in class files.
|
||||
.PP
|
||||
The deprecated API it uses is a method on the \f[CB]java.lang.Double\f[R]
|
||||
The deprecated API it uses is a method on the \f[V]java.lang.Double\f[R]
|
||||
class.
|
||||
.PP
|
||||
The name of the deprecated method is \f[CB]<init>\f[R], which is a special
|
||||
name that means that the method is actually a constructor.
|
||||
Another special name is \f[CB]<clinit>\f[R], which indicates a class
|
||||
The name of the deprecated method is \f[V]<init>\f[R], which is a
|
||||
special name that means that the method is actually a constructor.
|
||||
Another special name is \f[V]<clinit>\f[R], which indicates a class
|
||||
static initializer.
|
||||
.PP
|
||||
Other methods are listed just by their method name.
|
||||
Following the method name is the argument list and return type:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB](D)V\f[R]
|
||||
\f[V](D)V\f[R]
|
||||
.RE
|
||||
.PP
|
||||
This indicates that it takes just one double value (a primitive) and
|
||||
@ -212,19 +210,19 @@ For example, another line of output might be:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
class\ org/apache/commons/math3/util/Precision\ uses\ deprecated\ method\ java/math/BigDecimal::setScale(II)Ljava/math/BigDecimal;
|
||||
class org/apache/commons/math3/util/Precision uses deprecated method java/math/BigDecimal::setScale(II)Ljava/math/BigDecimal;
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
In this line of output, the deprecated method is on class
|
||||
\f[CB]java.math.BigDecimal\f[R], and the method is \f[CB]setScale()\f[R].
|
||||
In this case, the \f[CB](II)\f[R] means that it takes two \f[CB]int\f[R]
|
||||
\f[V]java.math.BigDecimal\f[R], and the method is \f[V]setScale()\f[R].
|
||||
In this case, the \f[V](II)\f[R] means that it takes two \f[V]int\f[R]
|
||||
arguments.
|
||||
The \f[CB]Ljava/math/BigDecimal;\f[R] after the parentheses means that it
|
||||
returns a reference to \f[CB]java.math.BigDecimal\f[R].
|
||||
.SH JDEPRSCAN ANALYSIS CAN BE VERSION\-SPECIFIC
|
||||
The \f[V]Ljava/math/BigDecimal;\f[R] after the parentheses means that it
|
||||
returns a reference to \f[V]java.math.BigDecimal\f[R].
|
||||
.SH JDEPRSCAN ANALYSIS CAN BE VERSION-SPECIFIC
|
||||
.PP
|
||||
You can use \f[CB]jdeprscan\f[R] relative to the previous three JDK
|
||||
You can use \f[V]jdeprscan\f[R] relative to the previous three JDK
|
||||
releases.
|
||||
For example, if you are running JDK 9, then you can check against JDK 8,
|
||||
7, and 6.
|
||||
@ -233,41 +231,41 @@ As an example, look at this code snippet:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
public\ class\ Deprecations\ {
|
||||
\ \ \ SecurityManager\ sm\ =\ new\ RMISecurityManager();\ \ \ \ //\ deprecated\ in\ 8
|
||||
\ \ \ Boolean\ b2\ =\ new\ Boolean(true);\ \ \ \ \ \ \ \ \ \ //\ deprecated\ in\ 9
|
||||
public class Deprecations {
|
||||
SecurityManager sm = new RMISecurityManager(); // deprecated in 8
|
||||
Boolean b2 = new Boolean(true); // deprecated in 9
|
||||
}
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
The complete class compiles without warnings in JDK 7.
|
||||
.PP
|
||||
If you run \f[CB]jdeprscan\f[R] on a system with JDK 9, then you see:
|
||||
If you run \f[V]jdeprscan\f[R] on a system with JDK 9, then you see:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
$\ jdeprscan\ \-\-class\-path\ classes\ \-\-release\ 7\ example.Deprecations
|
||||
(no\ output)
|
||||
$ jdeprscan --class-path classes --release 7 example.Deprecations
|
||||
(no output)
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
Run \f[CB]jdeprscan\f[R] with a release value of 8:
|
||||
Run \f[V]jdeprscan\f[R] with a release value of 8:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
$\ jdeprscan\ \-\-class\-path\ classes\ \-\-release\ 8\ example.Deprecations
|
||||
class\ example/Deprecations\ uses\ type\ java/rmi/RMISecurityManager\ deprecated
|
||||
class\ example/Deprecations\ uses\ method\ in\ type\ java/rmi/RMISecurityManager\ deprecated
|
||||
$ jdeprscan --class-path classes --release 8 example.Deprecations
|
||||
class example/Deprecations uses type java/rmi/RMISecurityManager deprecated
|
||||
class example/Deprecations uses method in type java/rmi/RMISecurityManager deprecated
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
Run \f[CB]jdeprscan\f[R] on JDK 9:
|
||||
Run \f[V]jdeprscan\f[R] on JDK 9:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
$\ jdeprscan\ \-\-class\-path\ classes\ example.Deprecations
|
||||
class\ example/Deprecations\ uses\ type\ java/rmi/RMISecurityManager\ deprecated
|
||||
class\ example/Deprecations\ uses\ method\ in\ type\ java/rmi/RMISecurityManager\ deprecated
|
||||
class\ example/Deprecations\ uses\ method\ java/lang/Boolean\ <init>\ (Z)V\ deprecated
|
||||
$ jdeprscan --class-path classes example.Deprecations
|
||||
class example/Deprecations uses type java/rmi/RMISecurityManager deprecated
|
||||
class example/Deprecations uses method in type java/rmi/RMISecurityManager deprecated
|
||||
class example/Deprecations uses method java/lang/Boolean <init> (Z)V deprecated
|
||||
\f[R]
|
||||
.fi
|
||||
|
||||
@ -19,19 +19,33 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JDEPS" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JDEPS" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jdeps \- launch the Java class dependency analyzer
|
||||
jdeps - launch the Java class dependency analyzer
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]jdeps\f[R] [\f[I]options\f[R]] \f[I]path\f[R] ...
|
||||
\f[V]jdeps\f[R] [\f[I]options\f[R]] \f[I]path\f[R] ...
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
Command\-line options.
|
||||
\f[I]options\f[R]
|
||||
Command-line options.
|
||||
For detailed descriptions of the options that can be used, see
|
||||
.RS
|
||||
.IP \[bu] 2
|
||||
@ -44,322 +58,246 @@ For detailed descriptions of the options that can be used, see
|
||||
\f[B]Options to Filter Classes to be Analyzed\f[R]
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]path\f[R]
|
||||
A pathname to the \f[CB]\&.class\f[R] file, directory, or JAR file to
|
||||
\f[I]path\f[R]
|
||||
A pathname to the \f[V].class\f[R] file, directory, or JAR file to
|
||||
analyze.
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jdeps\f[R] command shows the package\-level or class\-level
|
||||
The \f[V]jdeps\f[R] command shows the package-level or class-level
|
||||
dependencies of Java class files.
|
||||
The input class can be a path name to a \f[CB]\&.class\f[R] file, a
|
||||
The input class can be a path name to a \f[V].class\f[R] file, a
|
||||
directory, a JAR file, or it can be a fully qualified class name to
|
||||
analyze all class files.
|
||||
The options determine the output.
|
||||
By default, the \f[CB]jdeps\f[R] command writes the dependencies to the
|
||||
By default, the \f[V]jdeps\f[R] command writes the dependencies to the
|
||||
system output.
|
||||
The command can generate the dependencies in DOT language (see the
|
||||
\f[CB]\-dotoutput\f[R] option).
|
||||
\f[V]-dotoutput\f[R] option).
|
||||
.SH POSSIBLE OPTIONS
|
||||
.TP
|
||||
.B \f[CB]\-?\f[R] or \f[CB]\-h\f[R] or \f[CB]\-\-help\f[R]
|
||||
\f[V]-?\f[R] or \f[V]-h\f[R] or \f[V]--help\f[R]
|
||||
Prints the help message.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-dotoutput\f[R] \f[I]dir\f[R] or \f[CB]\-\-dot\-output\f[R] \f[I]dir\f[R]
|
||||
\f[V]-dotoutput\f[R] \f[I]dir\f[R] or \f[V]--dot-output\f[R] \f[I]dir\f[R]
|
||||
Specifies the destination directory for DOT file output.
|
||||
If this option is specified, then the \f[CB]jdeps\f[R]command generates
|
||||
one \f[CB]\&.dot\f[R] file for each analyzed archive named
|
||||
\f[CB]archive\-file\-name.dot\f[R] that lists the dependencies, and also a
|
||||
summary file named \f[CB]summary.dot\f[R] that lists the dependencies
|
||||
If this option is specified, then the \f[V]jdeps\f[R]command generates
|
||||
one \f[V].dot\f[R] file for each analyzed archive named
|
||||
\f[V]archive-file-name.dot\f[R] that lists the dependencies, and also a
|
||||
summary file named \f[V]summary.dot\f[R] that lists the dependencies
|
||||
among the archive files.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-s\f[R] or \f[CB]\-summary\f[R]
|
||||
\f[V]-s\f[R] or \f[V]-summary\f[R]
|
||||
Prints a dependency summary only.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-v\f[R] or \f[CB]\-verbose\f[R]
|
||||
Prints all class\-level dependencies.
|
||||
\f[V]-v\f[R] or \f[V]-verbose\f[R]
|
||||
Prints all class-level dependencies.
|
||||
This is equivalent to
|
||||
.RS
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]\-verbose:class\ \-filter:none\f[R]
|
||||
\f[V]-verbose:class -filter:none\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-verbose:package\f[R]
|
||||
Prints package\-level dependencies excluding, by default, dependences
|
||||
\f[V]-verbose:package\f[R]
|
||||
Prints package-level dependencies excluding, by default, dependences
|
||||
within the same package.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-verbose:class\f[R]
|
||||
Prints class\-level dependencies excluding, by default, dependencies
|
||||
\f[V]-verbose:class\f[R]
|
||||
Prints class-level dependencies excluding, by default, dependencies
|
||||
within the same archive.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-apionly\f[R] or \f[CB]\-\-api\-only\f[R]
|
||||
\f[V]-apionly\f[R] or \f[V]--api-only\f[R]
|
||||
Restricts the analysis to APIs, for example, dependences from the
|
||||
signature of \f[CB]public\f[R] and \f[CB]protected\f[R] members of public
|
||||
signature of \f[V]public\f[R] and \f[V]protected\f[R] members of public
|
||||
classes including field type, method parameter types, returned type, and
|
||||
checked exception types.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-jdkinternals\f[R] or \f[CB]\-\-jdk\-internals\f[R]
|
||||
Finds class\-level dependences in the JDK internal APIs.
|
||||
\f[V]-jdkinternals\f[R] or \f[V]--jdk-internals\f[R]
|
||||
Finds class-level dependences in the JDK internal APIs.
|
||||
By default, this option analyzes all classes specified in the
|
||||
\f[CB]\-\-classpath\f[R] option and input files unless you specified the
|
||||
\f[CB]\-include\f[R] option.
|
||||
You can\[aq]t use this option with the \f[CB]\-p\f[R], \f[CB]\-e\f[R], and
|
||||
\f[CB]\-s\f[R] options.
|
||||
\f[V]--classpath\f[R] option and input files unless you specified the
|
||||
\f[V]-include\f[R] option.
|
||||
You can\[aq]t use this option with the \f[V]-p\f[R], \f[V]-e\f[R], and
|
||||
\f[V]-s\f[R] options.
|
||||
.RS
|
||||
.PP
|
||||
\f[B]Warning\f[R]: The JDK internal APIs are inaccessible.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-cp\f[R] \f[I]path\f[R], \f[CB]\-classpath\f[R] \f[I]path\f[R], or \f[CB]\-\-class\-path\f[R] \f[I]path\f[R]
|
||||
\f[V]-cp\f[R] \f[I]path\f[R], \f[V]-classpath\f[R] \f[I]path\f[R], or \f[V]--class-path\f[R] \f[I]path\f[R]
|
||||
Specifies where to find class files.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-module\-path\f[R] \f[I]module\-path\f[R]
|
||||
\f[V]--module-path\f[R] \f[I]module-path\f[R]
|
||||
Specifies the module path.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-upgrade\-module\-path\f[R] \f[I]module\-path\f[R]
|
||||
\f[V]--upgrade-module-path\f[R] \f[I]module-path\f[R]
|
||||
Specifies the upgrade module path.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-system\f[R] \f[I]java\-home\f[R]
|
||||
\f[V]--system\f[R] \f[I]java-home\f[R]
|
||||
Specifies an alternate system module path.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-add\-modules\f[R] \f[I]module\-name\f[R][\f[CB],\f[R] \f[I]module\-name\f[R]...]
|
||||
\f[V]--add-modules\f[R] \f[I]module-name\f[R][\f[V],\f[R] \f[I]module-name\f[R]...]
|
||||
Adds modules to the root set for analysis.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-multi\-release\f[R] \f[I]version\f[R]
|
||||
Specifies the version when processing multi\-release JAR files.
|
||||
\f[V]--multi-release\f[R] \f[I]version\f[R]
|
||||
Specifies the version when processing multi-release JAR files.
|
||||
\f[I]version\f[R] should be an integer >=9 or base.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-q\f[R] or \f[CB]\-quiet\f[R]
|
||||
\f[V]-q\f[R] or \f[V]-quiet\f[R]
|
||||
Doesn\[aq]t show missing dependencies from
|
||||
\f[CB]\-generate\-module\-info\f[R] output.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]-generate-module-info\f[R] output.
|
||||
.TP
|
||||
.B \f[CB]\-version\f[R] or \f[CB]\-\-version\f[R]
|
||||
\f[V]-version\f[R] or \f[V]--version\f[R]
|
||||
Prints version information.
|
||||
.RS
|
||||
.RE
|
||||
.SH MODULE DEPENDENCE ANALYSIS OPTIONS
|
||||
.TP
|
||||
.B \f[CB]\-m\f[R] \f[I]module\-name\f[R] or \f[CB]\-\-module\f[R] \f[I]module\-name\f[R]
|
||||
\f[V]-m\f[R] \f[I]module-name\f[R] or \f[V]--module\f[R] \f[I]module-name\f[R]
|
||||
Specifies the root module for analysis.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-generate\-module\-info\f[R] \f[I]dir\f[R]
|
||||
Generates \f[CB]module\-info.java\f[R] under the specified directory.
|
||||
\f[V]--generate-module-info\f[R] \f[I]dir\f[R]
|
||||
Generates \f[V]module-info.java\f[R] under the specified directory.
|
||||
The specified JAR files will be analyzed.
|
||||
This option cannot be used with \f[CB]\-\-dot\-output\f[R] or
|
||||
\f[CB]\-\-class\-path\f[R] options.
|
||||
Use the \f[CB]\-\-generate\-open\-module\f[R] option for open modules.
|
||||
.RS
|
||||
.RE
|
||||
This option cannot be used with \f[V]--dot-output\f[R] or
|
||||
\f[V]--class-path\f[R] options.
|
||||
Use the \f[V]--generate-open-module\f[R] option for open modules.
|
||||
.TP
|
||||
.B \f[CB]\-\-generate\-open\-module\f[R] \f[I]dir\f[R]
|
||||
Generates \f[CB]module\-info.java\f[R] for the specified JAR files under
|
||||
\f[V]--generate-open-module\f[R] \f[I]dir\f[R]
|
||||
Generates \f[V]module-info.java\f[R] for the specified JAR files under
|
||||
the specified directory as open modules.
|
||||
This option cannot be used with the \f[CB]\-\-dot\-output\f[R] or
|
||||
\f[CB]\-\-class\-path\f[R] options.
|
||||
.RS
|
||||
.RE
|
||||
This option cannot be used with the \f[V]--dot-output\f[R] or
|
||||
\f[V]--class-path\f[R] options.
|
||||
.TP
|
||||
.B \f[CB]\-\-check\f[R] \f[I]module\-name\f[R] [\f[CB],\f[R] \f[I]module\-name\f[R]...]
|
||||
\f[V]--check\f[R] \f[I]module-name\f[R] [\f[V],\f[R] \f[I]module-name\f[R]...]
|
||||
Analyzes the dependence of the specified modules.
|
||||
It prints the module descriptor, the resulting module dependences after
|
||||
analysis and the graph after transition reduction.
|
||||
It also identifies any unused qualified exports.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-list\-deps\f[R]
|
||||
\f[V]--list-deps\f[R]
|
||||
Lists the module dependences and also the package names of JDK internal
|
||||
APIs (if referenced).
|
||||
This option transitively analyzes libraries on class path and module
|
||||
path if referenced.
|
||||
Use \f[CB]\-\-no\-recursive\f[R] option for non\-transitive dependency
|
||||
Use \f[V]--no-recursive\f[R] option for non-transitive dependency
|
||||
analysis.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-list\-reduced\-deps\f[R]
|
||||
Same as \f[CB]\-\-list\-deps\f[R] without listing the implied reads edges
|
||||
\f[V]--list-reduced-deps\f[R]
|
||||
Same as \f[V]--list-deps\f[R] without listing the implied reads edges
|
||||
from the module graph.
|
||||
If module M1 reads M2, and M2 requires transitive on M3, then M1 reading
|
||||
M3 is implied and is not shown in the graph.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-print\-module\-deps\f[R]
|
||||
Same as \f[CB]\-\-list\-reduced\-deps\f[R] with printing a
|
||||
comma\-separated list of module dependences.
|
||||
The output can be used by \f[CB]jlink\ \-\-add\-modules\f[R] to create a
|
||||
\f[V]--print-module-deps\f[R]
|
||||
Same as \f[V]--list-reduced-deps\f[R] with printing a comma-separated
|
||||
list of module dependences.
|
||||
The output can be used by \f[V]jlink --add-modules\f[R] to create a
|
||||
custom image that contains those modules and their transitive
|
||||
dependences.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-ignore\-missing\-deps\f[R]
|
||||
\f[V]--ignore-missing-deps\f[R]
|
||||
Ignore missing dependences.
|
||||
.RS
|
||||
.RE
|
||||
.SH OPTIONS TO FILTER DEPENDENCES
|
||||
.TP
|
||||
.B \f[CB]\-p\f[R] \f[I]pkg_name\f[R], \f[CB]\-package\f[R] \f[I]pkg_name\f[R], or \f[CB]\-\-package\f[R] \f[I]pkg_name\f[R]
|
||||
\f[V]-p\f[R] \f[I]pkg_name\f[R], \f[V]-package\f[R] \f[I]pkg_name\f[R], or \f[V]--package\f[R] \f[I]pkg_name\f[R]
|
||||
Finds dependences matching the specified package name.
|
||||
You can specify this option multiple times for different packages.
|
||||
The \f[CB]\-p\f[R] and \f[CB]\-e\f[R] options are mutually exclusive.
|
||||
.RS
|
||||
.RE
|
||||
The \f[V]-p\f[R] and \f[V]-e\f[R] options are mutually exclusive.
|
||||
.TP
|
||||
.B \f[CB]\-e\f[R] \f[I]regex\f[R], \f[CB]\-regex\f[R] \f[I]regex\f[R], or \f[CB]\-\-regex\f[R] \f[I]regex\f[R]
|
||||
\f[V]-e\f[R] \f[I]regex\f[R], \f[V]-regex\f[R] \f[I]regex\f[R], or \f[V]--regex\f[R] \f[I]regex\f[R]
|
||||
Finds dependences matching the specified pattern.
|
||||
The \f[CB]\-p\f[R] and \f[CB]\-e\f[R] options are mutually exclusive.
|
||||
.RS
|
||||
.RE
|
||||
The \f[V]-p\f[R] and \f[V]-e\f[R] options are mutually exclusive.
|
||||
.TP
|
||||
.B \f[CB]\-\-require\f[R] \f[I]module\-name\f[R]
|
||||
\f[V]--require\f[R] \f[I]module-name\f[R]
|
||||
Finds dependences matching the given module name (may be given multiple
|
||||
times).
|
||||
The \f[CB]\-\-package\f[R], \f[CB]\-\-regex\f[R], and \f[CB]\-\-require\f[R]
|
||||
The \f[V]--package\f[R], \f[V]--regex\f[R], and \f[V]--require\f[R]
|
||||
options are mutually exclusive.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-f\f[R] \f[I]regex\f[R] or \f[CB]\-filter\f[R] \f[I]regex\f[R]
|
||||
\f[V]-f\f[R] \f[I]regex\f[R] or \f[V]-filter\f[R] \f[I]regex\f[R]
|
||||
Filters dependences matching the given pattern.
|
||||
If give multiple times, the last one will be selected.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-filter:package\f[R]
|
||||
\f[V]-filter:package\f[R]
|
||||
Filters dependences within the same package.
|
||||
This is the default.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-filter:archive\f[R]
|
||||
\f[V]-filter:archive\f[R]
|
||||
Filters dependences within the same archive.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-filter:module\f[R]
|
||||
\f[V]-filter:module\f[R]
|
||||
Filters dependences within the same module.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-filter:none\f[R]
|
||||
No \f[CB]\-filter:package\f[R] and \f[CB]\-filter:archive\f[R] filtering.
|
||||
Filtering specified via the \f[CB]\-filter\f[R] option still applies.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]-filter:none\f[R]
|
||||
No \f[V]-filter:package\f[R] and \f[V]-filter:archive\f[R] filtering.
|
||||
Filtering specified via the \f[V]-filter\f[R] option still applies.
|
||||
.TP
|
||||
.B \f[CB]\-\-missing\-deps\f[R]
|
||||
\f[V]--missing-deps\f[R]
|
||||
Finds missing dependences.
|
||||
This option cannot be used with \f[CB]\-p\f[R], \f[CB]\-e\f[R] and
|
||||
\f[CB]\-s\f[R] options.
|
||||
.RS
|
||||
.RE
|
||||
This option cannot be used with \f[V]-p\f[R], \f[V]-e\f[R] and
|
||||
\f[V]-s\f[R] options.
|
||||
.SH OPTIONS TO FILTER CLASSES TO BE ANALYZED
|
||||
.TP
|
||||
.B \f[CB]\-include\f[R] \f[I]regex\f[R]
|
||||
\f[V]-include\f[R] \f[I]regex\f[R]
|
||||
Restricts analysis to the classes matching pattern.
|
||||
This option filters the list of classes to be analyzed.
|
||||
It can be used together with \f[CB]\-p\f[R] and \f[CB]\-e\f[R], which apply
|
||||
It can be used together with \f[V]-p\f[R] and \f[V]-e\f[R], which apply
|
||||
the pattern to the dependencies.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-P\f[R] or \f[CB]\-profile\f[R]
|
||||
\f[V]-P\f[R] or \f[V]-profile\f[R]
|
||||
Shows the profile containing a package.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-R\f[R] or \f[CB]\-\-recursive\f[R]
|
||||
Recursively traverses all run\-time dependences.
|
||||
The \f[CB]\-R\f[R] option implies \f[CB]\-filter:none\f[R].
|
||||
If \f[CB]\-p\f[R], \f[CB]\-e\f[R], or \f[CB]\-f\f[R] options are specified,
|
||||
\f[V]-R\f[R] or \f[V]--recursive\f[R]
|
||||
Recursively traverses all run-time dependences.
|
||||
The \f[V]-R\f[R] option implies \f[V]-filter:none\f[R].
|
||||
If \f[V]-p\f[R], \f[V]-e\f[R], or \f[V]-f\f[R] options are specified,
|
||||
only the matching dependences are analyzed.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-no\-recursive\f[R]
|
||||
\f[V]--no-recursive\f[R]
|
||||
Do not recursively traverse dependences.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-I\f[R] or \f[CB]\-\-inverse\f[R]
|
||||
\f[V]-I\f[R] or \f[V]--inverse\f[R]
|
||||
Analyzes the dependences per other given options and then finds all
|
||||
artifacts that directly and indirectly depend on the matching nodes.
|
||||
This is equivalent to the inverse of the compile\-time view analysis and
|
||||
This is equivalent to the inverse of the compile-time view analysis and
|
||||
the print dependency summary.
|
||||
This option must be used with the \f[CB]\-\-require\f[R],
|
||||
\f[CB]\-\-package\f[R], or \f[CB]\-\-regex\f[R] options.
|
||||
.RS
|
||||
.RE
|
||||
This option must be used with the \f[V]--require\f[R],
|
||||
\f[V]--package\f[R], or \f[V]--regex\f[R] options.
|
||||
.TP
|
||||
.B \f[CB]\-\-compile\-time\f[R]
|
||||
Analyzes the compile\-time view of transitive dependencies, such as the
|
||||
compile\-time view of the \f[CB]\-R\f[R] option.
|
||||
\f[V]--compile-time\f[R]
|
||||
Analyzes the compile-time view of transitive dependencies, such as the
|
||||
compile-time view of the \f[V]-R\f[R] option.
|
||||
Analyzes the dependences per other specified options.
|
||||
If a dependency is found from a directory, a JAR file or a module, all
|
||||
classes in that containing archive are analyzed.
|
||||
.RS
|
||||
.RE
|
||||
.SH EXAMPLE OF ANALYZING DEPENDENCIES
|
||||
.PP
|
||||
The following example demonstrates analyzing the dependencies of the
|
||||
\f[CB]Notepad.jar\f[R] file.
|
||||
\f[V]Notepad.jar\f[R] file.
|
||||
.PP
|
||||
\f[B]Linux and OS X:\f[R]
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
$\ jdeps\ demo/jfc/Notepad/Notepad.jar
|
||||
Notepad.jar\ \->\ java.base
|
||||
Notepad.jar\ \->\ java.desktop
|
||||
Notepad.jar\ \->\ java.logging
|
||||
\ \ \ <unnamed>\ (Notepad.jar)
|
||||
\ \ \ \ \ \ \->\ java.awt
|
||||
\ \ \ \ \ \ \->\ java.awt.event
|
||||
\ \ \ \ \ \ \->\ java.beans
|
||||
\ \ \ \ \ \ \->\ java.io
|
||||
\ \ \ \ \ \ \->\ java.lang
|
||||
\ \ \ \ \ \ \->\ java.net
|
||||
\ \ \ \ \ \ \->\ java.util
|
||||
\ \ \ \ \ \ \->\ java.util.logging
|
||||
\ \ \ \ \ \ \->\ javax.swing
|
||||
\ \ \ \ \ \ \->\ javax.swing.border
|
||||
\ \ \ \ \ \ \->\ javax.swing.event
|
||||
\ \ \ \ \ \ \->\ javax.swing.text
|
||||
\ \ \ \ \ \ \->\ javax.swing.tree
|
||||
\ \ \ \ \ \ \->\ javax.swing.undo
|
||||
$ jdeps demo/jfc/Notepad/Notepad.jar
|
||||
Notepad.jar -> java.base
|
||||
Notepad.jar -> java.desktop
|
||||
Notepad.jar -> java.logging
|
||||
<unnamed> (Notepad.jar)
|
||||
-> java.awt
|
||||
-> java.awt.event
|
||||
-> java.beans
|
||||
-> java.io
|
||||
-> java.lang
|
||||
-> java.net
|
||||
-> java.util
|
||||
-> java.util.logging
|
||||
-> javax.swing
|
||||
-> javax.swing.border
|
||||
-> javax.swing.event
|
||||
-> javax.swing.text
|
||||
-> javax.swing.tree
|
||||
-> javax.swing.undo
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
@ -367,37 +305,37 @@ Notepad.jar\ \->\ java.logging
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
C:\\Java\\jdk1.9.0>jdeps\ demo\\jfc\\Notepad\\Notepad.jar
|
||||
Notepad.jar\ \->\ java.base
|
||||
Notepad.jar\ \->\ java.desktop
|
||||
Notepad.jar\ \->\ java.logging
|
||||
\ \ \ <unnamed>\ (Notepad.jar)
|
||||
\ \ \ \ \ \ \->\ java.awt
|
||||
\ \ \ \ \ \ \->\ java.awt.event
|
||||
\ \ \ \ \ \ \->\ java.beans
|
||||
\ \ \ \ \ \ \->\ java.io
|
||||
\ \ \ \ \ \ \->\ java.lang
|
||||
\ \ \ \ \ \ \->\ java.net
|
||||
\ \ \ \ \ \ \->\ java.util
|
||||
\ \ \ \ \ \ \->\ java.util.logging
|
||||
\ \ \ \ \ \ \->\ javax.swing
|
||||
\ \ \ \ \ \ \->\ javax.swing.border
|
||||
\ \ \ \ \ \ \->\ javax.swing.event
|
||||
\ \ \ \ \ \ \->\ javax.swing.text
|
||||
\ \ \ \ \ \ \->\ javax.swing.tree
|
||||
\ \ \ \ \ \ \->\ javax.swing.undo
|
||||
C:\[rs]Java\[rs]jdk1.9.0>jdeps demo\[rs]jfc\[rs]Notepad\[rs]Notepad.jar
|
||||
Notepad.jar -> java.base
|
||||
Notepad.jar -> java.desktop
|
||||
Notepad.jar -> java.logging
|
||||
<unnamed> (Notepad.jar)
|
||||
-> java.awt
|
||||
-> java.awt.event
|
||||
-> java.beans
|
||||
-> java.io
|
||||
-> java.lang
|
||||
-> java.net
|
||||
-> java.util
|
||||
-> java.util.logging
|
||||
-> javax.swing
|
||||
-> javax.swing.border
|
||||
-> javax.swing.event
|
||||
-> javax.swing.text
|
||||
-> javax.swing.tree
|
||||
-> javax.swing.undo
|
||||
\f[R]
|
||||
.fi
|
||||
.SH EXAMPLE USING THE \-\-INVERSE OPTION
|
||||
.SH EXAMPLE USING THE --INVERSE OPTION
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
\ $\ jdeps\ \-\-inverse\ \-\-require\ java.xml.bind
|
||||
Inverse\ transitive\ dependences\ on\ [java.xml.bind]
|
||||
java.xml.bind\ <\-\ java.se.ee
|
||||
java.xml.bind\ <\-\ jdk.xml.ws
|
||||
java.xml.bind\ <\-\ java.xml.ws\ <\-\ java.se.ee
|
||||
java.xml.bind\ <\-\ java.xml.ws\ <\-\ jdk.xml.ws
|
||||
java.xml.bind\ <\-\ jdk.xml.bind\ <\-\ jdk.xml.ws
|
||||
$ jdeps --inverse --require java.xml.bind
|
||||
Inverse transitive dependences on [java.xml.bind]
|
||||
java.xml.bind <- java.se.ee
|
||||
java.xml.bind <- jdk.xml.ws
|
||||
java.xml.bind <- java.xml.ws <- java.se.ee
|
||||
java.xml.bind <- java.xml.ws <- jdk.xml.ws
|
||||
java.xml.bind <- jdk.xml.bind <- jdk.xml.ws
|
||||
\f[R]
|
||||
.fi
|
||||
|
||||
@ -19,40 +19,48 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JDB" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JDB" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jdb \- find and fix bugs in Java platform programs
|
||||
jdb - find and fix bugs in Java platform programs
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]jdb\f[R] [\f[I]options\f[R]] [\f[I]classname\f[R]]
|
||||
\f[V]jdb\f[R] [\f[I]options\f[R]] [\f[I]classname\f[R]]
|
||||
[\f[I]arguments\f[R]]
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
This represents the \f[CB]jdb\f[R] command\-line options.
|
||||
\f[I]options\f[R]
|
||||
This represents the \f[V]jdb\f[R] command-line options.
|
||||
See \f[B]Options for the jdb command\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]classname\f[R]
|
||||
\f[I]classname\f[R]
|
||||
This represents the name of the main class to debug.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]arguments\f[R]
|
||||
This represents the arguments that are passed to the \f[CB]main()\f[R]
|
||||
\f[I]arguments\f[R]
|
||||
This represents the arguments that are passed to the \f[V]main()\f[R]
|
||||
method of the class.
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The Java Debugger (JDB) is a simple command\-line debugger for Java
|
||||
The Java Debugger (JDB) is a simple command-line debugger for Java
|
||||
classes.
|
||||
The \f[CB]jdb\f[R] command and its options call the JDB.
|
||||
The \f[CB]jdb\f[R] command demonstrates the Java Platform Debugger
|
||||
The \f[V]jdb\f[R] command and its options call the JDB.
|
||||
The \f[V]jdb\f[R] command demonstrates the Java Platform Debugger
|
||||
Architecture and provides inspection and debugging of a local or remote
|
||||
JVM.
|
||||
.SH START A JDB SESSION
|
||||
@ -60,45 +68,45 @@ JVM.
|
||||
There are many ways to start a JDB session.
|
||||
The most frequently used way is to have the JDB launch a new JVM with
|
||||
the main class of the application to be debugged.
|
||||
Do this by substituting the \f[CB]jdb\f[R] command for the \f[CB]java\f[R]
|
||||
Do this by substituting the \f[V]jdb\f[R] command for the \f[V]java\f[R]
|
||||
command in the command line.
|
||||
For example, if your application\[aq]s main class is \f[CB]MyClass\f[R],
|
||||
For example, if your application\[aq]s main class is \f[V]MyClass\f[R],
|
||||
then use the following command to debug it under the JDB:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jdb\ MyClass\f[R]
|
||||
\f[V]jdb MyClass\f[R]
|
||||
.RE
|
||||
.PP
|
||||
When started this way, the \f[CB]jdb\f[R] command calls a second JVM with
|
||||
When started this way, the \f[V]jdb\f[R] command calls a second JVM with
|
||||
the specified parameters, loads the specified class, and stops the JVM
|
||||
before executing that class\[aq]s first instruction.
|
||||
.PP
|
||||
Another way to use the \f[CB]jdb\f[R] command is by attaching it to a JVM
|
||||
Another way to use the \f[V]jdb\f[R] command is by attaching it to a JVM
|
||||
that\[aq]s already running.
|
||||
Syntax for starting a JVM to which the \f[CB]jdb\f[R] command attaches
|
||||
Syntax for starting a JVM to which the \f[V]jdb\f[R] command attaches
|
||||
when the JVM is running is as follows.
|
||||
This loads in\-process debugging libraries and specifies the kind of
|
||||
This loads in-process debugging libraries and specifies the kind of
|
||||
connection to be made.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]java\ \-agentlib:jdwp=transport=dt_socket,server=y,suspend=n\ MyClass\f[R]
|
||||
\f[V]java -agentlib:jdwp=transport=dt_socket,server=y,suspend=n MyClass\f[R]
|
||||
.RE
|
||||
.PP
|
||||
You can then attach the \f[CB]jdb\f[R] command to the JVM with the
|
||||
You can then attach the \f[V]jdb\f[R] command to the JVM with the
|
||||
following command:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jdb\ \-attach\ 8000\f[R]
|
||||
\f[V]jdb -attach 8000\f[R]
|
||||
.RE
|
||||
.PP
|
||||
8000 is the address of the running JVM.
|
||||
.PP
|
||||
The \f[CB]MyClass\f[R] argument isn\[aq]t specified in the \f[CB]jdb\f[R]
|
||||
command line in this case because the \f[CB]jdb\f[R] command is connecting
|
||||
to an existing JVM instead of launching a new JVM.
|
||||
The \f[V]MyClass\f[R] argument isn\[aq]t specified in the \f[V]jdb\f[R]
|
||||
command line in this case because the \f[V]jdb\f[R] command is
|
||||
connecting to an existing JVM instead of launching a new JVM.
|
||||
.PP
|
||||
There are many other ways to connect the debugger to a JVM, and all of
|
||||
them are supported by the \f[CB]jdb\f[R] command.
|
||||
them are supported by the \f[V]jdb\f[R] command.
|
||||
The Java Platform Debugger Architecture has additional documentation on
|
||||
these connection options.
|
||||
.SH BREAKPOINTS
|
||||
@ -106,175 +114,139 @@ these connection options.
|
||||
Breakpoints can be set in the JDB at line numbers or at the first
|
||||
instruction of a method, for example:
|
||||
.IP \[bu] 2
|
||||
The command \f[CB]stop\ at\ MyClass:22\f[R] sets a breakpoint at the first
|
||||
instruction for line 22 of the source file containing \f[CB]MyClass\f[R].
|
||||
The command \f[V]stop at MyClass:22\f[R] sets a breakpoint at the first
|
||||
instruction for line 22 of the source file containing \f[V]MyClass\f[R].
|
||||
.IP \[bu] 2
|
||||
The command \f[CB]stop\ in\ java.lang.String.length\f[R] sets a breakpoint
|
||||
at the beginning of the method \f[CB]java.lang.String.length\f[R].
|
||||
The command \f[V]stop in java.lang.String.length\f[R] sets a breakpoint
|
||||
at the beginning of the method \f[V]java.lang.String.length\f[R].
|
||||
.IP \[bu] 2
|
||||
The command \f[CB]stop\ in\ MyClass.<clinit>\f[R] uses \f[CB]<clinit>\f[R]
|
||||
to identify the static initialization code for \f[CB]MyClass\f[R].
|
||||
The command \f[V]stop in MyClass.<clinit>\f[R] uses \f[V]<clinit>\f[R]
|
||||
to identify the static initialization code for \f[V]MyClass\f[R].
|
||||
.PP
|
||||
When a method is overloaded, you must also specify its argument types so
|
||||
that the proper method can be selected for a breakpoint.
|
||||
For example, \f[CB]MyClass.myMethod(int,java.lang.String)\f[R] or
|
||||
\f[CB]MyClass.myMethod()\f[R].
|
||||
For example, \f[V]MyClass.myMethod(int,java.lang.String)\f[R] or
|
||||
\f[V]MyClass.myMethod()\f[R].
|
||||
.PP
|
||||
The \f[CB]clear\f[R] command removes breakpoints using the following
|
||||
syntax: \f[CB]clear\ MyClass:45\f[R].
|
||||
Using the \f[CB]clear\f[R] or \f[CB]stop\f[R] command with no argument
|
||||
The \f[V]clear\f[R] command removes breakpoints using the following
|
||||
syntax: \f[V]clear MyClass:45\f[R].
|
||||
Using the \f[V]clear\f[R] or \f[V]stop\f[R] command with no argument
|
||||
displays a list of all breakpoints currently set.
|
||||
The \f[CB]cont\f[R] command continues execution.
|
||||
The \f[V]cont\f[R] command continues execution.
|
||||
.SH STEPPING
|
||||
.PP
|
||||
The \f[CB]step\f[R] command advances execution to the next line whether
|
||||
The \f[V]step\f[R] command advances execution to the next line whether
|
||||
it\[aq]s in the current stack frame or a called method.
|
||||
The \f[CB]next\f[R] command advances execution to the next line in the
|
||||
The \f[V]next\f[R] command advances execution to the next line in the
|
||||
current stack frame.
|
||||
.SH EXCEPTIONS
|
||||
.PP
|
||||
When an exception occurs for which there isn\[aq]t a \f[CB]catch\f[R]
|
||||
When an exception occurs for which there isn\[aq]t a \f[V]catch\f[R]
|
||||
statement anywhere in the throwing thread\[aq]s call stack, the JVM
|
||||
typically prints an exception trace and exits.
|
||||
When running under the JDB, however, control returns to the JDB at the
|
||||
offending throw.
|
||||
You can then use the \f[CB]jdb\f[R] command to diagnose the cause of the
|
||||
You can then use the \f[V]jdb\f[R] command to diagnose the cause of the
|
||||
exception.
|
||||
.PP
|
||||
Use the \f[CB]catch\f[R] command to cause the debugged application to stop
|
||||
at other thrown exceptions, for example:
|
||||
\f[CB]catch\ java.io.FileNotFoundException\f[R] or \f[CB]catch\f[R]
|
||||
\f[CB]mypackage.BigTroubleException\f[R].
|
||||
Use the \f[V]catch\f[R] command to cause the debugged application to
|
||||
stop at other thrown exceptions, for example:
|
||||
\f[V]catch java.io.FileNotFoundException\f[R] or \f[V]catch\f[R]
|
||||
\f[V]mypackage.BigTroubleException\f[R].
|
||||
Any exception that\[aq]s an instance of the specified class or subclass
|
||||
stops the application at the point where the exception is thrown.
|
||||
.PP
|
||||
The \f[CB]ignore\f[R] command negates the effect of an earlier
|
||||
\f[CB]catch\f[R] command.
|
||||
The \f[CB]ignore\f[R] command doesn\[aq]t cause the debugged JVM to ignore
|
||||
specific exceptions, but only to ignore the debugger.
|
||||
The \f[V]ignore\f[R] command negates the effect of an earlier
|
||||
\f[V]catch\f[R] command.
|
||||
The \f[V]ignore\f[R] command doesn\[aq]t cause the debugged JVM to
|
||||
ignore specific exceptions, but only to ignore the debugger.
|
||||
.SH OPTIONS FOR THE JDB COMMAND
|
||||
.PP
|
||||
When you use the \f[CB]jdb\f[R] command instead of the \f[CB]java\f[R]
|
||||
command on the command line, the \f[CB]jdb\f[R] command accepts many of
|
||||
the same options as the \f[CB]java\f[R] command.
|
||||
When you use the \f[V]jdb\f[R] command instead of the \f[V]java\f[R]
|
||||
command on the command line, the \f[V]jdb\f[R] command accepts many of
|
||||
the same options as the \f[V]java\f[R] command.
|
||||
.PP
|
||||
The following options are accepted by the \f[CB]jdb\f[R] command:
|
||||
The following options are accepted by the \f[V]jdb\f[R] command:
|
||||
.TP
|
||||
.B \f[CB]\-help\f[R]
|
||||
\f[V]-help\f[R]
|
||||
Displays a help message.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-sourcepath\f[R] \f[I]dir1\f[R]\f[CB]:\f[R]\f[I]dir2\f[R]\f[CB]:\f[R]...
|
||||
\f[V]-sourcepath\f[R] \f[I]dir1\f[R]\f[V]:\f[R]\f[I]dir2\f[R]\f[V]:\f[R]...
|
||||
Uses the specified path to search for source files in the specified
|
||||
path.
|
||||
If this option is not specified, then use the default path of dot
|
||||
(\f[CB]\&.\f[R]).
|
||||
.RS
|
||||
.RE
|
||||
(\f[V].\f[R]).
|
||||
.TP
|
||||
.B \f[CB]\-attach\f[R] \f[I]address\f[R]
|
||||
\f[V]-attach\f[R] \f[I]address\f[R]
|
||||
Attaches the debugger to a running JVM with the default connection
|
||||
mechanism.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-listen\f[R] \f[I]address\f[R]
|
||||
\f[V]-listen\f[R] \f[I]address\f[R]
|
||||
Waits for a running JVM to connect to the specified address with a
|
||||
standard connector.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-listenany\f[R]
|
||||
\f[V]-listenany\f[R]
|
||||
Waits for a running JVM to connect at any available address using a
|
||||
standard connector.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-launch\f[R]
|
||||
\f[V]-launch\f[R]
|
||||
Starts the debugged application immediately upon startup of the
|
||||
\f[CB]jdb\f[R] command.
|
||||
The \f[CB]\-launch\f[R] option removes the need for the \f[CB]run\f[R]
|
||||
\f[V]jdb\f[R] command.
|
||||
The \f[V]-launch\f[R] option removes the need for the \f[V]run\f[R]
|
||||
command.
|
||||
The debugged application is launched and then stopped just before the
|
||||
initial application class is loaded.
|
||||
At that point, you can set any necessary breakpoints and use the
|
||||
\f[CB]cont\f[R] command to continue execution.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]cont\f[R] command to continue execution.
|
||||
.TP
|
||||
.B \f[CB]\-listconnectors\f[R]
|
||||
\f[V]-listconnectors\f[R]
|
||||
Lists the connectors available in this JVM.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-connect\f[R] \f[I]connector\-name\f[R]\f[CB]:\f[R]\f[I]name1\f[R]\f[CB]=\f[R]\f[I]value1\f[R]....
|
||||
\f[V]-connect\f[R] \f[I]connector-name\f[R]\f[V]:\f[R]\f[I]name1\f[R]\f[V]=\f[R]\f[I]value1\f[R]....
|
||||
Connects to the target JVM with the named connector and listed argument
|
||||
values.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-dbgtrace\f[R] [\f[I]flags\f[R]]
|
||||
Prints information for debugging the \f[CB]jdb\f[R] command.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]-dbgtrace\f[R] [\f[I]flags\f[R]]
|
||||
Prints information for debugging the \f[V]jdb\f[R] command.
|
||||
.TP
|
||||
.B \f[CB]\-tclient\f[R]
|
||||
\f[V]-tclient\f[R]
|
||||
Runs the application in the Java HotSpot VM client.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-trackallthreads\f[R]
|
||||
\f[V]-trackallthreads\f[R]
|
||||
Track all threads as they are created, including virtual threads.
|
||||
See \f[B]Working With Virtual Threads\f[R] below.
|
||||
Virtual threads are a preview feature of the Java platform.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-tserver\f[R]
|
||||
\f[V]-tserver\f[R]
|
||||
Runs the application in the Java HotSpot VM server.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-J\f[R]\f[I]option\f[R]
|
||||
\f[V]-J\f[R]\f[I]option\f[R]
|
||||
Passes \f[I]option\f[R] to the JDB JVM, where option is one of the
|
||||
options described on the reference page for the Java application
|
||||
launcher.
|
||||
For example, \f[CB]\-J\-Xms48m\f[R] sets the startup memory to 48 MB.
|
||||
For example, \f[V]-J-Xms48m\f[R] sets the startup memory to 48 MB.
|
||||
See \f[I]Overview of Java Options\f[R] in \f[B]java\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.PP
|
||||
The following options are forwarded to the debuggee process:
|
||||
.TP
|
||||
.B \f[CB]\-R\f[R]\f[I]option\f[R]
|
||||
\f[V]-R\f[R]\f[I]option\f[R]
|
||||
Passes \f[I]option\f[R] to the debuggee JVM, where option is one of the
|
||||
options described on the reference page for the Java application
|
||||
launcher.
|
||||
For example, \f[CB]\-R\-Xms48m\f[R] sets the startup memory to 48 MB.
|
||||
For example, \f[V]-R-Xms48m\f[R] sets the startup memory to 48 MB.
|
||||
See \f[I]Overview of Java Options\f[R] in \f[B]java\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-v\f[R] or \f[CB]\-verbose\f[R][\f[CB]:\f[R]\f[I]class\f[R]|\f[CB]gc\f[R]|\f[CB]jni\f[R]]
|
||||
\f[V]-v\f[R] or \f[V]-verbose\f[R][\f[V]:\f[R]\f[I]class\f[R]|\f[V]gc\f[R]|\f[V]jni\f[R]]
|
||||
Turns on the verbose mode.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-D\f[R]\f[I]name\f[R]\f[CB]=\f[R]\f[I]value\f[R]
|
||||
\f[V]-D\f[R]\f[I]name\f[R]\f[V]=\f[R]\f[I]value\f[R]
|
||||
Sets a system property.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-classpath\f[R] \f[I]dir\f[R]
|
||||
\f[V]-classpath\f[R] \f[I]dir\f[R]
|
||||
Lists directories separated by colons in which to look for classes.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-X\f[R] \f[I]option\f[R]
|
||||
\f[V]-X\f[R] \f[I]option\f[R]
|
||||
A nonstandard target JVM option.
|
||||
.RS
|
||||
.RE
|
||||
.PP
|
||||
Other options are supported to provide alternate mechanisms for
|
||||
connecting the debugger to the JVM that it\[aq]s to debug.
|
||||
@ -290,7 +262,7 @@ For this reason by default JDB does not keep track of virtual threads as
|
||||
they are created.
|
||||
It will only keep track of virtual threads that an event has arrived on,
|
||||
such as a breakpoint event.
|
||||
The \f[CB]\-trackallthreads\f[R] option can be used to make JDB track all
|
||||
The \f[V]-trackallthreads\f[R] option can be used to make JDB track all
|
||||
virtual threads as they are created.
|
||||
.PP
|
||||
When JDB first connects, it requests a list of all known threads from
|
||||
@ -298,12 +270,12 @@ the Debug Agent.
|
||||
By default the debug agent does not return any virtual threads in this
|
||||
list, once again because the list could be so large that it overwhelms
|
||||
the debugger.
|
||||
The Debug Agent has an \f[CB]includevirtualthreads\f[R] option that can be
|
||||
enabled to change this behavior so all known virtual threads will be
|
||||
The Debug Agent has an \f[V]includevirtualthreads\f[R] option that can
|
||||
be enabled to change this behavior so all known virtual threads will be
|
||||
included in the list.
|
||||
The JDB \f[CB]\-trackallthreads\f[R] option will cause JDB to
|
||||
The JDB \f[V]-trackallthreads\f[R] option will cause JDB to
|
||||
automatically enable the Debug Agent\[aq]s
|
||||
\f[CB]includevirtualthreads\f[R] option when JDB launches an application
|
||||
\f[V]includevirtualthreads\f[R] option when JDB launches an application
|
||||
to debug.
|
||||
However, keep in mind that the Debug Agent may not know about any
|
||||
virtual threads that were created before JDB attached to the debugged
|
||||
|
||||
@ -19,57 +19,64 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JFR" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JFR" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jfr \- parse and print Flight Recorder files
|
||||
jfr - parse and print Flight Recorder files
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
To print the contents of a flight recording to standard out:
|
||||
.PP
|
||||
\f[CB]jfr\f[R] \f[CB]print\f[R] [\f[I]options\f[R]] \f[I]file\f[R]
|
||||
\f[V]jfr\f[R] \f[V]print\f[R] [\f[I]options\f[R]] \f[I]file\f[R]
|
||||
.PP
|
||||
To print metadata information about flight recording events:
|
||||
.PP
|
||||
\f[CB]jfr\f[R] \f[CB]metadata\f[R] \f[I]file\f[R]
|
||||
\f[V]jfr\f[R] \f[V]metadata\f[R] \f[I]file\f[R]
|
||||
.PP
|
||||
To assemble chunk files into a flight recording file:
|
||||
.PP
|
||||
\f[CB]jfr\f[R] \f[CB]assemble\f[R] \f[I]repository\f[R] \f[I]file\f[R]
|
||||
\f[V]jfr\f[R] \f[V]assemble\f[R] \f[I]repository\f[R] \f[I]file\f[R]
|
||||
.PP
|
||||
To disassemble a flight recording file into chunk files:
|
||||
.PP
|
||||
\f[CB]jfr\f[R] \f[CB]disassmble\f[R] [\f[I]options\f[R]] \f[I]file\f[R]
|
||||
\f[V]jfr\f[R] \f[V]disassmble\f[R] [\f[I]options\f[R]] \f[I]file\f[R]
|
||||
.PP
|
||||
To view the summary statistics for a flight recording file:
|
||||
.PP
|
||||
\f[CB]jfr\f[R] \f[CB]summary\f[R] \f[I]file\f[R]
|
||||
\f[V]jfr\f[R] \f[V]summary\f[R] \f[I]file\f[R]
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
Optional: Specifies command\-line options separated by spaces.
|
||||
\f[I]options\f[R]
|
||||
Optional: Specifies command-line options separated by spaces.
|
||||
See the individual subcomponent sections for descriptions of the
|
||||
available options.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]file\f[R]
|
||||
Specifies the name of the target flight recording file
|
||||
(\f[CB]\&.jfr\f[R]).
|
||||
.RS
|
||||
.RE
|
||||
\f[I]file\f[R]
|
||||
Specifies the name of the target flight recording file (\f[V].jfr\f[R]).
|
||||
.TP
|
||||
.B \f[I]repository\f[R]
|
||||
\f[I]repository\f[R]
|
||||
Specifies the location of the chunk files which are to be assembled into
|
||||
a flight recording.
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jfr\f[R] command provides a tool for interacting with flight
|
||||
recorder files (\f[CB]\&.jfr\f[R]).
|
||||
The \f[V]jfr\f[R] command provides a tool for interacting with flight
|
||||
recorder files (\f[V].jfr\f[R]).
|
||||
The main function is to filter, summarize and output flight recording
|
||||
files into human readable format.
|
||||
There is also support for merging and splitting recording files.
|
||||
@ -80,77 +87,65 @@ manipulate the contents and translate them into human readable format
|
||||
helps developers to debug performance issues with Java applications.
|
||||
.SS Subcommands
|
||||
.PP
|
||||
The \f[CB]jfr\f[R] command has several subcommands:
|
||||
The \f[V]jfr\f[R] command has several subcommands:
|
||||
.IP \[bu] 2
|
||||
\f[CB]print\f[R]
|
||||
\f[V]print\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]summary\f[R]
|
||||
\f[V]summary\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]assemble\f[R]
|
||||
\f[V]assemble\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]disassemble\f[R]
|
||||
\f[V]disassemble\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]metadata\f[R]
|
||||
.SS \f[CB]jfr\ print\f[R] subcommand
|
||||
\f[V]metadata\f[R]
|
||||
.SS \f[V]jfr print\f[R] subcommand
|
||||
.PP
|
||||
Use \f[CB]jfr\ print\f[R] to print the contents of a flight recording file
|
||||
Use \f[V]jfr print\f[R] to print the contents of a flight recording file
|
||||
to standard out.
|
||||
The syntax is:
|
||||
.PP
|
||||
\f[CB]jfr\ print\f[R] [\f[CB]\-\-xml\f[R]|\f[CB]\-\-json\f[R]]
|
||||
[\f[CB]\-\-categories\f[R] <\f[I]filters\f[R]>] [\f[CB]\-\-events\f[R]
|
||||
<\f[I]filters\f[R]>] [\f[CB]\-\-stack\-depth\f[R] <\f[I]depth\f[R]>]
|
||||
\f[V]jfr print\f[R] [\f[V]--xml\f[R]|\f[V]--json\f[R]]
|
||||
[\f[V]--categories\f[R] <\f[I]filters\f[R]>] [\f[V]--events\f[R]
|
||||
<\f[I]filters\f[R]>] [\f[V]--stack-depth\f[R] <\f[I]depth\f[R]>]
|
||||
<\f[I]file\f[R]>
|
||||
.PP
|
||||
where:
|
||||
.TP
|
||||
.B \f[CB]\-\-xml\f[R]
|
||||
\f[V]--xml\f[R]
|
||||
Print the recording in XML format
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-json\f[R]
|
||||
\f[V]--json\f[R]
|
||||
Print the recording in JSON format
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-categories\f[R] <\f[I]filters\f[R]>
|
||||
\f[V]--categories\f[R] <\f[I]filters\f[R]>
|
||||
Select events matching a category name.
|
||||
The filter is a comma\-separated list of names, simple and/or qualified,
|
||||
The filter is a comma-separated list of names, simple and/or qualified,
|
||||
and/or quoted glob patterns
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-events\f[R] <\f[I]filters\f[R]>
|
||||
\f[V]--events\f[R] <\f[I]filters\f[R]>
|
||||
Select events matching an event name.
|
||||
The filter is a comma\-separated list of names, simple and/or qualified,
|
||||
The filter is a comma-separated list of names, simple and/or qualified,
|
||||
and/or quoted glob patterns
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-stack\-depth\f[R] <\f[I]depth\f[R]>
|
||||
\f[V]--stack-depth\f[R] <\f[I]depth\f[R]>
|
||||
Number of frames in stack traces, by default 5
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B <\f[I]file\f[R]>
|
||||
Location of the recording file (\f[CB]\&.jfr\f[R])
|
||||
.RS
|
||||
.RE
|
||||
<\f[I]file\f[R]>
|
||||
Location of the recording file (\f[V].jfr\f[R])
|
||||
.PP
|
||||
The default format for printing the contents of the flight recording
|
||||
file is human readable form unless either \f[CB]xml\f[R] or \f[CB]json\f[R]
|
||||
is specified.
|
||||
These options provide machine\-readable output that can be further
|
||||
parsed or processed by user created scripts.
|
||||
file is human readable form unless either \f[V]xml\f[R] or
|
||||
\f[V]json\f[R] is specified.
|
||||
These options provide machine-readable output that can be further parsed
|
||||
or processed by user created scripts.
|
||||
.PP
|
||||
Use \f[CB]jfr\ \-\-help\ print\f[R] to see example usage of filters.
|
||||
Use \f[V]jfr --help print\f[R] to see example usage of filters.
|
||||
.PP
|
||||
To reduce the amount of data displayed, it is possible to filter out
|
||||
events or categories of events.
|
||||
The filter operates on the symbolic name of an event, set by using the
|
||||
\f[CB]\@Name\f[R] annotation, or the category name, set by using the
|
||||
\f[CB]\@Category\f[R] annotation.
|
||||
\f[V]\[at]Name\f[R] annotation, or the category name, set by using the
|
||||
\f[V]\[at]Category\f[R] annotation.
|
||||
If multiple filters are used, events from both filters will be included.
|
||||
If no filter is used, all the events will be printed.
|
||||
If a combination of a category filter and event filter is used, the
|
||||
@ -159,19 +154,19 @@ selected events will be the union of the two filters.
|
||||
For example, to show all GC events and the CPULoad event, the following
|
||||
command could be used:
|
||||
.PP
|
||||
\f[CB]jfr\ print\ \-\-categories\ GC\ \-\-events\ CPULoad\ recording.jfr\f[R]
|
||||
\f[V]jfr print --categories GC --events CPULoad recording.jfr\f[R]
|
||||
.PP
|
||||
Event values are formatted according to the content types that are being
|
||||
used.
|
||||
For example, a field with the \f[CB]jdk.jfr.Percentage\f[R] annotation
|
||||
For example, a field with the \f[V]jdk.jfr.Percentage\f[R] annotation
|
||||
that has the value 0.52 is formatted as 52%.
|
||||
.PP
|
||||
Stack traces are by default truncated to 5 frames, but the number can be
|
||||
increased/decreased using the \f[CB]\-\-stack\-depth\f[R] command\-line
|
||||
increased/decreased using the \f[V]--stack-depth\f[R] command-line
|
||||
option.
|
||||
.SS \f[CB]jfr\ summary\f[R] subcommand
|
||||
.SS \f[V]jfr summary\f[R] subcommand
|
||||
.PP
|
||||
Use \f[CB]jfr\ summary\f[R] to print statistics for a recording.
|
||||
Use \f[V]jfr summary\f[R] to print statistics for a recording.
|
||||
For example, a summary can illustrate the number of recorded events and
|
||||
how much disk space they used.
|
||||
This is useful for troubleshooting and understanding the impact of event
|
||||
@ -179,117 +174,102 @@ settings.
|
||||
.PP
|
||||
The syntax is:
|
||||
.PP
|
||||
\f[CB]jfr\ summary\f[R] <\f[I]file\f[R]>
|
||||
\f[V]jfr summary\f[R] <\f[I]file\f[R]>
|
||||
.PP
|
||||
where:
|
||||
.TP
|
||||
.B <\f[I]file\f[R]>
|
||||
Location of the flight recording file (\f[CB]\&.jfr\f[R])
|
||||
.RS
|
||||
.RE
|
||||
.SS \f[CB]jfr\ metadata\f[R] subcommand
|
||||
<\f[I]file\f[R]>
|
||||
Location of the flight recording file (\f[V].jfr\f[R])
|
||||
.SS \f[V]jfr metadata\f[R] subcommand
|
||||
.PP
|
||||
Use \f[CB]jfr\ metadata\f[R] to view information about events, such as
|
||||
Use \f[V]jfr metadata\f[R] to view information about events, such as
|
||||
event names, categories and field layout within a flight recording file.
|
||||
The syntax is:
|
||||
.PP
|
||||
\f[CB]jfr\ metadata\f[R] <\f[I]file\f[R]>
|
||||
\f[V]jfr metadata\f[R] <\f[I]file\f[R]>
|
||||
.PP
|
||||
where:
|
||||
.TP
|
||||
.B <\f[I]file\f[R]>
|
||||
Location of the flight recording file (\f[CB]\&.jfr\f[R])
|
||||
.RS
|
||||
.RE
|
||||
.SS jfr \f[CB]assemble\f[R] subcommand
|
||||
<\f[I]file\f[R]>
|
||||
Location of the flight recording file (\f[V].jfr\f[R])
|
||||
.SS jfr \f[V]assemble\f[R] subcommand
|
||||
.PP
|
||||
Use jfr \f[CB]assemble\f[R] to assemble chunk files into a recording file.
|
||||
Use jfr \f[V]assemble\f[R] to assemble chunk files into a recording
|
||||
file.
|
||||
.PP
|
||||
The syntax is:
|
||||
.PP
|
||||
\f[CB]jfr\ assemble\f[R] <\f[I]repository\f[R]> <\f[I]file\f[R]>
|
||||
\f[V]jfr assemble\f[R] <\f[I]repository\f[R]> <\f[I]file\f[R]>
|
||||
.PP
|
||||
where:
|
||||
.TP
|
||||
.B <\f[I]repository\f[R]>
|
||||
<\f[I]repository\f[R]>
|
||||
Directory where the repository containing chunk files is located
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B <\f[I]file\f[R]>
|
||||
Location of the flight recording file (\f[CB]\&.jfr\f[R])
|
||||
.RS
|
||||
.RE
|
||||
<\f[I]file\f[R]>
|
||||
Location of the flight recording file (\f[V].jfr\f[R])
|
||||
.PP
|
||||
Flight recording information is written in chunks.
|
||||
A chunk contains all of the information necessary for parsing.
|
||||
A chunk typically contains events useful for troubleshooting.
|
||||
If a JVM should crash, these chunks can be recovered and used to create
|
||||
a flight recording file using this \f[CB]jfr\ assemble\f[R] command.
|
||||
a flight recording file using this \f[V]jfr assemble\f[R] command.
|
||||
These chunk files are concatenated in chronological order and chunk
|
||||
files that are not finished (.part) are excluded.
|
||||
.SS \f[CB]jfr\ disassemble\f[R] subcommand
|
||||
.SS \f[V]jfr disassemble\f[R] subcommand
|
||||
.PP
|
||||
Use \f[CB]jfr\ disassemble\f[R] to decompose a flight recording file into
|
||||
Use \f[V]jfr disassemble\f[R] to decompose a flight recording file into
|
||||
its chunk file pieces.
|
||||
The syntax is:
|
||||
.PP
|
||||
\f[CB]jfr\ disassemble\f[R] [\f[CB]\-\-max\-chunks\f[R] <\f[I]chunks\f[R]>]
|
||||
[\f[CB]\-\-output\f[R] <\f[I]directory\f[R]>] <\f[I]file\f[R]>
|
||||
\f[V]jfr disassemble\f[R] [\f[V]--max-chunks\f[R] <\f[I]chunks\f[R]>]
|
||||
[\f[V]--output\f[R] <\f[I]directory\f[R]>] <\f[I]file\f[R]>
|
||||
.PP
|
||||
where:
|
||||
.TP
|
||||
.B \f[CB]\-\-output\f[R] <\f[I]directory\f[R]>
|
||||
\f[V]--output\f[R] <\f[I]directory\f[R]>
|
||||
The location to write the disassembled file, by default the current
|
||||
directory
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-max\-chunks\f[R] <\f[I]chunks\f[R]>
|
||||
\f[V]--max-chunks\f[R] <\f[I]chunks\f[R]>
|
||||
Maximum number of chunks per file, by default 5.
|
||||
The chunk size varies, but is typically around 15 MB.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-max\-size\f[R] <\f[I]size\f[R]>
|
||||
\f[V]--max-size\f[R] <\f[I]size\f[R]>
|
||||
Maximum number of bytes per file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B <\f[I]file\f[R]>
|
||||
Location of the flight recording file (\f[CB]\&.jfr\f[R])
|
||||
.RS
|
||||
.RE
|
||||
<\f[I]file\f[R]>
|
||||
Location of the flight recording file (\f[V].jfr\f[R])
|
||||
.PP
|
||||
This function can be useful for repairing a broken file by removing the
|
||||
faulty chunk.
|
||||
It can also be used to reduce the size of a file that is too large to
|
||||
transfer.
|
||||
The resulting chunk files are named \f[CB]myfile_1.jfr\f[R],
|
||||
\f[CB]myfile_2.jfr\f[R], etc.
|
||||
The resulting chunk files are named \f[V]myfile_1.jfr\f[R],
|
||||
\f[V]myfile_2.jfr\f[R], etc.
|
||||
If needed, the resulting file names will be padded with zeros to
|
||||
preserve chronological order.
|
||||
For example, the chunk file name is \f[CB]myfile_001.jfr\f[R] if the
|
||||
For example, the chunk file name is \f[V]myfile_001.jfr\f[R] if the
|
||||
recording consists of more than 100 chunks.
|
||||
.SS jfr version and help subcommands
|
||||
.PP
|
||||
Use \f[CB]jfr\ \-\-version\f[R] or \f[CB]jfr\ version\f[R] to view the
|
||||
version string information for this jfr command.
|
||||
Use \f[V]jfr --version\f[R] or \f[V]jfr version\f[R] to view the version
|
||||
string information for this jfr command.
|
||||
.PP
|
||||
To get help on any of the jfr subcommands, use:
|
||||
.PP
|
||||
\f[CB]jfr\ <\-\-help|help>\f[R] [\f[I]subcommand\f[R]]
|
||||
\f[V]jfr <--help|help>\f[R] [\f[I]subcommand\f[R]]
|
||||
.PP
|
||||
where:
|
||||
.PP
|
||||
[\f[I]subcommand\f[R]] is any of:
|
||||
.IP \[bu] 2
|
||||
\f[CB]print\f[R]
|
||||
\f[V]print\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]metadata\f[R]
|
||||
\f[V]metadata\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]summary\f[R]
|
||||
\f[V]summary\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]assemble\f[R]
|
||||
\f[V]assemble\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]disassemble\f[R]
|
||||
\f[V]disassemble\f[R]
|
||||
|
||||
@ -19,41 +19,49 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JLINK" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JLINK" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jlink \- assemble and optimize a set of modules and their dependencies
|
||||
jlink - assemble and optimize a set of modules and their dependencies
|
||||
into a custom runtime image
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]jlink\f[R] [\f[I]options\f[R]] \f[CB]\-\-module\-path\f[R]
|
||||
\f[I]modulepath\f[R] \f[CB]\-\-add\-modules\f[R] \f[I]module\f[R] [,
|
||||
\f[V]jlink\f[R] [\f[I]options\f[R]] \f[V]--module-path\f[R]
|
||||
\f[I]modulepath\f[R] \f[V]--add-modules\f[R] \f[I]module\f[R] [,
|
||||
\f[I]module\f[R]...]
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
Command\-line options separated by spaces.
|
||||
\f[I]options\f[R]
|
||||
Command-line options separated by spaces.
|
||||
See \f[B]jlink Options\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]modulepath\f[R]
|
||||
The path where the \f[CB]jlink\f[R] tool discovers observable modules.
|
||||
\f[I]modulepath\f[R]
|
||||
The path where the \f[V]jlink\f[R] tool discovers observable modules.
|
||||
These modules can be modular JAR files, JMOD files, or exploded modules.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[I]module\f[R]
|
||||
\f[I]module\f[R]
|
||||
The names of the modules to add to the runtime image.
|
||||
The \f[CB]jlink\f[R] tool adds these modules and their transitive
|
||||
The \f[V]jlink\f[R] tool adds these modules and their transitive
|
||||
dependencies.
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jlink\f[R] tool links a set of modules, along with their
|
||||
The \f[V]jlink\f[R] tool links a set of modules, along with their
|
||||
transitive dependences, to create a custom runtime image.
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
@ -61,120 +69,90 @@ transitive dependences, to create a custom runtime image.
|
||||
Developers are responsible for updating their custom runtime images.
|
||||
.SH JLINK OPTIONS
|
||||
.TP
|
||||
.B \f[CB]\-\-add\-modules\f[R] \f[I]mod\f[R] [\f[CB],\f[R] \f[I]mod\f[R]...]
|
||||
\f[V]--add-modules\f[R] \f[I]mod\f[R] [\f[V],\f[R] \f[I]mod\f[R]...]
|
||||
Adds the named modules, \f[I]mod\f[R], to the default set of root
|
||||
modules.
|
||||
The default set of root modules is empty.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-bind\-services\f[R]
|
||||
\f[V]--bind-services\f[R]
|
||||
Link service provider modules and their dependencies.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-c\ ={0|1|2}\f[R] or \f[CB]\-\-compress={0|1|2}\f[R]
|
||||
\f[V]-c ={0|1|2}\f[R] or \f[V]--compress={0|1|2}\f[R]
|
||||
Enable compression of resources:
|
||||
.RS
|
||||
.IP \[bu] 2
|
||||
\f[CB]0\f[R]: No compression
|
||||
\f[V]0\f[R]: No compression
|
||||
.IP \[bu] 2
|
||||
\f[CB]1\f[R]: Constant string sharing
|
||||
\f[V]1\f[R]: Constant string sharing
|
||||
.IP \[bu] 2
|
||||
\f[CB]2\f[R]: ZIP
|
||||
\f[V]2\f[R]: ZIP
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-disable\-plugin\f[R] \f[I]pluginname\f[R]
|
||||
Disables the specified plug\-in.
|
||||
See \f[B]jlink Plug\-ins\f[R] for the list of supported plug\-ins.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--disable-plugin\f[R] \f[I]pluginname\f[R]
|
||||
Disables the specified plug-in.
|
||||
See \f[B]jlink Plug-ins\f[R] for the list of supported plug-ins.
|
||||
.TP
|
||||
.B \f[CB]\-\-endian\f[R] {\f[CB]little\f[R]|\f[CB]big\f[R]}
|
||||
\f[V]--endian\f[R] {\f[V]little\f[R]|\f[V]big\f[R]}
|
||||
Specifies the byte order of the generated image.
|
||||
The default value is the format of your system\[aq]s architecture.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-h\f[R] or \f[CB]\-\-help\f[R]
|
||||
\f[V]-h\f[R] or \f[V]--help\f[R]
|
||||
Prints the help message.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-ignore\-signing\-information\f[R]
|
||||
\f[V]--ignore-signing-information\f[R]
|
||||
Suppresses a fatal error when signed modular JARs are linked in the
|
||||
runtime image.
|
||||
The signature\-related files of the signed modular JARs aren\[aq]t
|
||||
copied to the runtime image.
|
||||
.RS
|
||||
.RE
|
||||
The signature-related files of the signed modular JARs aren\[aq]t copied
|
||||
to the runtime image.
|
||||
.TP
|
||||
.B \f[CB]\-\-launcher\f[R] \f[I]command\f[R]\f[CB]=\f[R]\f[I]module\f[R] or \f[CB]\-\-launcher\f[R] \f[I]command\f[R]\f[CB]=\f[R]\f[I]module\f[R]\f[CB]/\f[R]\f[I]main\f[R]
|
||||
\f[V]--launcher\f[R] \f[I]command\f[R]\f[V]=\f[R]\f[I]module\f[R] or \f[V]--launcher\f[R] \f[I]command\f[R]\f[V]=\f[R]\f[I]module\f[R]\f[V]/\f[R]\f[I]main\f[R]
|
||||
Specifies the launcher command name for the module or the command name
|
||||
for the module and main class (the module and the main class names are
|
||||
separated by a slash (\f[CB]/\f[R])).
|
||||
.RS
|
||||
.RE
|
||||
separated by a slash (\f[V]/\f[R])).
|
||||
.TP
|
||||
.B \f[CB]\-\-limit\-modules\f[R] \f[I]mod\f[R] [\f[CB],\f[R] \f[I]mod\f[R]...]
|
||||
\f[V]--limit-modules\f[R] \f[I]mod\f[R] [\f[V],\f[R] \f[I]mod\f[R]...]
|
||||
Limits the universe of observable modules to those in the transitive
|
||||
closure of the named modules, \f[CB]mod\f[R], plus the main module, if
|
||||
any, plus any further modules specified in the \f[CB]\-\-add\-modules\f[R]
|
||||
closure of the named modules, \f[V]mod\f[R], plus the main module, if
|
||||
any, plus any further modules specified in the \f[V]--add-modules\f[R]
|
||||
option.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-list\-plugins\f[R]
|
||||
Lists available plug\-ins, which you can access through command\-line
|
||||
options; see \f[B]jlink Plug\-ins\f[R].
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--list-plugins\f[R]
|
||||
Lists available plug-ins, which you can access through command-line
|
||||
options; see \f[B]jlink Plug-ins\f[R].
|
||||
.TP
|
||||
.B \f[CB]\-p\f[R] or \f[CB]\-\-module\-path\f[R] \f[I]modulepath\f[R]
|
||||
\f[V]-p\f[R] or \f[V]--module-path\f[R] \f[I]modulepath\f[R]
|
||||
Specifies the module path.
|
||||
.RS
|
||||
.PP
|
||||
If this option is not specified, then the default module path is
|
||||
\f[CB]$JAVA_HOME/jmods\f[R].
|
||||
This directory contains the \f[CB]java.base\f[R] module and the other
|
||||
\f[V]$JAVA_HOME/jmods\f[R].
|
||||
This directory contains the \f[V]java.base\f[R] module and the other
|
||||
standard and JDK modules.
|
||||
If this option is specified but the \f[CB]java.base\f[R] module cannot be
|
||||
resolved from it, then the \f[CB]jlink\f[R] command appends
|
||||
\f[CB]$JAVA_HOME/jmods\f[R] to the module path.
|
||||
If this option is specified but the \f[V]java.base\f[R] module cannot be
|
||||
resolved from it, then the \f[V]jlink\f[R] command appends
|
||||
\f[V]$JAVA_HOME/jmods\f[R] to the module path.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-no\-header\-files\f[R]
|
||||
\f[V]--no-header-files\f[R]
|
||||
Excludes header files.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-no\-man\-pages\f[R]
|
||||
\f[V]--no-man-pages\f[R]
|
||||
Excludes man pages.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-output\f[R] \f[I]path\f[R]
|
||||
\f[V]--output\f[R] \f[I]path\f[R]
|
||||
Specifies the location of the generated runtime image.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-save\-opts\f[R] \f[I]filename\f[R]
|
||||
Saves \f[CB]jlink\f[R] options in the specified file.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--save-opts\f[R] \f[I]filename\f[R]
|
||||
Saves \f[V]jlink\f[R] options in the specified file.
|
||||
.TP
|
||||
.B \f[CB]\-\-suggest\-providers\f[R] [\f[I]name\f[R]\f[CB],\f[R] ...]
|
||||
\f[V]--suggest-providers\f[R] [\f[I]name\f[R]\f[V],\f[R] ...]
|
||||
Suggest providers that implement the given service types from the module
|
||||
path.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-version\f[R]
|
||||
\f[V]--version\f[R]
|
||||
Prints version information.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\@\f[R]\f[I]filename\f[R]
|
||||
\f[V]\[at]\f[R]\f[I]filename\f[R]
|
||||
Reads options from the specified file.
|
||||
.RS
|
||||
.PP
|
||||
@ -182,55 +160,53 @@ An options file is a text file that contains the options and values that
|
||||
you would typically enter in a command prompt.
|
||||
Options may appear on one line or on several lines.
|
||||
You may not specify environment variables for path names.
|
||||
You may comment out lines by prefixing a hash symbol (\f[CB]#\f[R]) to the
|
||||
beginning of the line.
|
||||
You may comment out lines by prefixing a hash symbol (\f[V]#\f[R]) to
|
||||
the beginning of the line.
|
||||
.PP
|
||||
The following is an example of an options file for the \f[CB]jlink\f[R]
|
||||
The following is an example of an options file for the \f[V]jlink\f[R]
|
||||
command:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
#Wed\ Dec\ 07\ 00:40:19\ EST\ 2016
|
||||
\-\-module\-path\ mlib
|
||||
\-\-add\-modules\ com.greetings
|
||||
\-\-output\ greetingsapp
|
||||
#Wed Dec 07 00:40:19 EST 2016
|
||||
--module-path mlib
|
||||
--add-modules com.greetings
|
||||
--output greetingsapp
|
||||
\f[R]
|
||||
.fi
|
||||
.RE
|
||||
.SH JLINK PLUG\-INS
|
||||
.SH JLINK PLUG-INS
|
||||
.PP
|
||||
\f[B]Note:\f[R]
|
||||
.PP
|
||||
Plug\-ins not listed in this section aren\[aq]t supported and are
|
||||
subject to change.
|
||||
Plug-ins not listed in this section aren\[aq]t supported and are subject
|
||||
to change.
|
||||
.PP
|
||||
For plug\-in options that require a \f[I]pattern\-list\f[R], the value is
|
||||
a comma\-separated list of elements, with each element using one the
|
||||
For plug-in options that require a \f[I]pattern-list\f[R], the value is
|
||||
a comma-separated list of elements, with each element using one the
|
||||
following forms:
|
||||
.IP \[bu] 2
|
||||
\f[I]glob\-pattern\f[R]
|
||||
\f[I]glob-pattern\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]glob:\f[R]\f[I]glob\-pattern\f[R]
|
||||
\f[V]glob:\f[R]\f[I]glob-pattern\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]regex:\f[R]\f[I]regex\-pattern\f[R]
|
||||
\f[V]regex:\f[R]\f[I]regex-pattern\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]\@\f[R]\f[I]filename\f[R]
|
||||
\f[V]\[at]\f[R]\f[I]filename\f[R]
|
||||
.RS 2
|
||||
.IP \[bu] 2
|
||||
\f[I]filename\f[R] is the name of a file that contains patterns to be
|
||||
used, one pattern per line.
|
||||
.RE
|
||||
.PP
|
||||
For a complete list of all available plug\-ins, run the command
|
||||
\f[CB]jlink\ \-\-list\-plugins\f[R].
|
||||
.SS Plugin \f[CB]compress\f[R]
|
||||
For a complete list of all available plug-ins, run the command
|
||||
\f[V]jlink --list-plugins\f[R].
|
||||
.SS Plugin \f[V]compress\f[R]
|
||||
.TP
|
||||
.B Options
|
||||
\f[CB]\-\-compress=\f[R]{\f[CB]0\f[R]|\f[CB]1\f[R]|\f[CB]2\f[R]}[\f[CB]:filter=\f[R]\f[I]pattern\-list\f[R]]
|
||||
.RS
|
||||
.RE
|
||||
Options
|
||||
\f[V]--compress=\f[R]{\f[V]0\f[R]|\f[V]1\f[R]|\f[V]2\f[R]}[\f[V]:filter=\f[R]\f[I]pattern-list\f[R]]
|
||||
.TP
|
||||
.B Description
|
||||
Description
|
||||
Compresses all resources in the output image.
|
||||
.RS
|
||||
.IP \[bu] 2
|
||||
@ -240,19 +216,17 @@ Level 1: Constant string sharing
|
||||
.IP \[bu] 2
|
||||
Level 2: ZIP
|
||||
.PP
|
||||
An optional \f[I]pattern\-list\f[R] filter can be specified to list the
|
||||
An optional \f[I]pattern-list\f[R] filter can be specified to list the
|
||||
pattern of files to include.
|
||||
.RE
|
||||
.SS Plugin \f[CB]include\-locales\f[R]
|
||||
.SS Plugin \f[V]include-locales\f[R]
|
||||
.TP
|
||||
.B Options
|
||||
\f[CB]\-\-include\-locales=\f[R]\f[I]langtag\f[R][\f[CB],\f[R]\f[I]langtag\f[R]]*
|
||||
.RS
|
||||
.RE
|
||||
Options
|
||||
\f[V]--include-locales=\f[R]\f[I]langtag\f[R][\f[V],\f[R]\f[I]langtag\f[R]]*
|
||||
.TP
|
||||
.B Description
|
||||
Includes the list of locales where \f[I]langtag\f[R] is a BCP 47 language
|
||||
tag.
|
||||
Description
|
||||
Includes the list of locales where \f[I]langtag\f[R] is a BCP 47
|
||||
language tag.
|
||||
This option supports locale matching as defined in RFC 4647.
|
||||
Ensure that you add the module jdk.localedata when using this option.
|
||||
.RS
|
||||
@ -260,74 +234,64 @@ Ensure that you add the module jdk.localedata when using this option.
|
||||
Example:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]\-\-add\-modules\ jdk.localedata\ \-\-include\-locales=en,ja,*\-IN\f[R]
|
||||
\f[V]--add-modules jdk.localedata --include-locales=en,ja,*-IN\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.SS Plugin \f[CB]order\-resources\f[R]
|
||||
.SS Plugin \f[V]order-resources\f[R]
|
||||
.TP
|
||||
.B Options
|
||||
\f[CB]\-\-order\-resources=\f[R]\f[I]pattern\-list\f[R]
|
||||
.RS
|
||||
.RE
|
||||
Options
|
||||
\f[V]--order-resources=\f[R]\f[I]pattern-list\f[R]
|
||||
.TP
|
||||
.B Description
|
||||
Description
|
||||
Orders the specified paths in priority order.
|
||||
If \f[CB]\@\f[R]\f[I]filename\f[R] is specified, then each line in
|
||||
\f[I]pattern\-list\f[R] must be an exact match for the paths to be
|
||||
If \f[V]\[at]\f[R]\f[I]filename\f[R] is specified, then each line in
|
||||
\f[I]pattern-list\f[R] must be an exact match for the paths to be
|
||||
ordered.
|
||||
.RS
|
||||
.PP
|
||||
Example:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]\-\-order\-resources=/module\-info.class,\@classlist,/java.base/java/lang/\f[R]
|
||||
\f[V]--order-resources=/module-info.class,\[at]classlist,/java.base/java/lang/\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.SS Plugin \f[CB]strip\-debug\f[R]
|
||||
.SS Plugin \f[V]strip-debug\f[R]
|
||||
.TP
|
||||
.B Options
|
||||
\f[CB]\-\-strip\-debug\f[R]
|
||||
.RS
|
||||
.RE
|
||||
Options
|
||||
\f[V]--strip-debug\f[R]
|
||||
.TP
|
||||
.B Description
|
||||
Description
|
||||
Strips debug information from the output image.
|
||||
.RS
|
||||
.RE
|
||||
.SS Plugin \f[CB]generate\-cds\-archive\f[R]
|
||||
.SS Plugin \f[V]generate-cds-archive\f[R]
|
||||
.TP
|
||||
.B Options
|
||||
\f[CB]\-\-generate\-cds\-archive\f[R]
|
||||
.RS
|
||||
.RE
|
||||
Options
|
||||
\f[V]--generate-cds-archive\f[R]
|
||||
.TP
|
||||
.B Description
|
||||
Description
|
||||
Generate CDS archive if the runtime image supports the CDS feature.
|
||||
.RS
|
||||
.RE
|
||||
.SH JLINK EXAMPLES
|
||||
.PP
|
||||
The following command creates a runtime image in the directory
|
||||
\f[CB]greetingsapp\f[R].
|
||||
This command links the module \f[CB]com.greetings\f[R], whose module
|
||||
definition is contained in the directory \f[CB]mlib\f[R].
|
||||
\f[V]greetingsapp\f[R].
|
||||
This command links the module \f[V]com.greetings\f[R], whose module
|
||||
definition is contained in the directory \f[V]mlib\f[R].
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jlink\ \-\-module\-path\ mlib\ \-\-add\-modules\ com.greetings\ \-\-output\ greetingsapp
|
||||
jlink --module-path mlib --add-modules com.greetings --output greetingsapp
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
The following command lists the modules in the runtime image
|
||||
\f[CB]greetingsapp\f[R]:
|
||||
\f[V]greetingsapp\f[R]:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
greetingsapp/bin/java\ \-\-list\-modules
|
||||
greetingsapp/bin/java --list-modules
|
||||
com.greetings
|
||||
java.base\@11
|
||||
java.logging\@11
|
||||
org.astro\@1.0
|
||||
java.base\[at]11
|
||||
java.logging\[at]11
|
||||
org.astro\[at]1.0
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
@ -337,64 +301,64 @@ reduce space, and includes French language locale information:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jlink\ \-\-add\-modules\ jdk.localedata\ \-\-strip\-debug\ \-\-compress=2\ \-\-include\-locales=fr\ \-\-output\ compressedrt
|
||||
jlink --add-modules jdk.localedata --strip-debug --compress=2 --include-locales=fr --output compressedrt
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
The following example compares the size of the runtime image
|
||||
\f[CB]compressedrt\f[R] with \f[CB]fr_rt\f[R], which isn\[aq]t stripped of
|
||||
\f[V]compressedrt\f[R] with \f[V]fr_rt\f[R], which isn\[aq]t stripped of
|
||||
debug symbols and doesn\[aq]t use compression:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jlink\ \-\-add\-modules\ jdk.localedata\ \-\-include\-locales=fr\ \-\-output\ fr_rt
|
||||
jlink --add-modules jdk.localedata --include-locales=fr --output fr_rt
|
||||
|
||||
du\ \-sh\ ./compressedrt\ ./fr_rt
|
||||
23M\ \ \ \ \ ./compressedrt
|
||||
36M\ \ \ \ \ ./fr_rt
|
||||
du -sh ./compressedrt ./fr_rt
|
||||
23M ./compressedrt
|
||||
36M ./fr_rt
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
The following example lists the providers that implement
|
||||
\f[CB]java.security.Provider\f[R]:
|
||||
\f[V]java.security.Provider\f[R]:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jlink\ \-\-suggest\-providers\ java.security.Provider
|
||||
jlink --suggest-providers java.security.Provider
|
||||
|
||||
Suggested\ providers:
|
||||
\ \ java.naming\ provides\ java.security.Provider\ used\ by\ java.base
|
||||
\ \ java.security.jgss\ provides\ java.security.Provider\ used\ by\ java.base
|
||||
\ \ java.security.sasl\ provides\ java.security.Provider\ used\ by\ java.base
|
||||
\ \ java.smartcardio\ provides\ java.security.Provider\ used\ by\ java.base
|
||||
\ \ java.xml.crypto\ provides\ java.security.Provider\ used\ by\ java.base
|
||||
\ \ jdk.crypto.cryptoki\ provides\ java.security.Provider\ used\ by\ java.base
|
||||
\ \ jdk.crypto.ec\ provides\ java.security.Provider\ used\ by\ java.base
|
||||
\ \ jdk.crypto.mscapi\ provides\ java.security.Provider\ used\ by\ java.base
|
||||
\ \ jdk.security.jgss\ provides\ java.security.Provider\ used\ by\ java.base
|
||||
Suggested providers:
|
||||
java.naming provides java.security.Provider used by java.base
|
||||
java.security.jgss provides java.security.Provider used by java.base
|
||||
java.security.sasl provides java.security.Provider used by java.base
|
||||
java.smartcardio provides java.security.Provider used by java.base
|
||||
java.xml.crypto provides java.security.Provider used by java.base
|
||||
jdk.crypto.cryptoki provides java.security.Provider used by java.base
|
||||
jdk.crypto.ec provides java.security.Provider used by java.base
|
||||
jdk.crypto.mscapi provides java.security.Provider used by java.base
|
||||
jdk.security.jgss provides java.security.Provider used by java.base
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
The following example creates a custom runtime image named
|
||||
\f[CB]mybuild\f[R] that includes only \f[CB]java.naming\f[R] and
|
||||
\f[CB]jdk.crypto.cryptoki\f[R] and their dependencies but no other
|
||||
\f[V]mybuild\f[R] that includes only \f[V]java.naming\f[R] and
|
||||
\f[V]jdk.crypto.cryptoki\f[R] and their dependencies but no other
|
||||
providers.
|
||||
Note that these dependencies must exist in the module path:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jlink\ \-\-add\-modules\ java.naming,jdk.crypto.cryptoki\ \-\-output\ mybuild
|
||||
jlink --add-modules java.naming,jdk.crypto.cryptoki --output mybuild
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
The following command is similar to the one that creates a runtime image
|
||||
named \f[CB]greetingsapp\f[R], except that it will link the modules
|
||||
named \f[V]greetingsapp\f[R], except that it will link the modules
|
||||
resolved from root modules with service binding; see the
|
||||
\f[B]\f[BC]Configuration.resolveAndBind\f[B]\f[R] method.
|
||||
\f[B]\f[VB]Configuration.resolveAndBind\f[B]\f[R] method.
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jlink\ \-\-module\-path\ mlib\ \-\-add\-modules\ com.greetings\ \-\-output\ greetingsapp\ \-\-bind\-services
|
||||
jlink --module-path mlib --add-modules com.greetings --output greetingsapp --bind-services
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
@ -403,43 +367,43 @@ greetingsapp created by this command:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
greetingsapp/bin/java\ \-\-list\-modules
|
||||
greetingsapp/bin/java --list-modules
|
||||
com.greetings
|
||||
java.base\@11
|
||||
java.compiler\@11
|
||||
java.datatransfer\@11
|
||||
java.desktop\@11
|
||||
java.logging\@11
|
||||
java.management\@11
|
||||
java.management.rmi\@11
|
||||
java.naming\@11
|
||||
java.prefs\@11
|
||||
java.rmi\@11
|
||||
java.security.jgss\@11
|
||||
java.security.sasl\@11
|
||||
java.smartcardio\@11
|
||||
java.xml\@11
|
||||
java.xml.crypto\@11
|
||||
jdk.accessibility\@11
|
||||
jdk.charsets\@11
|
||||
jdk.compiler\@11
|
||||
jdk.crypto.cryptoki\@11
|
||||
jdk.crypto.ec\@11
|
||||
jdk.crypto.mscapi\@11
|
||||
jdk.internal.opt\@11
|
||||
jdk.jartool\@11
|
||||
jdk.javadoc\@11
|
||||
jdk.jdeps\@11
|
||||
jdk.jfr\@11
|
||||
jdk.jlink\@11
|
||||
jdk.localedata\@11
|
||||
jdk.management\@11
|
||||
jdk.management.jfr\@11
|
||||
jdk.naming.dns\@11
|
||||
jdk.naming.rmi\@11
|
||||
jdk.security.auth\@11
|
||||
jdk.security.jgss\@11
|
||||
jdk.zipfs\@11
|
||||
org.astro\@1.0
|
||||
java.base\[at]11
|
||||
java.compiler\[at]11
|
||||
java.datatransfer\[at]11
|
||||
java.desktop\[at]11
|
||||
java.logging\[at]11
|
||||
java.management\[at]11
|
||||
java.management.rmi\[at]11
|
||||
java.naming\[at]11
|
||||
java.prefs\[at]11
|
||||
java.rmi\[at]11
|
||||
java.security.jgss\[at]11
|
||||
java.security.sasl\[at]11
|
||||
java.smartcardio\[at]11
|
||||
java.xml\[at]11
|
||||
java.xml.crypto\[at]11
|
||||
jdk.accessibility\[at]11
|
||||
jdk.charsets\[at]11
|
||||
jdk.compiler\[at]11
|
||||
jdk.crypto.cryptoki\[at]11
|
||||
jdk.crypto.ec\[at]11
|
||||
jdk.crypto.mscapi\[at]11
|
||||
jdk.internal.opt\[at]11
|
||||
jdk.jartool\[at]11
|
||||
jdk.javadoc\[at]11
|
||||
jdk.jdeps\[at]11
|
||||
jdk.jfr\[at]11
|
||||
jdk.jlink\[at]11
|
||||
jdk.localedata\[at]11
|
||||
jdk.management\[at]11
|
||||
jdk.management.jfr\[at]11
|
||||
jdk.naming.dns\[at]11
|
||||
jdk.naming.rmi\[at]11
|
||||
jdk.security.auth\[at]11
|
||||
jdk.security.jgss\[at]11
|
||||
jdk.zipfs\[at]11
|
||||
org.astro\[at]1.0
|
||||
\f[R]
|
||||
.fi
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
.\" Copyright (c) 2017, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
.\" Copyright (c) 2017, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
.\" DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
.\"
|
||||
.\" This code is free software; you can redistribute it and/or modify it
|
||||
@ -19,219 +19,190 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JMOD" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JMOD" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jmod \- create JMOD files and list the content of existing JMOD files
|
||||
jmod - create JMOD files and list the content of existing JMOD files
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[CB]jmod\f[R]
|
||||
(\f[CB]create\f[R]|\f[CB]extract\f[R]|\f[CB]list\f[R]|\f[CB]describe\f[R]|\f[CB]hash\f[R])
|
||||
[\f[I]options\f[R]] \f[I]jmod\-file\f[R]
|
||||
\f[V]jmod\f[R]
|
||||
(\f[V]create\f[R]|\f[V]extract\f[R]|\f[V]list\f[R]|\f[V]describe\f[R]|\f[V]hash\f[R])
|
||||
[\f[I]options\f[R]] \f[I]jmod-file\f[R]
|
||||
.PP
|
||||
Includes the following:
|
||||
.PP
|
||||
\f[B]Main operation modes\f[R]
|
||||
.TP
|
||||
.B \f[CB]create\f[R]
|
||||
\f[V]create\f[R]
|
||||
Creates a new JMOD archive file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]extract\f[R]
|
||||
\f[V]extract\f[R]
|
||||
Extracts all the files from the JMOD archive file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]list\f[R]
|
||||
\f[V]list\f[R]
|
||||
Prints the names of all the entries.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]describe\f[R]
|
||||
\f[V]describe\f[R]
|
||||
Prints the module details.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]hash\f[R]
|
||||
\f[V]hash\f[R]
|
||||
Determines leaf modules and records the hashes of the dependencies that
|
||||
directly and indirectly require them.
|
||||
.RS
|
||||
.RE
|
||||
.PP
|
||||
\f[B]Options\f[R]
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
\f[I]options\f[R]
|
||||
See \f[B]Options for jmod\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.PP
|
||||
\f[B]Required\f[R]
|
||||
.TP
|
||||
.B \f[I]jmod\-file\f[R]
|
||||
\f[I]jmod-file\f[R]
|
||||
Specifies the name of the JMOD file to create or from which to retrieve
|
||||
information.
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\f[B]Note:\f[R] For most development tasks, including deploying modules
|
||||
on the module path or publishing them to a Maven repository, continue to
|
||||
package modules in modular JAR files.
|
||||
The \f[CB]jmod\f[R] tool is intended for modules that have native
|
||||
The \f[V]jmod\f[R] tool is intended for modules that have native
|
||||
libraries or other configuration files or for modules that you intend to
|
||||
link, with the \f[B]jlink\f[R] tool, to a runtime image.
|
||||
.PP
|
||||
The JMOD file format lets you aggregate files other than
|
||||
\f[CB]\&.class\f[R] files, metadata, and resources.
|
||||
\f[V].class\f[R] files, metadata, and resources.
|
||||
This format is transportable but not executable, which means that you
|
||||
can use it during compile time or link time but not at run time.
|
||||
.PP
|
||||
Many \f[CB]jmod\f[R] options involve specifying a path whose contents are
|
||||
Many \f[V]jmod\f[R] options involve specifying a path whose contents are
|
||||
copied into the resulting JMOD files.
|
||||
These options copy all the contents of the specified path, including
|
||||
subdirectories and their contents, but exclude files whose names match
|
||||
the pattern specified by the \f[CB]\-\-exclude\f[R] option.
|
||||
the pattern specified by the \f[V]--exclude\f[R] option.
|
||||
.PP
|
||||
With the \f[CB]\-\-hash\-modules\f[R] option or the \f[CB]jmod\ hash\f[R]
|
||||
With the \f[V]--hash-modules\f[R] option or the \f[V]jmod hash\f[R]
|
||||
command, you can, in each module\[aq]s descriptor, record hashes of the
|
||||
content of the modules that are allowed to depend upon it, thus "tying"
|
||||
together these modules.
|
||||
This enables a package to be exported to one or more specifically\-named
|
||||
content of the modules that are allowed to depend upon it, thus
|
||||
\[dq]tying\[dq] together these modules.
|
||||
This enables a package to be exported to one or more specifically-named
|
||||
modules and to no others through qualified exports.
|
||||
The runtime verifies if the recorded hash of a module matches the one
|
||||
resolved at run time; if not, the runtime returns an error.
|
||||
.SH OPTIONS FOR JMOD
|
||||
.TP
|
||||
.B \f[CB]\-\-class\-path\f[R] \f[I]path\f[R]
|
||||
\f[V]--class-path\f[R] \f[I]path\f[R]
|
||||
Specifies the location of application JAR files or a directory
|
||||
containing classes to copy into the resulting JMOD file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-cmds\f[R] \f[I]path\f[R]
|
||||
\f[V]--cmds\f[R] \f[I]path\f[R]
|
||||
Specifies the location of native commands to copy into the resulting
|
||||
JMOD file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-config\f[R] \f[I]path\f[R]
|
||||
Specifies the location of user\-editable configuration files to copy
|
||||
into the resulting JMOD file.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--compress\f[R] \f[I]compress\f[R]
|
||||
Specifies the compression to use in creating the JMOD file.
|
||||
The accepted values are \f[V]zip-[0-9]\f[R], where \f[V]zip-0\f[R]
|
||||
provides no compression, and \f[V]zip-9\f[R] provides the best
|
||||
compression.
|
||||
Default is \f[V]zip-6\f[R].
|
||||
.TP
|
||||
.B \f[CB]\-\-date\f[R]\f[I]TIMESTAMP\f[R]
|
||||
The timestamp in ISO\-8601 extended offset date\-time with optional
|
||||
time\-zone format, to use for the timestamp of the entries, e.g.
|
||||
"2022\-02\-12T12:30:00\-05:00".
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--config\f[R] \f[I]path\f[R]
|
||||
Specifies the location of user-editable configuration files to copy into
|
||||
the resulting JMOD file.
|
||||
.TP
|
||||
.B \f[CB]\-\-dir\f[R] \f[I]path\f[R]
|
||||
Specifies the location where \f[CB]jmod\f[R] puts extracted files from the
|
||||
specified JMOD archive.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--date\f[R]\f[I]TIMESTAMP\f[R]
|
||||
The timestamp in ISO-8601 extended offset date-time with optional
|
||||
time-zone format, to use for the timestamp of the entries, e.g.
|
||||
\[dq]2022-02-12T12:30:00-05:00\[dq].
|
||||
.TP
|
||||
.B \f[CB]\-\-dry\-run\f[R]
|
||||
\f[V]--dir\f[R] \f[I]path\f[R]
|
||||
Specifies the location where \f[V]jmod\f[R] puts extracted files from
|
||||
the specified JMOD archive.
|
||||
.TP
|
||||
\f[V]--dry-run\f[R]
|
||||
Performs a dry run of hash mode.
|
||||
It identifies leaf modules and their required modules without recording
|
||||
any hash values.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-exclude\f[R] \f[I]pattern\-list\f[R]
|
||||
Excludes files matching the supplied comma\-separated pattern list, each
|
||||
\f[V]--exclude\f[R] \f[I]pattern-list\f[R]
|
||||
Excludes files matching the supplied comma-separated pattern list, each
|
||||
element using one the following forms:
|
||||
.RS
|
||||
.IP \[bu] 2
|
||||
\f[I]glob\-pattern\f[R]
|
||||
\f[I]glob-pattern\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]glob:\f[R]\f[I]glob\-pattern\f[R]
|
||||
\f[V]glob:\f[R]\f[I]glob-pattern\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]regex:\f[R]\f[I]regex\-pattern\f[R]
|
||||
\f[V]regex:\f[R]\f[I]regex-pattern\f[R]
|
||||
.PP
|
||||
See the \f[B]\f[BC]FileSystem.getPathMatcher\f[B]\f[R] method for the
|
||||
syntax of \f[I]glob\-pattern\f[R].
|
||||
See the \f[B]\f[BC]Pattern\f[B]\f[R] class for the syntax of
|
||||
\f[I]regex\-pattern\f[R], which represents a regular expression.
|
||||
See the \f[B]\f[VB]FileSystem.getPathMatcher\f[B]\f[R] method for the
|
||||
syntax of \f[I]glob-pattern\f[R].
|
||||
See the \f[B]\f[VB]Pattern\f[B]\f[R] class for the syntax of
|
||||
\f[I]regex-pattern\f[R], which represents a regular expression.
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-hash\-modules\f[R] \f[I]regex\-pattern\f[R]
|
||||
\f[V]--hash-modules\f[R] \f[I]regex-pattern\f[R]
|
||||
Determines the leaf modules and records the hashes of the dependencies
|
||||
directly and indirectly requiring them, based on the module graph of the
|
||||
modules matching the given \f[I]regex\-pattern\f[R].
|
||||
modules matching the given \f[I]regex-pattern\f[R].
|
||||
The hashes are recorded in the JMOD archive file being created, or a
|
||||
JMOD archive or modular JAR on the module path specified by the
|
||||
\f[CB]jmod\ hash\f[R] command.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]jmod hash\f[R] command.
|
||||
.TP
|
||||
.B \f[CB]\-\-header\-files\f[R] \f[I]path\f[R]
|
||||
\f[V]--header-files\f[R] \f[I]path\f[R]
|
||||
Specifies the location of header files to copy into the resulting JMOD
|
||||
file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-help\f[R] or \f[CB]\-h\f[R]
|
||||
\f[V]--help\f[R] or \f[V]-h\f[R]
|
||||
Prints a usage message.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-help\-extra\f[R]
|
||||
\f[V]--help-extra\f[R]
|
||||
Prints help for extra options.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-legal\-notices\f[R] \f[I]path\f[R]
|
||||
\f[V]--legal-notices\f[R] \f[I]path\f[R]
|
||||
Specifies the location of legal notices to copy into the resulting JMOD
|
||||
file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-libs\f[R] \f[I]path\f[R]
|
||||
\f[V]--libs\f[R] \f[I]path\f[R]
|
||||
Specifies location of native libraries to copy into the resulting JMOD
|
||||
file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-main\-class\f[R] \f[I]class\-name\f[R]
|
||||
Specifies main class to record in the module\-info.class file.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--main-class\f[R] \f[I]class-name\f[R]
|
||||
Specifies main class to record in the module-info.class file.
|
||||
.TP
|
||||
.B \f[CB]\-\-man\-pages\f[R] \f[I]path\f[R]
|
||||
\f[V]--man-pages\f[R] \f[I]path\f[R]
|
||||
Specifies the location of man pages to copy into the resulting JMOD
|
||||
file.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-module\-version\f[R] \f[I]module\-version\f[R]
|
||||
Specifies the module version to record in the module\-info.class file.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--module-version\f[R] \f[I]module-version\f[R]
|
||||
Specifies the module version to record in the module-info.class file.
|
||||
.TP
|
||||
.B \f[CB]\-\-module\-path\f[R] \f[I]path\f[R] or \f[CB]\-p\f[R] \f[I]path\f[R]
|
||||
\f[V]--module-path\f[R] \f[I]path\f[R] or \f[V]-p\f[R] \f[I]path\f[R]
|
||||
Specifies the module path.
|
||||
This option is required if you also specify \f[CB]\-\-hash\-modules\f[R].
|
||||
.RS
|
||||
.RE
|
||||
This option is required if you also specify \f[V]--hash-modules\f[R].
|
||||
.TP
|
||||
.B \f[CB]\-\-target\-platform\f[R] \f[I]platform\f[R]
|
||||
\f[V]--target-platform\f[R] \f[I]platform\f[R]
|
||||
Specifies the target platform.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-version\f[R]
|
||||
Prints version information of the \f[CB]jmod\f[R] tool.
|
||||
.RS
|
||||
.RE
|
||||
\f[V]--version\f[R]
|
||||
Prints version information of the \f[V]jmod\f[R] tool.
|
||||
.TP
|
||||
.B \f[CB]\@\f[R]\f[I]filename\f[R]
|
||||
\f[V]\[at]\f[R]\f[I]filename\f[R]
|
||||
Reads options from the specified file.
|
||||
.RS
|
||||
.PP
|
||||
@ -239,21 +210,21 @@ An options file is a text file that contains the options and values that
|
||||
you would ordinarily enter in a command prompt.
|
||||
Options may appear on one line or on several lines.
|
||||
You may not specify environment variables for path names.
|
||||
You may comment out lines by prefixinga hash symbol (\f[CB]#\f[R]) to the
|
||||
You may comment out lines by prefixinga hash symbol (\f[V]#\f[R]) to the
|
||||
beginning of the line.
|
||||
.PP
|
||||
The following is an example of an options file for the \f[CB]jmod\f[R]
|
||||
The following is an example of an options file for the \f[V]jmod\f[R]
|
||||
command:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
#Wed\ Dec\ 07\ 00:40:19\ EST\ 2016
|
||||
create\ \-\-class\-path\ mods/com.greetings\ \-\-module\-path\ mlib
|
||||
\ \ \-\-cmds\ commands\ \-\-config\ configfiles\ \-\-header\-files\ src/h
|
||||
\ \ \-\-libs\ lib\ \-\-main\-class\ com.greetings.Main
|
||||
\ \ \-\-man\-pages\ man\ \-\-module\-version\ 1.0
|
||||
\ \ \-\-os\-arch\ "x86_x64"\ \-\-os\-name\ "Mac\ OS\ X"
|
||||
\ \ \-\-os\-version\ "10.10.5"\ greetingsmod
|
||||
#Wed Dec 07 00:40:19 EST 2016
|
||||
create --class-path mods/com.greetings --module-path mlib
|
||||
--cmds commands --config configfiles --header-files src/h
|
||||
--libs lib --main-class com.greetings.Main
|
||||
--man-pages man --module-version 1.0
|
||||
--os-arch \[dq]x86_x64\[dq] --os-name \[dq]Mac OS X\[dq]
|
||||
--os-version \[dq]10.10.5\[dq] greetingsmod
|
||||
\f[R]
|
||||
.fi
|
||||
.RE
|
||||
@ -262,90 +233,86 @@ create\ \-\-class\-path\ mods/com.greetings\ \-\-module\-path\ mlib
|
||||
In addition to the options described in \f[B]Options for jmod\f[R], the
|
||||
following are extra options that can be used with the command.
|
||||
.TP
|
||||
.B \f[CB]\-\-do\-not\-resolve\-by\-default\f[R]
|
||||
\f[V]--do-not-resolve-by-default\f[R]
|
||||
Exclude from the default root set of modules
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-\-warn\-if\-resolved\f[R]
|
||||
\f[V]--warn-if-resolved\f[R]
|
||||
Hint for a tool to issue a warning if the module is resolved.
|
||||
One of deprecated, deprecated\-for\-removal, or incubating.
|
||||
.RS
|
||||
.RE
|
||||
One of deprecated, deprecated-for-removal, or incubating.
|
||||
.SH JMOD CREATE EXAMPLE
|
||||
.PP
|
||||
The following is an example of creating a JMOD file:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jmod\ create\ \-\-class\-path\ mods/com.greetings\ \-\-cmds\ commands
|
||||
\ \ \-\-config\ configfiles\ \-\-header\-files\ src/h\ \-\-libs\ lib
|
||||
\ \ \-\-main\-class\ com.greetings.Main\ \-\-man\-pages\ man\ \-\-module\-version\ 1.0
|
||||
\ \ \-\-os\-arch\ "x86_x64"\ \-\-os\-name\ "Mac\ OS\ X"
|
||||
\ \ \-\-os\-version\ "10.10.5"\ greetingsmod
|
||||
jmod create --class-path mods/com.greetings --cmds commands
|
||||
--config configfiles --header-files src/h --libs lib
|
||||
--main-class com.greetings.Main --man-pages man --module-version 1.0
|
||||
--os-arch \[dq]x86_x64\[dq] --os-name \[dq]Mac OS X\[dq]
|
||||
--os-version \[dq]10.10.5\[dq] greetingsmod
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
Create a JMOD file specifying the date for the entries as
|
||||
\f[CB]2022\ March\ 15\ 00:00:00\f[R]:
|
||||
\f[V]2022 March 15 00:00:00\f[R]:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jmod\ create\ \-\-class\-path\ build/foo/classes\ \-\-date\ 2022\-03\-15T00:00:00Z
|
||||
\ \ \ jmods/foo1.jmod
|
||||
jmod create --class-path build/foo/classes --date 2022-03-15T00:00:00Z
|
||||
jmods/foo1.jmod
|
||||
\f[R]
|
||||
.fi
|
||||
.SH JMOD HASH EXAMPLE
|
||||
.PP
|
||||
The following example demonstrates what happens when you try to link a
|
||||
leaf module (in this example, \f[CB]ma\f[R]) with a required module
|
||||
(\f[CB]mb\f[R]), and the hash value recorded in the required module
|
||||
leaf module (in this example, \f[V]ma\f[R]) with a required module
|
||||
(\f[V]mb\f[R]), and the hash value recorded in the required module
|
||||
doesn\[aq]t match that of the leaf module.
|
||||
.IP "1." 3
|
||||
Create and compile the following \f[CB]\&.java\f[R] files:
|
||||
Create and compile the following \f[V].java\f[R] files:
|
||||
.RS 4
|
||||
.IP \[bu] 2
|
||||
\f[CB]jmodhashex/src/ma/module\-info.java\f[R]
|
||||
\f[V]jmodhashex/src/ma/module-info.java\f[R]
|
||||
.RS 2
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
module\ ma\ {
|
||||
\ \ requires\ mb;
|
||||
module ma {
|
||||
requires mb;
|
||||
}
|
||||
\f[R]
|
||||
.fi
|
||||
.RE
|
||||
.IP \[bu] 2
|
||||
\f[CB]jmodhashex/src/mb/module\-info.java\f[R]
|
||||
\f[V]jmodhashex/src/mb/module-info.java\f[R]
|
||||
.RS 2
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
module\ mb\ {
|
||||
module mb {
|
||||
}
|
||||
\f[R]
|
||||
.fi
|
||||
.RE
|
||||
.IP \[bu] 2
|
||||
\f[CB]jmodhashex2/src/ma/module\-info.java\f[R]
|
||||
\f[V]jmodhashex2/src/ma/module-info.java\f[R]
|
||||
.RS 2
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
module\ ma\ {
|
||||
\ \ requires\ mb;
|
||||
module ma {
|
||||
requires mb;
|
||||
}
|
||||
\f[R]
|
||||
.fi
|
||||
.RE
|
||||
.IP \[bu] 2
|
||||
\f[CB]jmodhashex2/src/mb/module\-info.java\f[R]
|
||||
\f[V]jmodhashex2/src/mb/module-info.java\f[R]
|
||||
.RS 2
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
module\ mb\ {
|
||||
module mb {
|
||||
}
|
||||
\f[R]
|
||||
.fi
|
||||
@ -353,87 +320,87 @@ module\ mb\ {
|
||||
.RE
|
||||
.IP "2." 3
|
||||
Create a JMOD archive for each module.
|
||||
Create the directories \f[CB]jmodhashex/jmods\f[R] and
|
||||
\f[CB]jmodhashex2/jmods\f[R], and then run the following commands from the
|
||||
\f[CB]jmodhashex\f[R] directory, then from the \f[CB]jmodhashex2\f[R]
|
||||
Create the directories \f[V]jmodhashex/jmods\f[R] and
|
||||
\f[V]jmodhashex2/jmods\f[R], and then run the following commands from
|
||||
the \f[V]jmodhashex\f[R] directory, then from the \f[V]jmodhashex2\f[R]
|
||||
directory:
|
||||
.RS 4
|
||||
.IP \[bu] 2
|
||||
\f[CB]jmod\ create\ \-\-class\-path\ mods/ma\ jmods/ma.jmod\f[R]
|
||||
\f[V]jmod create --class-path mods/ma jmods/ma.jmod\f[R]
|
||||
.IP \[bu] 2
|
||||
\f[CB]jmod\ create\ \-\-class\-path\ mods/mb\ jmods/mb.jmod\f[R]
|
||||
\f[V]jmod create --class-path mods/mb jmods/mb.jmod\f[R]
|
||||
.RE
|
||||
.IP "3." 3
|
||||
Optionally preview the \f[CB]jmod\ hash\f[R] command.
|
||||
Run the following command from the \f[CB]jmodhashex\f[R] directory:
|
||||
Optionally preview the \f[V]jmod hash\f[R] command.
|
||||
Run the following command from the \f[V]jmodhashex\f[R] directory:
|
||||
.RS 4
|
||||
.PP
|
||||
\f[CB]jmod\ hash\ \-\-dry\-run\ \-module\-path\ jmods\ \-\-hash\-modules\ .*\f[R]
|
||||
\f[V]jmod hash --dry-run -module-path jmods --hash-modules .*\f[R]
|
||||
.PP
|
||||
The command prints the following:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
Dry\ run:
|
||||
Dry run:
|
||||
mb
|
||||
\ \ hashes\ ma\ SHA\-256\ 07667d5032004b37b42ec2bb81b46df380cf29e66962a16481ace2e71e74073a
|
||||
hashes ma SHA-256 07667d5032004b37b42ec2bb81b46df380cf29e66962a16481ace2e71e74073a
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
This indicates that the \f[CB]jmod\ hash\f[R] command (without the
|
||||
\f[CB]\-\-dry\-run\f[R] option) will record the hash value of the leaf
|
||||
module \f[CB]ma\f[R] in the module \f[CB]mb\f[R].
|
||||
This indicates that the \f[V]jmod hash\f[R] command (without the
|
||||
\f[V]--dry-run\f[R] option) will record the hash value of the leaf
|
||||
module \f[V]ma\f[R] in the module \f[V]mb\f[R].
|
||||
.RE
|
||||
.IP "4." 3
|
||||
Record hash values in the JMOD archive files contained in the
|
||||
\f[CB]jmodhashex\f[R] directory.
|
||||
Run the following command from the \f[CB]jmodhashex\f[R] directory:
|
||||
\f[V]jmodhashex\f[R] directory.
|
||||
Run the following command from the \f[V]jmodhashex\f[R] directory:
|
||||
.RS 4
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jmod\ hash\ \-\-module\-path\ jmods\ \-\-hash\-modules\ .*\f[R]
|
||||
\f[V]jmod hash --module-path jmods --hash-modules .*\f[R]
|
||||
.RE
|
||||
.PP
|
||||
The command prints the following:
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]Hashes\ are\ recorded\ in\ module\ mb\f[R]
|
||||
\f[V]Hashes are recorded in module mb\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.IP "5." 3
|
||||
Print information about each JMOD archive contained in the
|
||||
\f[CB]jmodhashex\f[R] directory.
|
||||
Run the highlighted commands from the \f[CB]jmodhashex\f[R] directory:
|
||||
\f[V]jmodhashex\f[R] directory.
|
||||
Run the highlighted commands from the \f[V]jmodhashex\f[R] directory:
|
||||
.RS 4
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jmod\ describe\ jmods/ma.jmod
|
||||
jmod describe jmods/ma.jmod
|
||||
|
||||
ma
|
||||
\ \ requires\ mandated\ java.base
|
||||
\ \ requires\ mb
|
||||
requires mandated java.base
|
||||
requires mb
|
||||
|
||||
jmod\ describe\ jmods/mb.jmod
|
||||
jmod describe jmods/mb.jmod
|
||||
|
||||
mb
|
||||
\ \ requires\ mandated\ java.base
|
||||
\ \ hashes\ ma\ SHA\-256\ 07667d5032004b37b42ec2bb81b46df380cf29e66962a16481ace2e71e74073a
|
||||
requires mandated java.base
|
||||
hashes ma SHA-256 07667d5032004b37b42ec2bb81b46df380cf29e66962a16481ace2e71e74073a
|
||||
\f[R]
|
||||
.fi
|
||||
.RE
|
||||
.IP "6." 3
|
||||
Attempt to create a runtime image that contains the module \f[CB]ma\f[R]
|
||||
from the directory \f[CB]jmodhashex2\f[R] but the module \f[CB]mb\f[R] from
|
||||
the directory \f[CB]jmodhashex\f[R].
|
||||
Run the following command from the \f[CB]jmodhashex2\f[R] directory:
|
||||
Attempt to create a runtime image that contains the module \f[V]ma\f[R]
|
||||
from the directory \f[V]jmodhashex2\f[R] but the module \f[V]mb\f[R]
|
||||
from the directory \f[V]jmodhashex\f[R].
|
||||
Run the following command from the \f[V]jmodhashex2\f[R] directory:
|
||||
.RS 4
|
||||
.IP \[bu] 2
|
||||
\f[B]Linux and OS X:\f[R]
|
||||
.RS 2
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jlink\ \-\-module\-path\ $JAVA_HOME/jmods:jmods/ma.jmod:../jmodhashex/jmods/mb.jmod\ \-\-add\-modules\ ma\ \-\-output\ ma\-app\f[R]
|
||||
\f[V]jlink --module-path $JAVA_HOME/jmods:jmods/ma.jmod:../jmodhashex/jmods/mb.jmod --add-modules ma --output ma-app\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.IP \[bu] 2
|
||||
@ -441,7 +408,7 @@ Run the following command from the \f[CB]jmodhashex2\f[R] directory:
|
||||
.RS 2
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jlink\ \-\-module\-path\ %JAVA_HOME%/jmods;jmods/ma.jmod;../jmodhashex/jmods/mb.jmod\ \-\-add\-modules\ ma\ \-\-output\ ma\-app\f[R]
|
||||
\f[V]jlink --module-path %JAVA_HOME%/jmods;jmods/ma.jmod;../jmodhashex/jmods/mb.jmod --add-modules ma --output ma-app\f[R]
|
||||
.RE
|
||||
.RE
|
||||
.PP
|
||||
@ -449,8 +416,8 @@ The command prints an error message similar to the following:
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
Error:\ Hash\ of\ ma\ (a2d77889b0cb067df02a3abc39b01ac1151966157a68dc4241562c60499150d2)\ differs\ to
|
||||
expected\ hash\ (07667d5032004b37b42ec2bb81b46df380cf29e66962a16481ace2e71e74073a)\ recorded\ in\ mb
|
||||
Error: Hash of ma (a2d77889b0cb067df02a3abc39b01ac1151966157a68dc4241562c60499150d2) differs to
|
||||
expected hash (07667d5032004b37b42ec2bb81b46df380cf29e66962a16481ace2e71e74073a) recorded in mb
|
||||
\f[R]
|
||||
.fi
|
||||
.RE
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -19,138 +19,141 @@
|
||||
.\" or visit www.oracle.com if you need additional information or have any
|
||||
.\" questions.
|
||||
.\"
|
||||
.\" Automatically generated by Pandoc 2.3.1
|
||||
.\" Automatically generated by Pandoc 2.19.2
|
||||
.\"
|
||||
.TH "JSTATD" "1" "2023" "JDK 20\-ea" "JDK Commands"
|
||||
.\" Define V font for inline verbatim, using C font in formats
|
||||
.\" that render this, and otherwise B font.
|
||||
.ie "\f[CB]x\f[R]"x" \{\
|
||||
. ftr V B
|
||||
. ftr VI BI
|
||||
. ftr VB B
|
||||
. ftr VBI BI
|
||||
.\}
|
||||
.el \{\
|
||||
. ftr V CR
|
||||
. ftr VI CI
|
||||
. ftr VB CB
|
||||
. ftr VBI CBI
|
||||
.\}
|
||||
.TH "JSTATD" "1" "2023" "JDK 20-ea" "JDK Commands"
|
||||
.hy
|
||||
.SH NAME
|
||||
.PP
|
||||
jstatd \- monitor the creation and termination of instrumented Java
|
||||
jstatd - monitor the creation and termination of instrumented Java
|
||||
HotSpot VMs
|
||||
.SH SYNOPSIS
|
||||
.PP
|
||||
\f[B]Note:\f[R] This command is experimental and unsupported.
|
||||
.PP
|
||||
\f[CB]jstatd\f[R] [\f[I]options\f[R]]
|
||||
\f[V]jstatd\f[R] [\f[I]options\f[R]]
|
||||
.TP
|
||||
.B \f[I]options\f[R]
|
||||
This represents the \f[CB]jstatd\f[R] command\-line options.
|
||||
\f[I]options\f[R]
|
||||
This represents the \f[V]jstatd\f[R] command-line options.
|
||||
See \f[B]Options for the jstatd Command\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \f[CB]jstatd\f[R] command is an RMI server application that monitors
|
||||
The \f[V]jstatd\f[R] command is an RMI server application that monitors
|
||||
for the creation and termination of instrumented Java HotSpot VMs and
|
||||
provides an interface to enable remote monitoring tools, \f[CB]jstat\f[R]
|
||||
and \f[CB]jps\f[R], to attach to JVMs that are running on the local host
|
||||
provides an interface to enable remote monitoring tools, \f[V]jstat\f[R]
|
||||
and \f[V]jps\f[R], to attach to JVMs that are running on the local host
|
||||
and collect information about the JVM process.
|
||||
.PP
|
||||
The \f[CB]jstatd\f[R] server requires an RMI registry on the local host.
|
||||
The \f[CB]jstatd\f[R] server attempts to attach to the RMI registry on the
|
||||
default port, or on the port you specify with the \f[CB]\-p\f[R]
|
||||
\f[CB]port\f[R] option.
|
||||
The \f[V]jstatd\f[R] server requires an RMI registry on the local host.
|
||||
The \f[V]jstatd\f[R] server attempts to attach to the RMI registry on
|
||||
the default port, or on the port you specify with the \f[V]-p\f[R]
|
||||
\f[V]port\f[R] option.
|
||||
If an RMI registry is not found, then one is created within the
|
||||
\f[CB]jstatd\f[R] application that\[aq]s bound to the port that\[aq]s
|
||||
indicated by the \f[CB]\-p\f[R] \f[CB]port\f[R] option or to the default RMI
|
||||
registry port when the \f[CB]\-p\f[R] \f[CB]port\f[R] option is omitted.
|
||||
\f[V]jstatd\f[R] application that\[aq]s bound to the port that\[aq]s
|
||||
indicated by the \f[V]-p\f[R] \f[V]port\f[R] option or to the default
|
||||
RMI registry port when the \f[V]-p\f[R] \f[V]port\f[R] option is
|
||||
omitted.
|
||||
You can stop the creation of an internal RMI registry by specifying the
|
||||
\f[CB]\-nr\f[R] option.
|
||||
\f[V]-nr\f[R] option.
|
||||
.SH OPTIONS FOR THE JSTATD COMMAND
|
||||
.TP
|
||||
.B \f[CB]\-nr\f[R]
|
||||
\f[V]-nr\f[R]
|
||||
This option does not attempt to create an internal RMI registry within
|
||||
the \f[CB]jstatd\f[R] process when an existing RMI registry isn\[aq]t
|
||||
the \f[V]jstatd\f[R] process when an existing RMI registry isn\[aq]t
|
||||
found.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-p\f[R] \f[I]port\f[R]
|
||||
\f[V]-p\f[R] \f[I]port\f[R]
|
||||
This option sets the port number where the RMI registry is expected to
|
||||
be found, or when not found, created if the \f[CB]\-nr\f[R] option
|
||||
be found, or when not found, created if the \f[V]-nr\f[R] option
|
||||
isn\[aq]t specified.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-r\f[R] \f[I]rmiport\f[R]
|
||||
\f[V]-r\f[R] \f[I]rmiport\f[R]
|
||||
This option sets the port number to which the RMI connector is bound.
|
||||
If not specified a random available port is used.
|
||||
.RS
|
||||
.RE
|
||||
.TP
|
||||
.B \f[CB]\-n\f[R] \f[I]rminame\f[R]
|
||||
\f[V]-n\f[R] \f[I]rminame\f[R]
|
||||
This option sets the name to which the remote RMI object is bound in the
|
||||
RMI registry.
|
||||
The default name is \f[CB]JStatRemoteHost\f[R].
|
||||
If multiple \f[CB]jstatd\f[R] servers are started on the same host, then
|
||||
The default name is \f[V]JStatRemoteHost\f[R].
|
||||
If multiple \f[V]jstatd\f[R] servers are started on the same host, then
|
||||
the name of the exported RMI object for each server can be made unique
|
||||
by specifying this option.
|
||||
However, doing so requires that the unique server name be included in
|
||||
the monitoring client\[aq]s \f[CB]hostid\f[R] and \f[CB]vmid\f[R] strings.
|
||||
.RS
|
||||
.RE
|
||||
the monitoring client\[aq]s \f[V]hostid\f[R] and \f[V]vmid\f[R] strings.
|
||||
.TP
|
||||
.B \f[CB]\-J\f[R]\f[I]option\f[R]
|
||||
This option passes a Java \f[CB]option\f[R] to the JVM, where the option
|
||||
\f[V]-J\f[R]\f[I]option\f[R]
|
||||
This option passes a Java \f[V]option\f[R] to the JVM, where the option
|
||||
is one of those described on the reference page for the Java application
|
||||
launcher.
|
||||
For example, \f[CB]\-J\-Xms48m\f[R] sets the startup memory to 48 MB.
|
||||
For example, \f[V]-J-Xms48m\f[R] sets the startup memory to 48 MB.
|
||||
See \f[B]java\f[R].
|
||||
.RS
|
||||
.RE
|
||||
.SH SECURITY
|
||||
.PP
|
||||
The \f[CB]jstatd\f[R] server can monitor only JVMs for which it has the
|
||||
The \f[V]jstatd\f[R] server can monitor only JVMs for which it has the
|
||||
appropriate native access permissions.
|
||||
Therefore, the \f[CB]jstatd\f[R] process must be running with the same
|
||||
Therefore, the \f[V]jstatd\f[R] process must be running with the same
|
||||
user credentials as the target JVMs.
|
||||
Some user credentials, such as the root user in Linux and OS X operating
|
||||
systems, have permission to access the instrumentation exported by any
|
||||
JVM on the system.
|
||||
A \f[CB]jstatd\f[R] process running with such credentials can monitor any
|
||||
A \f[V]jstatd\f[R] process running with such credentials can monitor any
|
||||
JVM on the system, but introduces additional security concerns.
|
||||
.PP
|
||||
The \f[CB]jstatd\f[R] server doesn\[aq]t provide any authentication of
|
||||
The \f[V]jstatd\f[R] server doesn\[aq]t provide any authentication of
|
||||
remote clients.
|
||||
Therefore, running a \f[CB]jstatd\f[R] server process exposes the
|
||||
instrumentation export by all JVMs for which the \f[CB]jstatd\f[R] process
|
||||
has access permissions to any user on the network.
|
||||
Therefore, running a \f[V]jstatd\f[R] server process exposes the
|
||||
instrumentation export by all JVMs for which the \f[V]jstatd\f[R]
|
||||
process has access permissions to any user on the network.
|
||||
This exposure might be undesirable in your environment, and therefore,
|
||||
local security policies should be considered before you start the
|
||||
\f[CB]jstatd\f[R] process, particularly in production environments or on
|
||||
\f[V]jstatd\f[R] process, particularly in production environments or on
|
||||
networks that aren\[aq]t secure.
|
||||
.PP
|
||||
For security purposes, the \f[CB]jstatd\f[R] server uses an RMI
|
||||
For security purposes, the \f[V]jstatd\f[R] server uses an RMI
|
||||
ObjectInputFilter to allow only essential classes to be deserialized.
|
||||
.PP
|
||||
If your security concerns can\[aq]t be addressed, then the safest action
|
||||
is to not run the \f[CB]jstatd\f[R] server and use the \f[CB]jstat\f[R] and
|
||||
\f[CB]jps\f[R] tools locally.
|
||||
However, when using \f[CB]jps\f[R] to get a list of instrumented JVMs, the
|
||||
list will not include any JVMs running in docker containers.
|
||||
is to not run the \f[V]jstatd\f[R] server and use the \f[V]jstat\f[R]
|
||||
and \f[V]jps\f[R] tools locally.
|
||||
However, when using \f[V]jps\f[R] to get a list of instrumented JVMs,
|
||||
the list will not include any JVMs running in docker containers.
|
||||
.SH REMOTE INTERFACE
|
||||
.PP
|
||||
The interface exported by the \f[CB]jstatd\f[R] process is proprietary and
|
||||
guaranteed to change.
|
||||
The interface exported by the \f[V]jstatd\f[R] process is proprietary
|
||||
and guaranteed to change.
|
||||
Users and developers are discouraged from writing to this interface.
|
||||
.SH EXAMPLES
|
||||
.PP
|
||||
The following are examples of the \f[CB]jstatd\f[R] command.
|
||||
The \f[CB]jstatd\f[R] scripts automatically start the server in the
|
||||
The following are examples of the \f[V]jstatd\f[R] command.
|
||||
The \f[V]jstatd\f[R] scripts automatically start the server in the
|
||||
background.
|
||||
.SH INTERNAL RMI REGISTRY
|
||||
.PP
|
||||
This example shows how to start a \f[CB]jstatd\f[R] session with an
|
||||
This example shows how to start a \f[V]jstatd\f[R] session with an
|
||||
internal RMI registry.
|
||||
This example assumes that no other server is bound to the default RMI
|
||||
registry port (port \f[CB]1099\f[R]).
|
||||
registry port (port \f[V]1099\f[R]).
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jstatd\f[R]
|
||||
\f[V]jstatd\f[R]
|
||||
.RE
|
||||
.SH EXTERNAL RMI REGISTRY
|
||||
.PP
|
||||
This example starts a \f[CB]jstatd\f[R] session with an external RMI
|
||||
This example starts a \f[V]jstatd\f[R] session with an external RMI
|
||||
registry.
|
||||
.IP
|
||||
.nf
|
||||
@ -160,55 +163,55 @@ jstatd
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
This example starts a \f[CB]jstatd\f[R] session with an external RMI
|
||||
registry server on port \f[CB]2020\f[R].
|
||||
This example starts a \f[V]jstatd\f[R] session with an external RMI
|
||||
registry server on port \f[V]2020\f[R].
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jrmiregistry\ 2020&
|
||||
jstatd\ \-p\ 2020
|
||||
jrmiregistry 2020&
|
||||
jstatd -p 2020
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
This example starts a \f[CB]jstatd\f[R] session with an external RMI
|
||||
registry server on port \f[CB]2020\f[R] and JMX connector bound to port
|
||||
\f[CB]2021\f[R].
|
||||
This example starts a \f[V]jstatd\f[R] session with an external RMI
|
||||
registry server on port \f[V]2020\f[R] and JMX connector bound to port
|
||||
\f[V]2021\f[R].
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
jrmiregistry\ 2020&
|
||||
jstatd\ \-p\ 2020\ \-r\ 2021
|
||||
jrmiregistry 2020&
|
||||
jstatd -p 2020 -r 2021
|
||||
\f[R]
|
||||
.fi
|
||||
.PP
|
||||
This example starts a \f[CB]jstatd\f[R] session with an external RMI
|
||||
This example starts a \f[V]jstatd\f[R] session with an external RMI
|
||||
registry on port 2020 that\[aq]s bound to
|
||||
\f[CB]AlternateJstatdServerName\f[R].
|
||||
\f[V]AlternateJstatdServerName\f[R].
|
||||
.IP
|
||||
.nf
|
||||
\f[CB]
|
||||
rmiregistry\ 2020&
|
||||
jstatd\ \-p\ 2020\ \-n\ AlternateJstatdServerName
|
||||
rmiregistry 2020&
|
||||
jstatd -p 2020 -n AlternateJstatdServerName
|
||||
\f[R]
|
||||
.fi
|
||||
.SH STOP THE CREATION OF AN IN\-PROCESS RMI REGISTRY
|
||||
.SH STOP THE CREATION OF AN IN-PROCESS RMI REGISTRY
|
||||
.PP
|
||||
This example starts a \f[CB]jstatd\f[R] session that doesn\[aq]t create an
|
||||
RMI registry when one isn\[aq]t found.
|
||||
This example starts a \f[V]jstatd\f[R] session that doesn\[aq]t create
|
||||
an RMI registry when one isn\[aq]t found.
|
||||
This example assumes an RMI registry is already running.
|
||||
If an RMI registry isn\[aq]t running, then an error message is
|
||||
displayed.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jstatd\ \-nr\f[R]
|
||||
\f[V]jstatd -nr\f[R]
|
||||
.RE
|
||||
.SH ENABLE RMI LOGGING
|
||||
.PP
|
||||
This example starts a \f[CB]jstatd\f[R] session with RMI logging
|
||||
This example starts a \f[V]jstatd\f[R] session with RMI logging
|
||||
capabilities enabled.
|
||||
This technique is useful as a troubleshooting aid or for monitoring
|
||||
server activities.
|
||||
.RS
|
||||
.PP
|
||||
\f[CB]jstatd\ \-J\-Djava.rmi.server.logCalls=true\f[R]
|
||||
\f[V]jstatd -J-Djava.rmi.server.logCalls=true\f[R]
|
||||
.RE
|
||||
|
||||
@ -71,6 +71,11 @@ public class CheckManPageOptions {
|
||||
void run(String... args) throws Exception {
|
||||
var file = args.length == 0 ? findDefaultFile() : Path.of(args[0]);
|
||||
out.println("File: " + file);
|
||||
out.println(Files.readAllLines(file).stream()
|
||||
.filter(l -> l.contains("Automatically generated by Pandoc"))
|
||||
.findFirst()
|
||||
.map(l -> l.substring(l.indexOf("Auto")))
|
||||
.orElse("version string not found"));
|
||||
out.println();
|
||||
|
||||
var manPageOptions = getManPageOptions(file);
|
||||
@ -222,31 +227,34 @@ public class CheckManPageOptions {
|
||||
// In the troff man page, options are defined in one of two forms:
|
||||
// 1. options delegated to javac appear in pairs of lines of the form
|
||||
// .IP \[bu] 2
|
||||
// \f[CB]\-....
|
||||
// 2. options implemented by the tool or doclet appear in lines of the form
|
||||
// .B \f[CB]\-...
|
||||
// \f[V]-....
|
||||
// 2. options implemented by the tool or doclet appear in pairs of lines of the form
|
||||
// .TP
|
||||
// \f[V]-...
|
||||
|
||||
Pattern p1 = Pattern.compile("\\R" + Pattern.quote(".IP \\[bu] 2") + "\\R" + Pattern.quote("\\f[CB]\\-") + ".*");
|
||||
Pattern p2 = Pattern.compile("\\R" + Pattern.quote(".B \\f[CB]\\-") + ".*");
|
||||
Pattern p1 = Pattern.compile("\\R" + Pattern.quote(".IP \\[bu] 2") + "\\R" + Pattern.quote("\\f[V]-") + ".*");
|
||||
Pattern p2 = Pattern.compile("\\R" + Pattern.quote(".TP") + "\\R" + Pattern.quote("\\f[V]-") + ".*");
|
||||
Pattern outer = Pattern.compile("(" + p1.pattern() + "|" + p2.pattern() + ")");
|
||||
Matcher outerMatcher = outer.matcher(page);
|
||||
|
||||
// In the defining areas, option names are represented as follows:
|
||||
// \f[CB]OPTION\f[R] or \f[CB]OPTION:
|
||||
// \f[V]OPTION\f[R] or \f[V]OPTION:
|
||||
// where OPTION is the shortest string not containing whitespace or colon,
|
||||
// and in which all '-' characters are escaped with a single backslash.
|
||||
|
||||
Pattern inner = Pattern.compile("\\s\\\\f\\[CB](\\\\-[^ :]+?)(:|\\\\f\\[R])");
|
||||
Pattern inner = Pattern.compile("\\s\\\\f\\[V](-[^ :]+?)(:|\\\\f\\[R])");
|
||||
|
||||
while (outerMatcher.find()) {
|
||||
String lines = outerMatcher.group();
|
||||
out.println("found:" + lines + "\n");
|
||||
out.println("found:" + lines);
|
||||
|
||||
Matcher innerMatcher = inner.matcher(lines);
|
||||
while (innerMatcher.find()) {
|
||||
String option = innerMatcher.group(1).replace("\\-", "-");
|
||||
String option = innerMatcher.group(1);
|
||||
out.println(" found option:" + option);
|
||||
list.add(option);
|
||||
}
|
||||
out.println();
|
||||
}
|
||||
|
||||
return list;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user