Hello World Application on JBoss

For adding an administrator user for JBoss, execute the “add-user.bat” file located at path (see location on my machine):

“D:\programfiles\jboss-eap-6.4.0\jboss-eap-6.4\bin\add-user.bat”



Check the application logs below:




To start the application, we run the script 'standalone.bat' located at path:
D:\programfiles\jboss-eap-6.4.0\jboss-eap-6.4\bin

Logs:
Calling "D:\programfiles\jboss-eap-6.4.0\jboss-eap-6.4\bin\standalone.conf.bat"
Setting JAVA property to "D:\programfiles\jdk1.8.0_92\bin\java"
========================================================================

  JBoss Bootstrap Environment

  JBOSS_HOME: "D:\programfiles\jboss-eap-6.4.0\jboss-eap-6.4"

  JAVA: "D:\programfiles\jdk1.8.0_92\bin\java"

  JAVA_OPTS: "-verbose:gc -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=5 -XX:GCLogFileSize=3M -XX:-TraceClassUnloading -XX:+UseCompressedOops -Dprogram.name=standalone.bat -Xms1G -Xmx1G -XX:MaxPermSize=256M -Djava.net.preferIPv4Stack=true  -Djboss.modules.policy-permissions=true  -Djboss.modules.system.pkgs=org.jboss.byteman"

========================================================================

Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=256M; support was removed in 8.0
10:44:35,603 INFO  [org.jboss.modules] (main) JBoss Modules version 1.3.6.Final-redhat-1
...
...
...
10:46:32,602 INFO  [org.jboss.as] (Controller Boot Thread) JBAS015874: JBoss EAP 6.4.0.GA (AS 7.5.0.Final-redhat-21) started in 117949ms - Started 753 of 790 services (94 services are lazy, passive or on-demand)


You can also start the JBoss in debug mode using the command:
"standalone.bat –debug 7777"

Now create a Maven project using the item from the Eclipse menu as shown below:


...

...

...
Add an HTML file to the project as shown below:

...

...

...
Export the project as 'WAR' file:


...
Paste the WAR file in 'deployments' folder at path:
"D:\programfiles\jboss-eap-6.4.0\jboss-eap-6.4\standalone\deployments"


...

Then, you can view the page using the URL for it. For my application, URL is:
http://localhost:8090/project4_jboss_intro_revisited/Welcome.html

Here, "project4_jboss_intro_revisited" is the project name and "Welcome.html" is the template.
Note: the URL is case sensitive.



--- End of Post ---

No comments:

Post a Comment