JRebel remote server support¶
JRebel can be applied to update applications deployed to a remote environment from developers workstation. Two parts are involved in communication between the developer’s machine and the remote host:
- The IDE plugin responsible for uploading the resources to the remote application.
- The JRebel agent itself that installs an HTTP filter inside of the application for talking to the IDE plugin.
JRebel remote server support with third party cloud platforms¶
JRebel remote server support can be used with the following third party cloud service providers.
JRebel remote server support in your IDE¶
We have prepared guides for setting up JRebel remote server support with specific IDEs.
Troubleshooting JRebel remote server support¶
We have also compiled a list of common issues and how to solve them.
To enable the JRebel agent for the container that the application is deployed to, you need to add a -javaagent parameter to the JVM arguments list. For that you need to modify your server startup script as described in the manual.
The remote server support plugin is disabled by default. You need to add a JVM argument to activate it:
Dedicated port (optional)¶
When your application, deployed to a remote server does not have an HTTP endpoint (e.g. EJB modules and standalone applications), you can designate a port for remote server support to enable JRebel’s embedded Jetty container.
Adding -Drebel.remoting_port=[port number] (e.g. -Drebel.remoting_port=12345) enables the embedded Jetty container inside JRebel. This will be used for handling HTTP requests from the IDE plugin. Note that enabling Jetty will impact performance.
Server-side password configuration¶
To enable password-based security on the server, set the server password using the following command:
$ java -jar jrebel.jar -set-remote-password
To operate, JRebel remote server support requires a configuration file – rebel-remote.xml. This file is used to distinguish between the different application modules. The regular rebel.xml configuration file is ignored when the remote server support plugin is enabled. This file is automatically generated by the IDE and should never be edited manually.
<?xml version="1.0" encoding="UTF-8"?> <rebel-remote> <id>module-id</id> </rebel-remote>
The rebel-remote.xml configuration file should end up in your WEB-INF/classes directory in the case of a web module and in the root of the archive in the case of an EJB module or a JAR library. Put it in the root of a source or resource folder in your project (the same place where the .properties files are) and make sure it is copied to the target directory.
The configuration elements include:
- id is the only required element in rebel-remote.xml configuration file. This is the id of the application module, which will include this configuration. By module, we mean an individual JAR or a WAR file (web archive).
With the release of JRebel 6.2.4, a password-based security measure is included in remote server support with Eclipse. Future releases will roll out the new security protocol for other IDEs as well.
For more information, please refer to the specific IDE remote server chapters: