[jboss-user] [EJB 3.0] - Re: How to deal with huge uploaded file in JBoss
jochen.reinhardt
do-not-reply at jboss.com
Wed May 13 14:37:13 EDT 2009
Hi and thanks for your responeses,
First of all, it works ;-) Just by saving the file in the
I found several other problems in the app:
- I was using a wrong version of tomahawk
- Tomahawk seems to ignore setting for file size thresholds. This resulted in a FileUploadHtmlComponent caching 100 MB in memory. Have to submit a bug report for this...
- I had to use a hardly documented attribute in the file upload tag (found in tomahawk's source code).
I don't like the idea of splitting the files into chunks. That's just because I am a bit lazy and I want to keep things as clean and as simple as possible. And with junking I do not solve my general problem. That is using a JMS Message to process the file asynchronously. I would not want to send a message for each chunk. That would not be fast enough. And I would end up having JMS dumping the chunks to the database.
Next time I start a new application I will consider using struts. But for this project, I'm already in to deep using myFaces. And I've never heard about BlobStreams. Is that part of some JDBC spec? But it seems to make good sense - as I won't be able to hold that much data in one row of a result set.
For now, I'll keep things as they are - I like using the simple FileInputStreams, consuming only minimum memory. Buffering is done by some sick CSV-library. I thought I had to die as I took a look into the sources... but as long as it works...
Any hint about standards violation?
Accessing a file from disk in MessageListner?
Passing a FileInputStream to EJB3 stateless session bean method call?
I guess I just don't care - as long as it works.
Thanks again for your hints - I had not suspected tomahawk to be the major problem in that case. So after all, this post seems to be somewhat off-topic here...
So long,
Jochen
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4230932#4230932
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4230932
More information about the jboss-user
mailing list