In my latest conducted survey, I received lots of topic requests to write on, and one of the frequent subjects was JBoss interview preparation. You may also want to check WAS & Apache Interview Q.A. So, I hear you, here you go. Before jumping to Q.A., a little introduction to JBoss AS. WildFly is the new name of the JBoss application server starting from version 8. It was renamed on 20th Nov 2014. WildFly is a community project, and if you are looking for enterprise support with additional features, then you need the Red Hat JBoss Enterprise Application Platform (also known as JBoss EAP). In one line – WildFly is a community version and it’s FREE but JBoss EAP is not. Note: If you are looking to enhance your skills in JBoss EAP then you may refer to this book – JBoss EAP Administration Let’s get into questions/answers.

1. What is the directory structure in JBoss?

The following directories are available after JBoss is installed.

modules bundles domain standalone appclient bin docs welcome-content

2. What are the logging levels available?

There is five possible levels:

FATAL ERROR WARN INFO DEBUG

3. Which component is responsible for handling clustering?

JBoss clustering is on top of JGroups toolkit which helps to create, delete, membership detection, notification, etc. in the cluster.

4. How to install JBoss on Linux server?

JBoss installation is very straightforward. You need to download the desired version from JBoss official download page in zip or gz format. Once downloaded, just extract the file to the location you want to install. If you downloaded zip format, then you can use unzip command to extract it.

5. What’s the default port to access Administration Console in JBoss 7?

9990 is the default port. If it’s installed on server1 then you need to access like:

6. What must be done to access Admin Console?

The user must be created under “ManagementRealm” to have console operational. To create the user, you can go to bin folder and execute add-user.sh script.

7. How to start JBoss in standalone mode?

Go to the bin folder where JBoss is installed and start with the following command.

8. How to increase Java Heap Memory in JBoss 7?

Heap Memory can be increased in a respective conf file. To increase memory for standalone;

Go to the bin folder Edit the standalone.conf file and look for “JAVA_OPTS=” argument line The default configuration will have a minimum of 64 MB and a maximum of 512 MB. You can increase to the desired value.

In a similar way, you can adjust the memory for a domain in domain.conf file

9. What is the difference between standalone and domain mode?

Standalone mode is single JVM process where every JBoss server has its configuration. If you just need one JVM or development environment, then standalone would be perfect. Domain mode may have multiple servers where all configuration is managed centralized and often used in production environment.

10. Can you create a cluster in standalone mode?

Yes, clustering is possible in standalone mode. However, an application must be deployed on each server/JVM in standalone mode.

11. What is difference between and ?

validate the database connection every time, and if a connection is not valid, it will write a warning in the logs. Having “validate-on-match” configured may have a little high load on the database as it may create lots of requests. validate the connection periodically based on what frequency is configured for “background-validation-millis”. The default configuration is set to zero means disabled. Having “ background-validation” set to true will create fewer database connections and it’s side-effects would be not detecting immediately if dead connections.

12. What module needed to integrate Apache with JBoss?

There are two modules you can use to connect JBoss with Apache.

mod_proxy mod_jk

13. What are the file types you can deploy in JBoss?

You can deploy almost any kind of Java/J2EE application, and it supports the following file format.

WAR – Web application archive SAR – Service archive JAR – Java Archive EAR – Enterprise application archive

14. How can you deploy an application?

There are three possible ways to deploy an application in JBoss application server.

Admin Console – you can deploy the necessary application files through the administration console. Auto-deploy – leverage file system deployment scanner to auto-deploy files from the deployments folder. Automation – use automation tool/ant/scripting to deploy an application.

15. What marker file type is required to instruct JBoss to deploy?

.dodeploy file suffix is needed for JBoss to deploy or redeploy an application. Ex:

16. What are the important types available for marker file deployment?

.dodeploy – instruct to deploy .deployed – indicate the file is deployed .pending – deployment is still pending .undeployed – confirmation that application is undeployed .failed – deployment is failed for some reason .skipdeploy – instruct JBoss to ignore the files for auto-deployment

17. What does mgmt-user.properties contain?

All admin console users and passwords (encrypted) are stored in mgmt.-user.properties file. I hope the above gives you an idea of what type of questions being asked in the Interview and wish you good luck.