javafile-uploadstruts2limitupload-max-filesize

How to fix SizeLimitExceededException: the request was rejected because its size (337867) exceeds the configured maximum (200) in Struts 2?


How to handle custom inteceptors execptions in Struts 2?

org.apache.commons.fileupload.FileUploadBase$SizeLimitExceededException: the request was rejected because its size (337867) exceeds the configured maximum (200)


Solution

  • <global-exception-mappings>
      <exception-mapping exception="java.lang.NullPointerException" result="npe"/>
    </global-exception-mappings>