March 2019
Intermediate to advanced
242 pages
6h 21m
English
You can manually control usage of CDS by switching it on, switching it off, or putting it on automode. These are the command-line options to do so:
Let's quickly define a class as follows:
class ConquerWorld {
public static void main(String args[]) {
System.out.println("Go and conquer the world");
}
}
Let's execute the preceding class (ConquerWorld) using the shared archive file, classes.jsa. To view the system class loading from the shared archive, you can use a log file with class execution, as follows:
java -Xlog:class+load:file=myCDSlog.log ConquerWorld
The preceding command outputs the following: ...
Read now
Unlock full access