Jboss configures hot deployment step by step

Hello, I would like to ask how can I configure a jboss server for something like live, hot deploment:

  • every time I change the code of my jsp, html, js or css file, I always need to clean and build the project, than deploy the project to jboss and again, agian and again. It is dear to me. I spend time on it. It will be easy when I can work with files that already use running jboss (deployed). But these files are in the WAR file "project.war" and through my IDE (Netbeans) I can’t edit these files (jsp, css, html or js). Netbeans made this file unchanged.

enter image description here

I would be happy to decide step by step how to avoid this boring process.

+5
source share
5 answers
  • Edit Standalone.xml, change version to "true"
    <configuration> <jsp-configuration development="true"/> </configuration>

  • Launch JBoss.

  • Go to ServerLocation-> standalone \ tmp \ vfs
  • Sort Descending "Date Modified"
  • Open the first folder (something like ******* deployment)
  • There will be your complete war exploded.
  • Go to jsps, js, css, change and save the changes.
  • changes will be displayed in real time.
+4
source

I think you are looking for something like JRebel . For those who have not had the opportunity to hear about it, this is a magic tool that allows you to get rid of such annoying redeployments after each modification made in your source files.

Since you are using the NetBeans IDE, this is a special tuto explaining how to configure JRebel.

+3
source

Follow this procedure to enable hot deployment in JBOSS.

It will work on JBoos AS 7.0.1 and should work with other versions with minor changes.

  • Go to JBoss admin panel (default localhost: 9990)
  • Now in the profile settings open Core - Deployment Scanners
  • Enable Autodeploy-Explode (set to true)
  • You can set the scan time (default 5000 ms) for your opinion (I prefer to set 2000, for faster incremental publication when making changes to projects)

What is it.

Now JBoss launches HOT for almost all file types

+2
source

I have the same problem. My solution is to run the program in debug mode without editing the configuration file. Once you are done, you can see the result without restarting.

+2
source

Deploy the application as exploded (project.war folder), add to your web.xml:

 <web-app> <context-param> <param-name>org.jboss.weld.development</param-name> <param-value>true</param-value> </context-param> 

Copy the / jsp / etc class, update the web.xml timestamp every time you deploy (add an empty line):

 set PRJ_HOME=C:\Temp2\MyProject\src\main\webapp set PRJ_CLSS_HOME=%PRJ_HOME%\WEB-INF\classes\com\myProject set JBOSS_HOME= C:\Java\jboss-4.2.3.GA-jdk6\server\default\deploy\MyProject.war set JBOSS_CLSS_HOME= %JBOSS_HOME%\WEB-INF\classes\com\myProject copy %PRJ_CLSS_HOME%\frontend\actions\profile\ProfileAction.class %JBOSS_CLSS_HOME%\frontend\actions\profile\ProfileAction.class copy %PRJ_CLSS_HOME%\frontend\actions\profile\AjaxAction.class %JBOSS_CLSS_HOME%\frontend\actions\profile\AjaxAction.class ECHO.>>%JBOSS_HOME%\WEB-INF\web.xml 
0
source

Source: https://habr.com/ru/post/1211504/


All Articles