NonStop Server for Java Programmer's Reference (NSJ 4.2+)
Be familiar with the issues discussed in the Application Programming with Standard POSIX Threads
section of the OSS Programmers Guide.
This section contains information about the jacket routines that make many of the available system calls
thread-aware. The interfaces themselves, however, are documented in the OSS System Calls Reference
Manual.
To use these jacket routines, you need to add the following define in your native code.
#define SPT_THREAD_AWARE
Adding this define in the native C/C++ code, transparently provides you the thread-aware equivalents of
many of the interfaces, for example, the Socket interface. Additionally, the interfaces are available to
determine if a socket is read-ready (spt_fd_read_ready) or write-ready (spt_fd_write_ready).
The Socket implementation on NonStop systems supports streaming; multiple sends and receives are
outstanding at a time.
●
Be careful when using thread-aware interfaces.
The OSS Programmers Guide lists thread-aware equivalents of NonStop system-specific interfaces. These
interfaces have an explicit spt_ prefix.
For example, when using a thread-aware function, do not attempt to control the set of files that are enabled
for completion or directly attempt to wait for a completion on a file registered with pthreads
(FILE_COMPLETE_SET_, FILE_COMPLETE_, AWAITIO, or AWAITIOX procedure).
●
Java Print Service (JPS)
The Java Print Service is implemented in NonStop Server for Java 4. The Java Print Service allows you to print on
printers directly to NonStop systems and to network printers attached to a local area network (LAN) or wide area
network (WAN). For information on configuring network printers, see the Spooler FASTP Network Print
Processes Manual. For information on the Spooler subsystem, see the Spooler Utilities Reference Manual.
The Java Print Service implemented into NonStop Server for Java 4 uses the headless version of the javax.print
API. All printing features and attributes in the JPS classes listed below work when the NonStop Kernel spooler and
printer support the API. However, the NonStop Kernel requirement for sending text and postscript files to separate
printers also applies when printing under JPs The JPs classes are:
javax.print●
javax.print.attribute●
javax.print.attribute.standard●
javax.print.event●
Java Authentication and Authorization
Service (JAAS)
The Java Authentication and Authorization Service (JAAS) is integrated into the NonStop Server for Java 4. JAAS
augments the core Java 2 platform with facilities to authenticate and enforce access controls upon users. JAAS,
also, has the ability to enforce access controls based on who runs the code.
JAAS implements a Java version of the standard Pluggable Authentication Module (PAM) framework. This