Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
..
Failed to load latest commit information.
src/main
README.md
pom.xml

README.md

2lcache:

Author: Francesco Marchioni Level: Intermediate Technologies: EJB, CDI, JPS, JSF Summary: Basic example that shows how to use the 2nd Level cache with WildFly 10 Target Product: WildFly 10

Tutorial description

A Complete tutorial about the Second Level Cache is available at the following URL: http://www.mastertheboss.com/jboss-frameworks/hibernate-jpa/hibernate-cache/using-hibernate-second-level-cache-with-jboss-as-5-6-7.

System requirements

All you need to build this project is Java 6.0 (Java SDK 1.6) or better, Maven 3.0 or better.

The application this project produces is designed to be run on WildFly 10.

Configure Maven

If you have not yet done so, you must Configure Maven before testing the quickstarts.

Start WildFly

  1. Open a command line and navigate to the root of the JBoss server directory.
  2. The following shows the command line to start the server with the web profile:

    For Linux:   JBOSS_HOME/bin/standalone.sh
    For Windows: JBOSS_HOME\bin\standalone.bat
    

Build and Deploy the application

NOTE: The following build command assumes you have configured your Maven user settings. If you have not, you must include Maven setting arguments on the command line. See Build and Deploy the Quickstarts for complete instructions and additional options.

  1. Make sure you have started the JBoss Server as described above.
  2. Open a command line and navigate to the root directory of this quickstart.
  3. Type this command to build and deploy the archive:

    mvn clean package wildfly:deploy
    
  4. This will deploy target/2levelcache.war to the running instance of the server.

Access the application

The application will be running at the following URL: http://localhost:8080/javaee6example.

Undeploy the Archive

  1. Make sure you have started the JBoss Server as described above.
  2. Open a command line and navigate to the root directory of this quickstart.
  3. When you are finished testing, type this command to undeploy the archive:

    mvn wildfly:undeploy