NonStop Server for Java Tools Reference Pages Abstract This document consists of this title page, a table of contents, and the Tools Reference Pages for the HP NonStop™ Server for Java™, based on Java 2 Platform, Standard Edition, SDK 1.4.1. Product Version NonStop Server for Java (based on J2SE SDK 1.4.1) 1.0 Supported Hardware All HP NonStop S-series servers except S700 and S70000. Supported Release Version Updates (RVUs) This manual supports G06.
526239-001 NonStop Server for Java (based on October 2003 J2SE SDK 1.4.1) 1.0 Ordering Information For manual ordering information: domestic U.S. customers, call 1-800-243-6886; international customers, contact your local sales representative. Legal Notices Copyright 2003 Hewlett-Packard Development Company L.P.
Mentat Inc. © 1988 Microsoft Corporation. © 1987, 1988, 1989, 1990, 1991, 1992 SecureWare, Inc. © 1990, 1991 Siemens Nixdorf Informationssysteme AG. © 1986, 1989, 1996, 1997 Sun Microsystems, Inc. © 1989, 1990, 1991 Transarc Corporation. OSF software and documentation are based in part on the Fourth Berkeley Software Distribution under license from The Regents of the University of California. OSF acknowledges the following individuals and institutions for their role in its development: Kenneth C.R.C.
© 2003 Hewlett-Packard Development Company L.P. All rights reserved.
NonStop Server for Java 4 Tools Reference Pages Command Tool Name Function extcheck JAR Conflict Detection Tool Detects version conflicts between a target Java Archive (JAR) file and currently installed extension JAR files. idlj IDL-to-Java Compiler Generates Java bindings from a specified IDL file. jar Java Archive Tool Combines multiple files into a single JAR file and retrieves files from a JAR file.
Key and Certificate Management Tool keytool native2ascii Native-to-ASCII Converter Manages a database of private keys and their associated certificate chains authenticating the corresponding public keys. Converts a file with native-encoded characters to one with Unicode-encoded characters. orbd Object Request Broker Daemon Enables clients to transparently locate and invoke persistent objects on servers in the CORBA environment.
Tools Home Page extcheck: JAR Conflict Detection Tool The extcheck tool detects version conflicts between a target Java Archive (JAR) file and currently installed extension JAR files. For a complete description of the tool and its use, see the Sun Microsystems documentation for extcheck. Synopsis extcheck [ -verbose ] targetfile.jar See Also: jar Tools Home Page NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P. All rights reserved.
Tools Home Page idlj: IDL-to-Java Compiler The idlj tool generates Java bindings from a specified IDL (Interface Definition Language) file. For a complete description of the tool and its use, see the Sun Microsystems documentation for idlj. Synopsis idlj [ options ] idl-file Tools Home Page NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P. All rights reserved.
Tools Home Page jar: Java Archive Tool The jar tool combines multiple files into a single Java Archive (JAR) file or retrieves files from a JAR file. For a complete description of the tool and its use, see the Sun Microsystems documentation for jar. Synopsis jar [ options ] [ jar-file ] [ manifest-file ] [ file | directory ] ... Tools Home Page NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P All rights reserved.
Tools Home Page jarsigner: JAR Signing and Verification Tool The jarsigner tool generates signatures for Java Archive (JAR) files and verifies the signatures of signed JAR files. For a complete description of the tool and its use, see the Sun Microsystems documentation for jarsigner.
Tools Home Page java: Java Application Launcher ● Synopsis ● Deviations from Standard Java Options ● Nonstandard Java Options ● Deviations from Nonstandard Java Options ● HP Extensions to Standard Java Options ● See Also The java tool launches a Java application by starting a Java run-time environment, loading a specified class, and invoking that class' main method. For a complete description of the tool and its use, see the Sun Microsystems documentation for java.
-d64 Selects whether the program is to be run in a 32-bit or 64-bit environment. Note: These options are not valid with NonStop Server for Java 4, which uses only the 32-bit environment to run Java programs. Nonstandard Java Options The following nonstandard options are shown for your convenience; their implementations are a typical Java implementation. -Xssn Sets the thread stack size. Every thread spawned while a Java program runs has its own stack.
-XX:+UseConcMarkSweepGC Specifies using the concurrent mark-sweep garbage collector. This option is disabled. If you specify this option, the Java VM exits with the error: -XX:+UseConcMarkSweepGC option is not supported on this platform. -Xconcgc Enables a concurrent mark-sweep garbage collector. This option is disabled. If you specify this option, the Java VM exits with the error: -Xconcgc option is not supported on this platform. -Xincgc Specifies using the incremental low-pause garbage collector.
NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P. All rights reserved.
Tools Home Page javac: Java Programming Language Compiler The javac tool compiles Java source code into bytecode. For a complete description of the tool and its use, see the Sun Microsystems documentation for javac. Synopsis javac [ options ] [ sourcefiles ] [ @argfiles ] Arguments may be in any order. options Command-line options. sourcefiles One or more source files to be compiled (such as MyClass.java). @argfiles One or more files that list options and source files.
NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P. All rights reserved.
Tools Home Page javadoc: Java API Documentation Generator The javadoc tool generates API documentation in HTML format from Java source code. For a complete description of the tool and its use, see the Sun Microsystems documentation for javadoc. Synopsis javadoc [ options ] { package | class.java } ... See Also: ● javac ● rmic ● java ● jdb ● javah ● javap Tools Home Page NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P.
Tools Home Page javah: C Header and Stub File Generator The javah tool generates C header files and stub C source files from a Java class. These files provide the connections that allow your Java code and C code to interact. For a complete description of the tool and its use, see the Sun Microsystems documentation for javah. Synopsis For files that are needed to implement native methods: javah [ options ] fully-qualified-classname ...
Tools Home Page javap: Java Class File Disassembler The javap tool disassembles compiled Java files. For a complete description of the tool and its use, see the Sun Microsystems documentation for javap. Synopsis javap [ options ] class ... See Also: ● javac ● rmic ● java ● jdb ● javah ● javadoc Tools Home Page NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P. All rights reserved.
Tools Home Page jdb: Java Debugger The jdb tool helps you find and fix errors in Java programs. For a complete description of the tool and its use, see the Sun Microsystems documentation for jdb.
Description The Java Debugger, jdb, is a simple command-line debugger for Java classes. It is an example of the use of the Java Platform Debugger Architecture that provides inspection and debugging of a local or remote Java virtual machine (VM). Starting a jdb Session There are many ways to start a jdb session. The most frequent way is to have jdb launch a new Java VM with the main class of application to be debugged. You do this by substituting the command jdb for the command java in the command line.
You can then attach jdb to the Java VM with the following command: jdb -attach 8000 Note: MyClass is not specified in the jdb command line in this case because jdb connects to an existing Java VM instead of launching a new one. There are many other ways to connect the debugger to a Java VM, and all of them are supported by jdb, as specified in Connecting for Remote Debugging. Basic jdb Commands The following is a list of the basic jdb commands.
❍ print myObj.myMethod() (if myMethod() returns a non-null) ❍ print new java.lang.String("Hello").length() dump For primitive values, this command is identical to print. For objects, it prints the current value of each field defined in the object. Static and instance fields are included. The dump command supports the same set of expressions as the print command. threads List the threads that are currently running.
● stop in java.lang.String.length (sets a breakpoint at the beginning of the method java.lang.String.length) ● stop in MyClass.init (init identifies the MyClass constructor) ● stop in MyClass.clinit (clinit identifies the static initialization code for MyClass) If a method is overloaded, you must also specify its argument types so that the proper method can be selected for a breakpoint. For example, MyClass.myMethod(int,java.lang.String), or MyClass.myMethod().
Command-Line Options When you use jdb in place of the Java application launcher on the command line, jdb accepts many of the same options as the java command, including -D, -classpath, and -Xoption. The following additional options are accepted by jdb: -help Displays a help message. -sourcepath directory1 [:directory2]... Uses the given path in searching for source files in the specified path. If this option is not specified, the default path of "." is used.
Deviations from Standard Java -tclient Runs the application in the Java HotSpot client VM. Note: The -tclient option is not valid with NonStop Server for Java 4. -tserv Runs the application in the Java HotSpot server VM. Note: -tserv is the default option for NonStop Server for Java 4; therefore, specifying -tserv is optional. Options Forwarded to the Process Being Debugged -v -verbose[:class|gc|nji] Turns on verbose mode. -D name=value Sets a system property. -classpath directory1 [:directory2]...
-Xrunjdwp:transport=dt_socket,\ address=hostname:portnum,server=y ClassName Note: If address option is not given, the server will start on any available port on the local host and print portnum. This portnum should be used by the jdb to attach. iii. The target JVM attaches to previously running debugger. -listen jdb -listen hostname:portnum To attach a target Java VM, use the following command : java -Xnoagent -Xdebug -Djava.
See Also: ● javac ● java ● javah ● javap ● javadoc Tools Home Page NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P. All rights reserved.
Tools Home Page keytool: Key and Certificate Management Tool The keytool tool manages a keystore (database) of private keys and their associated X.509 certificate chains authenticating the corresponding public keys. For a complete description of the tool and its use, see the Sun Microsystems documentation for keytool.
Tools Home Page native2ascii: Native-to-ASCII Converter The native2ascii tool converts a file that has native-encoded characters (characters that are not Latin-1 and not Unicode) to a file with Unicode-encoded characters. For a complete description of the tool and its use, see the Sun Microsystems documentation for native2ascii.
Tools Home Page orbd: Object Request Broker Daemon The Server Manager included with the ordb tool enables clients to transparently locate and invoke persistent objects on servers in the CORBA environment. For a complete description of the tool and its use, see the Sun Microsystems documentation for orbd.
Tools Home Page rmic: Java RMI Compiler The rmic tool generates stubs and skeletons for remote objects that use either the JRMP or Internet Inter-ORB Protocol (IIOP). The rmic tool also generates Object Management Group (OMG) Interface Definition Language (IDL). For a complete description of the tool and its use, see the Sun Microsystems documentation for rmic. Synopsis rmic [ options ] package-qualified-classname ...
Tools Home Page rmid: Java RMI Activation System Daemon The rmid tool starts the activation system daemon that allows objects to be registered and activated in a Java virtual machine (VM). For a complete description of the tool and its use, see the Sun Microsystems documentation for rmid. Synopsis rmid [ options ] See Also: ● java ● CLASSPATH ● rmic Tools Home Page NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P. All rights reserved.
Tools Home Page rmiregistry: Java Remote Object Registry The rmiregistry tool starts a remote object registry on the specified port on the current host. For a complete description of the tool and its use, see the Sun Microsystems documentation for rmiregistry. Synopsis rmiregistry [ port ] See Also: ● java ● java.rmi.registry.LocateRegistry ● java.rmi.Naming Tools Home Page NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P.
Tools Home Page serialver: Serial Version Command The serialver tool returns the serialVersionUID of one or more classes. For a complete description of the tool and its use, see the Sun Microsystems documentation for serialver. Synopsis serialver [ option ] [ classname ... ] See Also: ● java.io.ObjectStreamClass Tools Home Page NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P. All rights reserved.
Tools Home Page servertool: Java IDL Server Tool The servertool tool provides a command-line interface for application programmers to register, unregister, start up, and shut down a persistent server. For a complete description of the tool and its use, see the Sun Microsystems documentation for servertool.
Tools Home Page tnameserv: Naming Service Access The tnameserv tool starts the Java Interface Definition Language (IDL) name server to provide access to the CORBA Common Object Services (COS) Naming Service. For a complete description of the tool and its use, see the Sun Microsystems documentation for Naming Service. Synopsis tnameserv [ -ORBInitialPort n ] Tools Home Page NonStop Server for Java Tools Reference Pages (526239-001) © 2003 Hewlett-Packard Development Company L.P. All rights reserved.