Specify the JVP
To execute, a UDR written in Java™ code must run in a JVP. The JVP is a predefined virtual-processor class that contains a Java virtual machine to interpret Java byte codes.
Use the following syntax to specify that a UDR executes in the
JVP class:
WITH (class='jvp')
By default, most UDRs run in the CPU VP, which does not contain a Java virtual machine. However, a UDR written in Java code runs on a JVP by default. Therefore, the CLASS routine modifier is optional when you register a UDR written in Java code. To improve readability of your SQL statements, include the CLASS routine modifier when you register a UDR.
For example:
-- Specifying the JVP
CREATE PROCEDURE showusers()
WITH (class='jvp')
EXTERNAL NAME 'thisjar:admin.showusers()'
LANGUAGE java;