Jul 16th, 2012, 12:01 AM
portletMultipartResolver: read timeout exception
We have a webflow portlet application where a user has to upload a few files. The form contains a dropdown where the user selects the type of file (photo, birth certificate, other) and a file upload input to attach the file. Once the attach button is pressed, the file is uploaded, there's a validation bean that checks that the file extension is correct (photo = jpg, birth cert = pdf, etc). Upon a successful validation, file object is added to a documents arraylist and displayed in a table. This cycle is repeated until the user attaches all documents and presses "next".
Example: (my apologies for the Spanish)
It works pretty well for the most part. Except at times the internet connection goes bad at the client's site and portletMultipartResolver will throw read timeout exceptions left and right.
We can't recreate it from our office and only one person in our QA team has an internet connection that's bad enough at home to make it happen. So, it is a pain to test and recreate.
I tried using a global transition to catch the exception, but the portletMultipartResolver resides outside the flow context, so the exception is not caught.
I was wondering what are my options to either catch the exception or, alternatively, provide other means to upload the file?