开发者

Streaming with Spring Framework

开发者 https://www.devze.com 2023-03-14 08:09 出处:网络
I have developed a client (Eclipse) server (Spring Framework on Tomcat) application using Spring Remoting over HttpInvoker.

I have developed a client (Eclipse) server (Spring Framework on Tomcat) application using Spring Remoting over HttpInvoker.

Some usecases need to transfer large files (>150MB) from server to client. Since we're on a 32Bit system on client side, I always get a Java heap size problem (althoough I set the Xmx to 1014 MB - but files could even be bigger).

My question is: Is there any way to do streaming over HttpIn开发者_StackOverflowvoker or something else to solve this problem?


see rmiio : RMIIO

RMIIO is a library which makes it as simple as possible to stream large amounts of data using the RMI framework (or any RPC framework for that matter). Who needs this? Well, if you have ever needed to send a file from an RMI client to an RMI server, you have faced this problem. And, if you did manage to implement a basic solution, it probably threw an OutOfMemoryError the first time someone tried to send a 2GB file. Due to the design of RMI, this common and deceptively simple problem is actually quite difficult to solve in an efficient and robust manner.

you can use it standalone or over any other rmi framework such as httpInvoker.

0

精彩评论

暂无评论...
验证码 换一张
取 消