users@jersey.java.net

[Jersey] 404 with Jersey with Maven IntelliJ and Tomcat

From: Anurag Jain <anuragjainfzd_at_gmail.com>
Date: Tue, 10 Jan 2017 00:05:05 +0530

Hi all,

This is my first post.

I'm not a java guy but I've to write some REST APIs and I wanted to
try out Jersey JAX-RS library as per the recommendation from my peers.
I've been able to configure a non-maven project in Eclipse and I'm
able to invoke an example REST API.

But I'm unable to do the same with IntelliJ idea ultimate. I'm trying
to configure a maven project with Jersey and Tomcat in IntelliJ Idea
Ultimate.

Below are the steps I followed.

1: Created a maven project with the archetype groupId -
org.glassfish.jersey.archetypes and artifactId -
jersey-quickstart-webapp with version 2.5. Maven downloads
2: Created tomcat configuration. During build Maven downloads the
necessary libs and on running I see the jersey JARs being placed
inside target folder's ..\target\{Projectname}\WEB-INF\lib

Yet I get 404 not found while connecting with the rest API URL. I'm
unsure what might the issue be and need some assistance. I'm attaching
my pom.xml, web.xml and other necessary files here below.

Regards,
-- 
Anurag Jain