Redwood Documentation

Product Documentation

 

You are currently viewing the legacy RunMyJobs documentation site. This site will be taken down later this month.
All current and future RunMyJobs documentation, including versions 2023.3 and later, can be found here.
Please update your bookmarks. Use the version dropdown menu to select the documentation you need.

›JDBC

RunMyJobsJDBC

JDBC

  • Connecting to Remote Databases with JDBC

JDBC Process Servers

  • Creating JDBC Process Servers using the Wizard
  • Creating JDBC Process Servers Manually

JDBC Drivers

  • JDBC Drivers
  • Using the JDBC Definition Type
  • JDBC Process Definition Wizard
Creating JDBC Process Servers using the Wizard →

Connecting to Remote Databases with JDBC

The JDBC standard allows you to connect to third-party databases and perform queries against the remote database. Redwood Server allows you to interface with JDBC. You can execute calls in database-specific dialects as well as stored procedures.

JDBC, OracleJob, and SQLPLUS Definition Types with Oracle Databases

If you need to execute calls against an Oracle database, consider the following options:

  • JDBC Definition Type - requires a JDBC process server, the output is stored on the central Redwood Server. Accepts both PL/SQL calls and JDBC queries. Numerous parameter mapping options are available, see JDBC Definition Type
  • SQLPLUS Definition Type - requires a platform agent with sqlplus executable, the output is stored on the platform agent. Accepts PL/SQL and SQL*PLUS code. Parameters are accessed and set as substitution variables.
  • OracleJob Definition Type - requires Redwood Server to be installed in an Oracle database, the output is stored on the central Redwood Server. Accepts a single anonymous PL/SQL block per process definition. Parameters are bound using OracleNamed bind mode.
note

On on-site environments, JDBC requires the ProcessServerService.JDBC.limit license key.

Tabs and Fields

TabFieldDescription
DatabaseNameThe name must start with a US ASCII letter, can contain only US ASCII letters, numbers, and underscores (_). Limited to 80 characters.
DatabaseDescriptionFree form text, can contain any printable UTF-8 character combination. Limited to 255 characters. Note that the browsers must be able to display the character.
DatabaseApplicationThe application to use for the database.
DatabaseConnection > LibraryThe library with the JDBC driver if you do not wish to use a driver on the class path
DatabaseConnection > Jdbc Driver Class NameThe class name of the JDBC driver; see the documentation for your JDBC driver for more information.
DatabaseConnection > Jdbc UrlTwo options are available to specify the JDBC connect string; using host, port (optional), and database specifier (Simple) or specifying the JDBC URL (Advanced). Note that the Simple method is only supported for specific databases.
DatabaseConnection > Auto Commit StyleThe type of commit policy you require:
Transaction Based - (default) a commit is performed at the end of every process run, this allows you to rollback (revert) all SQL queries on failure
Auto Commit On - a commit is performed after each query.
Auto Commit Off - no commit is performed, you are expected to code commits where you see fit.
DatabaseConnection UserThe JDBC credential to use for the database connection.
DocumentationDocumentationFree form text, can contain any printable UTF-8 character sequence.
Connect Pool SettingsMax Number Of ConnectionsMaximum number of physical connections the process server can establish to the remote database.
Connect Pool SettingsPooling StateControls the connection pool. When set to Disabled (default), connection pooling is disabled. Accepts values Enabled and DisabledForProcesses (connection pooling is disabled for JDBC and OracleJob processes source only and enabled for REL expressions, for example).
Connect Pool SettingsDriver PropertiesList of Java properties for the JDBC driver
Connect Pool SettingsMax Connect Time (ms)The maximum amount of time to keep a connection in the pool.
Connect Pool SettingsMax Idle Time (ms)The maximum amount of time a connection may remain idle before it is closed.
Connect Pool SettingsMax Abandoned Time (ms)The maximum amount of time the process server will wait before closing the connection.
Connect Pool SettingsFrequent UsersUsers requiring specific maximum connections and/or idle times.
Connect Pool SettingsMax Connections Per Frequent UserMaximum number of physical connections per user (from Frequent Users list) the process server can establish to the remote database.
Connect Pool SettingsMin Idle Connections Per Frequent UserMinimum number of idle connections the process server should keep open for users from the Frequent Users list.
Connect Pool SettingsMax Connections Per Non-Frequent UserMaximum number of physical connections per user (for users not on the Frequent Users list) the process server can establish to the remote database.
Connect Pool SettingsInitialization QueryA query that will be called each time a connection is opened.
Connect Pool SettingsValidation QueryA query that is performed after a successful login and after any severe SQL exception.
Connect Pool SettingsSevere SQL ExceptionsComma-separated list of exceptions that the process server should consider fatal, causing the process server to issue the ValidationQuery.
Connect Pool SettingsNon Transient Connect SQL ExceptionsComma-separated list of exceptions that should be considered non-transient (exceptions that should prevent the process server from retrying).
Connect Pool SettingsInvalid User Name Or Password SQL ExceptionsComma-separated list of exceptions that should be mapped to invalid username or password.

