Re: [Simpleweb-Support] Serving large file to a lot of clients
Brought to you by:
niallg
From: Niall G. <gal...@ya...> - 2010-11-25 11:13:52
|
Hi, In this scenario the clients are closing the sockets at their end. Ill take a look at the test, but I am pretty sure this is what is happening. Do a netstat to confirm. Niall --- On Wed, 24/11/10, Christophe Roudet <cr...@ac...> wrote: > From: Christophe Roudet <cr...@ac...> > Subject: [Simpleweb-Support] Serving large file to a lot of clients > To: sim...@li... > Received: Wednesday, 24 November, 2010, 7:49 AM > Hello, > > I am testing simpleweb to serve large file to a lot of > clients. > I have set up a test server that send arbitrary large data. > After a while I got exceptions: > > org.simpleframework.http.core.ProducerException: Error > sending response > at > org.simpleframework.http.core.FixedProducer.produce(FixedProducer.java:156) > at > org.simpleframework.http.core.Transfer.write(Transfer.java:184) > at > org.simpleframework.http.core.Transfer.write(Transfer.java:167) > at > org.simpleframework.http.core.Accumulator.write(Accumulator.java:219) > at > org.simpleframework.http.core.Accumulator.write(Accumulator.java:190) > at > org.simpleframework.FakeFileResource.run(FakeFileResource.java:66) > at > java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown > Source) > at > java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown > Source) > at java.lang.Thread.run(Unknown > Source) > Caused by: java.nio.channels.ClosedChannelException > at > sun.nio.ch.SocketChannelImpl.ensureWriteOpen(Unknown > Source) > at > sun.nio.ch.SocketChannelImpl.write(Unknown Source) > at > org.simpleframework.transport.Appender.write(Appender.java:343) > at > org.simpleframework.transport.Appender.write(Appender.java:322) > at > org.simpleframework.transport.Appender.write(Appender.java:297) > at > org.simpleframework.transport.Segment.write(Segment.java:206) > > Is there something I do wrong? > > I have attached the source, ServerTest is the server main > class, and ClientTest the client main class. > I have tested it on windows xp with java version "1.6.0_22" > and simple-4.1.21.jar. > > Thanks > > -- Christophe Roudet > > > -----Inline Attachment Follows----- > > ------------------------------------------------------------------------------ > Increase Visibility of Your 3D Game App & Earn a Chance > To Win $500! > Tap into the largest installed PC base & get more eyes > on your game by > optimizing for Intel(R) Graphics Technology. Get started > today with the > Intel(R) Software Partner Program. Five $500 cash prizes > are up for grabs. > http://p.sf.net/sfu/intelisp-dev2dev > -----Inline Attachment Follows----- > > _______________________________________________ > Simpleweb-Support mailing list > Sim...@li... > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > |