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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T19:55:15+00:00 2026-06-01T19:55:15+00:00

I am trying to use spring mvc to build web app. Before I was

  • 0

I am trying to use spring mvc to build web app.
Before I was using

<bean id="jspViewResolver" class="org.springframework.web.servlet.view.InternalResourceViewResolver">
    <property name="viewClass" value="org.springframework.web.servlet.view.JstlView"/>
    <property name="prefix" value="/WEB-INF/jsp/"/>
    <property name="suffix" value=".jsp"/>
</bean>

But now, because i need to upload files also, i have to change to

<bean id="multipartResolver" class="org.springframework.web.multipart.commons.CommonsMultipartResolver">
    <property name="maxUploadSize" value="1000000"/>
</bean>

This multipartResolver doesn’t have attributes like prefix.
If I need to use multipartResolver, where can I set the prefix and suffix?

Please give me suggestions, thank you!!!

  • 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-06-01T19:55:17+00:00Added an answer on June 1, 2026 at 7:55 pm

    The properties “prefix” and “suffix” are properties specific for the InternalResourceViewResolver. There are no properties on the CommonsMultipartResolver for this.

    You need those properties to advise the InternalResourceViewResolver to tell it where to find jsp files (for example, if you return a string of “foo”, it will resolve with the “{prefix}foo{suffix}”, which is “/WEB-INF/jsp/foo.jsp”).

    There is no need to define a prefix and suffix for the CommonsMultipartResolver. Per the comments in source code, the properties that CommonsMultipartResolver can use are “maxUploadSize”, “maxInMemorySize”, and “defaultEncoding”.

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

Sidebar

Related Questions

I am trying to convert my app written in Spring MVC 2.5 to use
I am new to spring. I am trying to use spring mvc to build
I'm trying to use a generic class as a Spring form backing bean, but
I have a Spring MVC application trying to use a rich domain model, with
I am trying to use Spring AOP with Spring MVC Controller. I have 3
I'm using Spring MVC, and I was wondering if it's possible to use methods
I'm trying to create a multiaction web controller using Spring annotations. This controller will
I am trying to run two Servlet-class in a single web.xml but its not
I´m new in spring-mvc. So, i´m trying to use RESTFull urls ( i think
We are trying to build some RESTful services with Spring MVC. We will be

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.