JDBC Drivers

note

There are a number of JDBC drivers for different databases. Always use the latest for your specific database version. Some JDBC drivers only allow connecting to newer database versions, ensure the JDBC driver is compatible with your database version.

The following is required to use the JDBC driver:

  • JDBC driver (jar file)
  • driver name
  • database URL
  • database name and username/password

The JDBC drivers usually have a driver name, for example oracle.jdbc.OracleDriver is the name of Oracle's thin client. Drivers also require a database URL, for example, the Oracle thin client can use jdbc:oracle:thin:@<host>:<port>:<SID> or jdbc:oracle:thin:@<host>:<port>/<service>. Always read the documentation that is provided with your JDBC driver. For example, on Oracle 12c, you connect to a PDB using the service name jdbc:oracle:thin:@<host>:<port>/<service>.

Connection Pool

You enable a connection pool to increase the performance of JDBC, OracleJob processes, and REL expressions making calls to remote databases. Note that when connection pooling is enabled and a JDBC or OracleJob process starts running, instead of creating a connection to the remote database, the process server uses a connection from a connection pool. Once the process has reached a final status, the connection is not closed but returned to the pool for another process to use. Special caution needs to be taken when you enable connection pooling, because you cannot make assertions about variables holding initial values, for example, or that locks are automatically released when processing finishes.

You can partially enable connection pooling for REL expressions, for example, and keep it disabled for JDBC and OracleJob processes; this is controlled by the Pooling State.

Process Flow

  1. You put the JDBC driver (jar file) into the CLASSPATH of your application server (AS), alternatively, you can upload it into a Redwood Server Library.
  2. You create a process server for JDBC using the wizard or process server for JDBC manually.
  3. You create one or more credential(s) for JDBC (also covered in the JDBC process server topic).
  4. You create one or more JDBC process definitions, you can use the JDBC Process Definition Wizard to jump-start.

See Also

  • JDBC Drivers
  • Creating JDBC Process Servers Using the Wizard
  • Creating JDBC Process Servers
  • JDBC Process Definition Wizard
  • JDBC Definition Types
  • JDBC Definition Type

jdbc

Creating JDBC Process Servers using the Wizard →
  • JDBC, OracleJob, and SQLPLUS Definition Types with Oracle Databases
  • Tabs and Fields
  • JDBC Drivers
  • Connection Pool
  • Process Flow
  • See Also
Docs
Getting StartedInstallationFinance InstallationConcepts
TroubleshootingArchiving
Learn and Connect
Support Portal
BlogEventsResources
ISO/ IEC 27001 Information Security Management
Automate to be human

2023 All Rights Reserved |

Terms of Service | Policies | Cookies | Glossary | Third-party Software | Contact | Copyright | Impressum |