SQL/MX 3.2.1 Guide to Stored Procedures in Java (H06.26+, J06.15+)
Applications that initiate multiple SQL/MX UDR server processes include NonStop ODBC/MX and
JDBC/MX applications. NonStop ODBC/MX clients often switch user identities. Multithreaded
JDBC/MX applications can use different UDR_JAVA_OPTIONS settings for different threads.
For these types of applications, new SQL/MX UDR server processes are started as needed, and
stop when all the connections that were serviced by the SQL/MX UDR server process end. For
more information, see Conditions Causing Initialization of an SPJ Environment (page 26).
The UDR_JAVA_OPTIONS default attribute controls the JVM startup options in an SPJ environment.
For more information, see Controlling JVM Startup Options (page 36).
Conditions Causing Initialization of an SPJ Environment
When an application issues a CALL statement (that is, invokes an SPJ), the SQL/MX executor starts
a new SQL/MX UDR server process and initializes a new SPJ environment if any of these conditions
are met:
• An SPJ environment is not currently servicing the application (that is, the CALL statement is the
first one executed by the application).
• The SPJ environments that are currently servicing the application are not associated with the
current user identity.
• The CALL statement has a UDR_JAVA_OPTIONS setting (other than ANYTHING) that is different
from the UDR_JAVA_OPTIONS setting in the SPJ environments that are servicing the application
under the current user identity.
See Determining the Uniqueness of UDR_JAVA_OPTIONS Settings (page 39).
Conditions Preventing Initialization of an SPJ Environment
The execution of a CALL statement does not start a new SQL/MX UDR server process and initialize
a new SPJ environment if one of these conditions is met:
• The CALL statement has a UDR_JAVA_OPTIONS setting (other than ANYTHING) that is the
same as the UDR_JAVA_OPTIONS setting in one or more SPJ environments that are servicing
the application under the current user identity.
See Determining the Uniqueness of UDR_JAVA_OPTIONS Settings (page 39).
• The CALL statement has a UDR_JAVA_OPTIONS setting of ANYTHING, and one or more SPJ
environments are currently servicing the application under the current user identity.
Figure 5 shows how SQL/MX UDR server processes and SPJ environments are initialized for an
application.
26 Introduction










