##### OpenJMS

- Overview
- Downloads
- Release Notes
- Getting Started
- User Guide
- Administrator Guide
  - Installation
  - Running OpenJMS
  - Configuration
    - Database
    - Connectors
      - TCP
      - TCPS
      - RMI
      - HTTP
      - HTTPS
      - Embedded
    - JNDI
    - Connection Factories
    - Security
    - Destinations
    - Garbage Collection
    - Reference
- Developer Guide
- FAQ

##### Search OpenJMS

##### Project Documentation

- About
- Project Info
- Project Reports
- Development Process

##### Legend

- External Link
- Opens in a new window

## Overview

The RMI connector enables OpenJMS clients to connect to the OpenJMS server using RMI.

It is configured by adding a <Connector> element to <Connectors> section of the $OPENJMS_HOME/config/openjms.xml file, with a scheme of type "rmi". E.g:

      <Connectors>
        <Connector scheme="rmi">
          <ConnectionFactories>
            <ConnectionFactory name="RMIConnectionFactory"/>
          </ConnectionFactories>
        </Connector>
      </Connectors>

## Using an external RMI registry

By default, the OpenJMS uses an embedded RMI registry for the RMI connector.

An external registry can be configured by changing the <RmiConfiguration> element:

      <RmiConfiguration embeddedRegistry="false"
                        registryHost="<registry-host>"
                        registryPort="<registry-port>">
      </RmiConfiguration>

Where:

- registry-host specifies the host that the RMI registry is running on.

  If not specified, it defaults to localhost.

- registry-port specifies the port that the RMI registry is listening on.

  If not specified, it defaults to 1099.

NOTE: when using an external RMI registry, the registry must be running before the OpenJMS server is started.

## See Also

The following references provide detailed descriptions of the configuration elements related to the RMI connector:

- Connectors
- ServerConfiguration
- RmiConfiguration