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 6091697
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T12:21:28+00:00 2026-05-23T12:21:28+00:00

In Spring 3 MVC, I have a controller that I call SettingsController, and it

  • 0

In Spring 3 MVC, I have a controller that I call SettingsController, and it has methods such as displayUsers() for displaying a list of users, saveUser(), and deleteUser(). SettingsContoller also controls roles and other things.

I’d love to be able to use URL routing such that /settings/users would call displayUsers(), /settings/users/save would call saveUser(), and /settings/users/delete would call deleteUser().

My code is below, and I’m getting the error message that follows the code. What am I doing wrong? Thanks!

@Controller
@RequestMapping("/settings")
public class SettingsController {

    @Transactional
    @RequestMapping(value = {"/users/save"}, method = {RequestMethod.POST})
    public ModelAndView saveUser(details removed){
        //details removed
    }

    @RequestMapping(value = {"/users/delete"}, method = {RequestMethod.POST})
    public ModelAndView deleteUser(details removed){
       //details removed
    }

    @RequestMapping(value = {"/users"}, method = RequestMethod.GET)
    public ModelAndView settingsUsers(details removed){
      //details removed
    }

}

Error:

HTTP ERROR: 500

Could not resolve view with name 'settings/users/delete' in servlet with name 'spring'
RequestURI=/das-portal/srv/settings/users/delete

Caused by:

javax.servlet.ServletException: Could not resolve view with name 'settings/users/delete' in servlet with name 'spring'
    at        org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1029)
...
  • 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-23T12:21:28+00:00Added an answer on May 23, 2026 at 12:21 pm

    It looks to me like you’ve set up your controller correctly. As you pointed out, the problem might be in how Spring parses annotations upon start up.

    How did you configure Sprint to parse annotations such as @Controller? Do you explicitly set up any sort of HandlerMapping? If you use <context:component-scan>, then it registers a DefaultAnnotationHandlerMapping for you.

    The good news is that you can chain multiple handler mapping classes together. The DispatcherServlet will check each one in the order that you specify via the order property of the handler mapping beans (in other words, use the order property to indicate the precedence of your handlers).

    So, throw <bean class="org.springframework.web.servlet.mvc.annotation.DefaultAnnotationHandlerMapping"/> into your configuration and set its order property as appropriate.

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

Sidebar

Related Questions

I have a controller (Spring-MVC) that generates a PDF report on a get request.
I have a MVC application which has a Controller that has a recursive method
I have a Spring MVC app that uses JSP to render pages. Spring has
I have a website that uses JSP as its view technology (and Spring MVC
I have a controller that is being called twice from an ActionLink call. My
I have controller method in my MVC application that I am calling using the
I have a Spring MVC Controller class (bean): @Controller @RequestMapping(/index.jsp) public class EjbCaller {
I have a controller action in ASP.NET MVC that handles uploaded files. However, it
I have looked at Spring MVC a few times briefly, and got the basic
I have a Spring MVC application trying to use a rich domain model, with

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.