-1

I am trying to create a restful webservice. Followed this tutorial - https://www.jetbrains.com/help/idea/creating-and-running-your-first-restful-web-service-on-glassfish-application-server.html

This project has 2 files -

  1. a resource class HelloWorld.java.
  2. a configuration class MyApplication.java.

I had IntelliJ generate a WAR file as an artifact. I added a MANIFEST.MF file to the WAR file. Contest of this file -

Manifest-Version: 1.0
Main-Class: HelloWorld

Question - Should the Main-Class be HelloWorld or MyApplication?

Quest Monger
  • 8,252
  • 11
  • 37
  • 43

1 Answers1

2

Neither. A WAR file is essentially a collection of Servlets, invoked by the container. No main class required.

user207421
  • 305,947
  • 44
  • 307
  • 483