Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4079328
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T17:47:16+00:00 2026-05-20T17:47:16+00:00

I am trying to follow the first part of jersey tutorial using Grizzly as

  • 0

I am trying to follow the first part of jersey tutorial using Grizzly as the web container. I am just at the “Hello World!” part and trying to run my code. This is the main of the web services that I am trying to deploy.

    public class Main {

    public static void main(String [] args) throws IOException {
        final String baseUri = "http://localhost:9998";
        final Map<String, String > initParams = new HashMap<String, String>();


        initParams.put("com.sun.jersey.config.property.packages", "com.sun.ws.rest.samples.helloworld.resources");

        System.out.println("Starting grizzly");
        SelectorThread threadSelector = GrizzlyWebContainerFactory.create(baseUri,initParams);

        System.out.println(String.format("Jersey app started with WADL available at %sapplication.wadl Try out %shelloworld. Hit enter to stop it...", baseUri, baseUri));

        System.in.read();
        threadSelector.stopEndpoint();
        System.exit(0);
    }
}

When I run this, I always get

Exception in thread "main" java.lang.IllegalArgumentException: The URI path, of the URI http://localhost:9998, must be present
at com.sun.jersey.api.container.grizzly.GrizzlyWebContainerFactory.create(GrizzlyWebContainerFactory.java:236)
at com.sun.jersey.api.container.grizzly.GrizzlyWebContainerFactory.create(GrizzlyWebContainerFactory.java:138)
at com.sun.jersey.api.container.grizzly.GrizzlyWebContainerFactory.create(GrizzlyWebContainerFactory.java:105)
at Main.main(Main.java:29)

Does anyone know what is happening? I have made sure that my packages are all correct. I do not know how to configure grizzly and just trying to learn how to use Jersey

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T17:47:17+00:00Added an answer on May 20, 2026 at 5:47 pm
     final String baseUri = "http://localhost:9998/";
    

    Note the / on the end; you’re missing it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Im trying to follow a tutorial that is using SBJsonParser to get twitter feeds,
First some background: I'm working on an application and I'm trying to follow MVVM
i'm moving my first steps into Django and i'm tryin' to follow the tutorial
I'm trying to follow the steps to compile some C code to import into
I'm trying to follow a tutorial on NodeJS. I don't think I missed anything
Well, I'm trying to follow the tutorial from http://rapidandroid.org/wiki/Graphing . But I found a
first poster here. Trying to use sed to find and replace a word. Code
I am currently trying to seed some test data using the following code: #
I am trying to get the first part of a Guid Field with the
I'm trying to follow the ruby on rails tutorial and impliment the Integration Testing.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.