Installing the JRebel plugin
- Go to Extensions in VSCode. (View -> Extensions)
- Search JRebel.
- Click Install.
- Accept terms.
Did this work?
If the installation was a success, your IDE will prompt a restart. After the restart, JRebel will be available to you in the left toolbar.
Getting a License
- Click JRebel view in left dashboard.
- Click Dashboard
- In Licenses section, Click “Add License”
Got a license?
Press I already have a license in the activation window.
- Activation code. Paste your activation code if you have one already.
- License file from the hard drive. Point to your
jrebel.lic
jrebel.lic file. You get this file via email when you purchase JRebel. - Connect to ZeroTurnaround License Management or an on-premises License Server. Enter your team URL and email. You get the team URL from your network administrator.
Don’t Have License?
Click “Individual Trial”
- Fill in information requested.
- Accept terms and click OK.
- Trial license distributed to your machine.
Mapping your workspace to the deployed application
- Open JRebel view (View -> Open View -> Search “JRebel”) and Click “Go to Projects”.
- Select the
check box for each project that you want to add JRebel to. This will generate
rebel.xml
and keep it up to date. - Redeploy your application (or restart your standalone application).
Didn’t work?
- Using Maven? Use the JRebel Maven plugin to generate the
rebel.xml
. JRebel Maven instructions. - Running Gradle? Use the JRebel Gradle plugin to generate
rebel.xml
. JRebel Gradle instructions. - Need to tweak your
rebel.xml
? JRebel rebel.xml reference manual has the answers.
Did this Work?
When building your application, rebel.xml
should be included within the application archive.
- In case of JAR files,
rebel.xml
should be included in the root folder. - When working with WAR files, the
rebel.xml
should be located within the WEB-INF/classes folder. - EAR files require a
rebel.xml
for each internal EAR module (that means JARs and WARs).
Adding JRebel agent to your server or standalone application
How do you run your server?
- Via IDE
- Locally from command line
- On a remote server
Run via IDE
- Open JRebel view (View -> Open View -> Search “JRebel”).
- Click Startup – Guide.
- Click “Run via IDE”.
- Select the check-box next to your application server. Doing this will automatically run it with the required JVM arguments.
Good to know
Not running your server from the IDE? Follow another application server startup method.
Did this work?
When successful, you will see the JRebel banner in the console right at server startup. This is what the JRebel banner should look like:
2016-11-15 12:19:20 JRebel: #############################################################
2016-11-15 12:19:20 JRebel:
2016-11-15 12:19:20 JRebel: JRebel Agent 7.0.0 (201611081555)
2016-11-15 12:19:20 JRebel: (c) Copyright ZeroTurnaround AS, Estonia, Tartu.
2016-11-15 12:19:20 JRebel:
2016-11-15 12:19:20 JRebel: Over the last 1 days JRebel prevented
2016-11-15 12:19:20 JRebel: at least 0 redeploys/restarts saving you about 0 hours.
2016-11-15 12:19:20 JRebel:
2016-11-15 12:19:20 JRebel: Licensed to ZeroTurnaround.
2016-11-15 12:19:20 JRebel:
2016-11-15 12:19:20 JRebel: #############################################################
JRebel in action
- Restart your application server or Java application.
- Change something in the application code.
- Make sure to compile updates made in code.
- Refresh the application in the browser to see the changes!