AngularJS Read System Property JBoss Server

AngularJS Read System Property JBoss Server

In this demo you will see how to set and read system property from JBoss server. This is needed when you are working on big project where you have to read environment property dynamically based on its location. Any medium or large scale project they goes to different stages as an example: Developer works on development, QA perform test on QA and finally project production deployment happens on PROD environment where you will have to read constant setting from property file.

Tools needed:

  • Eclipse Kepler (This comes with built-in maven plug-in)
  • JBoss 6.1 server

First set system property on JBoss application server. Add System properties on JBoss Properties MBean Service.On JBoss deployment folder look for “properties-service.xml” file . (Note: By any change if you don’t find it in your deployment folder you can create it). Below is properties-service.xml file sample:

  • As you see above file we have create below property and will read on AngularJS page:

  • Now create maven web project: JavaHonkAngularJSJBoss
  • Below is final project structure:

AngularJS Read System Property JBoss Server

Flow description: AngularJS page will make request to utilityServlet which will read system properties from JBoss server and return back the response.


  • AngularJS index.html page:

  • Now run this application on JBoss server. If you are not sure how to configure and run JBoss inside eclipse please use this tutorial. Start JBoss server and to see output use below URL in browser:

AngularJS Read System Property JBoss Server

  •  For more information please follow this link for AngularJS and here for JBoss

download Download Project: JavaHonkAngularJSJBoss

Leave a Reply

Your email address will not be published. Required fields are marked *

I am not Robot *