This project was generated by the Liberty app accelerator
The Liberty App Accelerator provides a starting point for creating applications running on WebSphere Liberty.
- Gradle
- Java 8: Any compliant JVM should work.
- Java 8 JDK from Oracle
- Java 8 JDK from IBM (AIX, Linux, z/OS, IBM i), or Download a Liberty server package that contains the IBM JDK (Windows, Linux)
The application is configured to provide various technologies and features. These capabilities are provided through dependencies in the build.gradle file and Liberty features enabled in the server config file found in src/main/liberty/config/server.xml
.
The context root is set in the src/main/webapp/WEB-INF/ibm-web-ext.xml
file. The ports are set in the build.gradle file.
-
Persistence : For the complete feature documentation, see the jpa-2.1 feature description in IBM Knowledge Center.
-
REST : Inside the project there is a application.rest package containing the
LibertyRestEndpoint
class. This adds a REST endpoint which you can access athttp://localhost:9080/<context>/rest
. There is also a test class namedit.rest.LibertyRestEndpointTest
that will test the REST endpoint to ensure it is working. For the complete feature documentation, see the jaxrs-2.0 feature description in IBM Knowledge Center. -
Servlet : Inside the project there is a application.servlet package containing the
LibertyServlet
class. This adds a servlet with an endpoint which you can access athttp://localhost:9080/<context>/servlet
. There is also a test namedit.servlet.LibertyServletTest
that will test the servlet's endpoint to ensure it is working. For the complete feature documentation, see the servlet-3.1 feature description in IBM Knowledge Center. -
Websockets : For the complete feature documentation, see the websocket-1.1 feature description in IBM Knowledge Center.
To build and run the application:
gradle build
gradle libertyStart
- To stop the application run
gradle libertyStop
The context root is set in the src/main/webapp/WEB-INF/ibm-web-ext.xml
file. The ports are set in the build.gradle file.
This project was generated using:
- generator-java v1.9.1
- java-common v2.0.6
- generator-liberty v5.1.2