Creating a simple servlet application

Let's take a look at how to create a simple servlet application using Maven and the Kotlin runtime. Follow these steps:

  1.  Click on File | New | Project.
  2. In the New Project window, select Maven and enable Create from archetype.
  1. Select org.apache.maven.archetypes:maven-archetype-webapp as the archetype and click on Next:

  1. Enter the GroupId, ArtifactId, and Version for the Maven project and click on Next.
  2. Verify the project's name and click on Finish. This has created a maven web app project with the following structure:

Let's write a simple login form and a welcome page.

We need to include the following ...

Get Kotlin for Enterprise Applications using Java EE now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.