simpleweb-support Mailing List for Simple (Page 20)
Brought to you by:
niallg
You can subscribe to this list here.
2004 |
Jan
(1) |
Feb
(4) |
Mar
(2) |
Apr
(14) |
May
(22) |
Jun
(15) |
Jul
(9) |
Aug
(2) |
Sep
(7) |
Oct
(4) |
Nov
(2) |
Dec
(12) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2005 |
Jan
(7) |
Feb
(16) |
Mar
(17) |
Apr
|
May
(12) |
Jun
(4) |
Jul
(22) |
Aug
(50) |
Sep
(8) |
Oct
(23) |
Nov
(9) |
Dec
(50) |
2006 |
Jan
(6) |
Feb
(7) |
Mar
(8) |
Apr
(3) |
May
(13) |
Jun
(4) |
Jul
(2) |
Aug
|
Sep
(1) |
Oct
|
Nov
(6) |
Dec
(7) |
2007 |
Jan
(11) |
Feb
(3) |
Mar
(17) |
Apr
(21) |
May
(9) |
Jun
(4) |
Jul
(6) |
Aug
(1) |
Sep
|
Oct
(8) |
Nov
(14) |
Dec
(3) |
2008 |
Jan
(3) |
Feb
|
Mar
|
Apr
(5) |
May
|
Jun
|
Jul
(4) |
Aug
(4) |
Sep
(15) |
Oct
(9) |
Nov
(6) |
Dec
(2) |
2009 |
Jan
(29) |
Feb
(2) |
Mar
(8) |
Apr
(14) |
May
(4) |
Jun
(13) |
Jul
(5) |
Aug
|
Sep
|
Oct
(4) |
Nov
(3) |
Dec
(7) |
2010 |
Jan
|
Feb
(2) |
Mar
(61) |
Apr
(9) |
May
(10) |
Jun
(9) |
Jul
(10) |
Aug
(7) |
Sep
(15) |
Oct
(5) |
Nov
(2) |
Dec
(3) |
2011 |
Jan
(11) |
Feb
|
Mar
|
Apr
(2) |
May
|
Jun
|
Jul
(3) |
Aug
|
Sep
(4) |
Oct
|
Nov
(6) |
Dec
(9) |
2012 |
Jan
|
Feb
(1) |
Mar
(2) |
Apr
(3) |
May
(2) |
Jun
|
Jul
(17) |
Aug
|
Sep
|
Oct
|
Nov
(10) |
Dec
(5) |
2013 |
Jan
(2) |
Feb
(4) |
Mar
|
Apr
(12) |
May
|
Jun
(5) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(3) |
Dec
(1) |
2014 |
Jan
|
Feb
(2) |
Mar
(6) |
Apr
|
May
|
Jun
(20) |
Jul
(12) |
Aug
(4) |
Sep
(3) |
Oct
(5) |
Nov
|
Dec
|
2015 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2016 |
Jan
(2) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
2017 |
Jan
|
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Niall G. <gal...@ya...> - 2007-04-18 13:02:51
|
Hi Hugo, Well there is support, but not for standard JSP. A JSP like syntax is supported though. This can be found in the simple.page package. Niall ----- Original Message ---- From: Hugo Weber <ug...@li...> To: sim...@li... Sent: Tuesday, April 17, 2007 1:12:32 PM Subject: [Simpleweb-Support] JSP support and powered by logo Niall, does simple has JSP support? I saw some JSP's on the demo package but all they do is a "insert" statement that works as an include. I'm also looking for a "Powered by Simple Framework" picture if you have one. By the way, that mapper.xml old syntax "<resolve match="/*" name="testFile1" type="simple.test.TestFile1"/>" is on the doc/example dir on the simple-core 3.1.3 package. Sorry about the forwarded e-mail I sent before, I accidentally hit <return>. Thank you, Hugo. ----- Original Message ----- From: "Niall Gallagher" <gal...@ya...> To: "Simple support and user issues" <sim...@li...> Subject: Re: [Simpleweb-Support] mapper.xml not working Date: Tue, 17 Apr 2007 02:27:08 -0700 (PDT) Hi, Yes, the tutorial is slightly out of date in this respect. It looks like your mapper.xml file is not correctly formatted. It should look like <mapper> <lookup> <service name="name" type="package.MyClass"/> </lookup> <resolve> <match name="name" path="/*"/> </resolve> </mapper> Niall = Search for products and services at: http://search.mail.com -- Powered by Outblaze ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Simpleweb-Support mailing list Sim...@li... https://lists.sourceforge.net/lists/listinfo/simpleweb-support __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com |
From: Hugo W. <ug...@li...> - 2007-04-17 12:13:26
|
Niall, does simple has JSP support? I saw some JSP's on the demo package but all they do is a "insert" statemen= t that works as an include. I'm also looking for a "Powered by Simple Framework" picture if you have on= e. By the way, that mapper.xml old syntax "<resolve match=3D"/*" name=3D"testF= ile1" type=3D"simple.test.TestFile1"/>" is on the doc/example dir on the si= mple-core 3.1.3 package. Sorry about the forwarded e-mail I sent before, I accidentally hit <return>. Thank you, Hugo. ----- Original Message ----- From: "Niall Gallagher" <gal...@ya...> To: "Simple support and user issues" <sim...@li...urceforge.n= et> Subject: Re: [Simpleweb-Support] mapper.xml not working Date: Tue, 17 Apr 2007 02:27:08 -0700 (PDT) Hi, Yes, the tutorial is slightly out of date in this respect. It looks=20 like your mapper.xml file is not correctly formatted. It should=20 look like <mapper> <lookup> <service name=3D"name" type=3D"package.MyClass"/> </lookup> <resolve> <match name=3D"name" path=3D"/*"/> </resolve> </mapper> Niall =3D Search for products and services at:=20 http://search.mail.com --=20 Powered by Outblaze |
From: Hugo W. <ug...@li...> - 2007-04-17 12:05:47
|
----- Original Message ----- From: "Niall Gallagher" <gal...@ya...> To: "Simple support and user issues" <sim...@li...urceforge.n= et> Subject: Re: [Simpleweb-Support] mapper.xml not working Date: Tue, 17 Apr 2007 02:27:08 -0700 (PDT) Hi, Yes, the tutorial is slightly out of date in this respect. It looks=20 like your mapper.xml file is not correctly formatted. It should=20 look like <mapper> <lookup> <service name=3D"name" type=3D"package.MyClass"/> </lookup> <resolve> <match name=3D"name" path=3D"/*"/> </resolve> </mapper> Niall ----- Original Message ---- From: Hugo Weber <ug...@li...> To: sim...@li... Sent: Tuesday, April 17, 2007 1:18:00 AM Subject: [Simpleweb-Support] mapper.xml not working I'm doing the tutorial samples for the HelloService and it only=20 works if I add the following lines to the DemoServer.java: engine.load("default", "HelloService"); engine.link("*", "default"); Looks like stuff on mapper.xml is bean ignored. The mapper.xml is=20 shown bellow. What's Wrong? The steps I made... I Copied DemoServer and DemoHandler sources from the tutorial=20 "getting started - r2" and HelloService from the tutorial "Simplest=20 possible Service". They compile but don't work. I found out the following error is due to a missing mapper.xml file. simple.http.serve.LocateException: File not found at simple.http.serve.FileLocator.getLocation(FileLocator.java:138) at simple.http.serve.FileLocator.getLocation(FileLocator.java:112) at simple.http.serve.FileLocator.getFile(FileLocator.java:157) at simple.http.load.PatternResolver.load(PatternResolver.java:146) at simple.http.load.PatternResolver.load(PatternResolver.java:130) at simple.http.load.PatternResolver.init(PatternResolver.java:106) at simple.http.load.PatternResolver.<init>(PatternResolver.java:91) at simple.http.load.PatternMapper.<init>(PatternMapper.java:106) at simple.http.load.PatternMapper.<init>(PatternMapper.java:92) at simple.http.load.MapperFactory.getInstance(MapperFactory.java:73) at simple.http.load.MapperEngine.<init>(MapperEngine.java:243) at simple.http.load.MapperEngine.<init>(MapperEngine.java:222) at simple.http.load.MapperEngine.<init>(MapperEngine.java:176) at simple.http.load.MapperEngine.<init>(MapperEngine.java:150) at simple.http.load.MapperEngine.<init>(MapperEngine.java:105) at simple.http.load.MapperEngine.<init>(MapperEngine.java:86) at DemoServer.main(DemoServer.java:12) So I place this mapper.xml file and the error above is solved,=20 however, HelloService still not working. <?xml version=3D"1.0"?> <!DOCTYPE mapper SYSTEM "http://www.simpleframework.org/dtd/mapper.dtd";> <mapper> <resolve match=3D"/*" name=3D"default" type=3D"HelloService"/> </mapper> Searching on the simple site I found this link=20 http://kasparov.skife.org/blog/2004/04/23 named "It's all so simple" That's where I got the lines engine.load("default", "HelloService"); engine.link("*", "default"); Why it only works with the load and link methods and not what is on=20 the mapper.xml file? Thank you, Hugo. =3D -- Powered by Outblaze ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Simpleweb-Support mailing list Sim...@li... https://lists.sourceforge.net/lists/listinfo/simpleweb-support __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Simpleweb-Support mailing list Sim...@li... https://lists.sourceforge.net/lists/listinfo/simpleweb-support =3D Search for products and services at:=20 http://search.mail.com --=20 Powered by Outblaze |
From: Niall G. <gal...@ya...> - 2007-04-17 09:27:18
|
Hi, Yes, the tutorial is slightly out of date in this respect. It looks like your mapper.xml file is not correctly formatted. It should look like <mapper> <lookup> <service name="name" type="package.MyClass"/> </lookup> <resolve> <match name="name" path="/*"/> </resolve> </mapper> Niall ----- Original Message ---- From: Hugo Weber <ug...@li...> To: sim...@li... Sent: Tuesday, April 17, 2007 1:18:00 AM Subject: [Simpleweb-Support] mapper.xml not working I'm doing the tutorial samples for the HelloService and it only works if I add the following lines to the DemoServer.java: engine.load("default", "HelloService"); engine.link("*", "default"); Looks like stuff on mapper.xml is bean ignored. The mapper.xml is shown bellow. What's Wrong? The steps I made... I Copied DemoServer and DemoHandler sources from the tutorial "getting started - r2" and HelloService from the tutorial "Simplest possible Service". They compile but don't work. I found out the following error is due to a missing mapper.xml file. simple.http.serve.LocateException: File not found at simple.http.serve.FileLocator.getLocation(FileLocator.java:138) at simple.http.serve.FileLocator.getLocation(FileLocator.java:112) at simple.http.serve.FileLocator.getFile(FileLocator.java:157) at simple.http.load.PatternResolver.load(PatternResolver.java:146) at simple.http.load.PatternResolver.load(PatternResolver.java:130) at simple.http.load.PatternResolver.init(PatternResolver.java:106) at simple.http.load.PatternResolver.<init>(PatternResolver.java:91) at simple.http.load.PatternMapper.<init>(PatternMapper.java:106) at simple.http.load.PatternMapper.<init>(PatternMapper.java:92) at simple.http.load.MapperFactory.getInstance(MapperFactory.java:73) at simple.http.load.MapperEngine.<init>(MapperEngine.java:243) at simple.http.load.MapperEngine.<init>(MapperEngine.java:222) at simple.http.load.MapperEngine.<init>(MapperEngine.java:176) at simple.http.load.MapperEngine.<init>(MapperEngine.java:150) at simple.http.load.MapperEngine.<init>(MapperEngine.java:105) at simple.http.load.MapperEngine.<init>(MapperEngine.java:86) at DemoServer.main(DemoServer.java:12) So I place this mapper.xml file and the error above is solved, however, HelloService still not working. <?xml version="1.0"?> <!DOCTYPE mapper SYSTEM "http://www.simpleframework.org/dtd/mapper.dtd";> <mapper> <resolve match="/*" name="default" type="HelloService"/> </mapper> Searching on the simple site I found this link http://kasparov.skife.org/blog/2004/04/23 named "It's all so simple" That's where I got the lines engine.load("default", "HelloService"); engine.link("*", "default"); Why it only works with the load and link methods and not what is on the mapper.xml file? Thank you, Hugo. = -- Powered by Outblaze ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Simpleweb-Support mailing list Sim...@li... https://lists.sourceforge.net/lists/listinfo/simpleweb-support __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com |
From: Hugo W. <ug...@li...> - 2007-04-17 00:18:13
|
I'm doing the tutorial samples for the HelloService and it only works if I = add the following lines to the DemoServer.java: engine.load("default", "HelloService"); engine.link("*", "default"); Looks like stuff on mapper.xml is bean ignored. The mapper.xml is shown bel= low.=20 What's Wrong? The steps I made... I Copied DemoServer and DemoHandler sources from the tutorial "getting star= ted - r2" and HelloService from the tutorial "Simplest possible Service". T= hey compile but don't work.=20 I found out the following error is due to a missing mapper.xml file. simple.http.serve.LocateException: File not found at simple.http.serve.FileLocator.getLocation(FileLocator.java:138) at simple.http.serve.FileLocator.getLocation(FileLocator.java:112) at simple.http.serve.FileLocator.getFile(FileLocator.java:157) at simple.http.load.PatternResolver.load(PatternResolver.java:146) at simple.http.load.PatternResolver.load(PatternResolver.java:130) at simple.http.load.PatternResolver.init(PatternResolver.java:106) at simple.http.load.PatternResolver.<init>(PatternResolver.java:91) at simple.http.load.PatternMapper.<init>(PatternMapper.java:106) at simple.http.load.PatternMapper.<init>(PatternMapper.java:92) at simple.http.load.MapperFactory.getInstance(MapperFactory.java:73) at simple.http.load.MapperEngine.<init>(MapperEngine.java:243) at simple.http.load.MapperEngine.<init>(MapperEngine.java:222) at simple.http.load.MapperEngine.<init>(MapperEngine.java:176) at simple.http.load.MapperEngine.<init>(MapperEngine.java:150) at simple.http.load.MapperEngine.<init>(MapperEngine.java:105) at simple.http.load.MapperEngine.<init>(MapperEngine.java:86) at DemoServer.main(DemoServer.java:12) So I place this mapper.xml file and the error above is solved, however, Hel= loService still not working. <?xml version=3D"1.0"?> <!DOCTYPE mapper SYSTEM "http://www.simpleframework.org/dtd/mapper.dtd"> <mapper> <resolve match=3D"/*" name=3D"default" type=3D"HelloService"/> </mapper> Searching on the simple site I found this link http://kasparov.skife.org/bl= og/2004/04/23 named "It's all so simple" That's where I got the lines engine.load("default", "HelloService"); engine.link("*", "default"); Why it only works with the load and link methods and not what is on the map= per.xml file? Thank you, Hugo. =3D --=20 Powered by Outblaze |
From: R P. <pat...@gm...> - 2007-04-16 21:12:21
|
Hi Niall, I've implemented some services loaded by a sub-class of the LoaderEngine. Now I would like to add a FileEngine in order to provide access to some file resources I'll have available on the server. I only saw the DomainEngine to deal with both of the 2 engines, but seems not exactly fit in my case. What do you recommend in such a case? Thank you very much, Pat |
From: <sth...@go...> - 2007-04-11 08:03:15
|
Hi Pat, You seem to be using this facility to discard objects gracefully while the JVM is shutting down? But I wonder, if this still works, even if I wouldn't want shut down the whole JVM but just my Simple server? -Stefan 2007/3/29, R Pat <pat...@gm...>: > Sent again with a correct message's obejct (sorry)... > > Hi Stephan, > > Something that works perfectly for me: > > public class MyServer implements Runnable { > > public void run() { > System.err.println ("Server is shutting down..."); > > // Close all (simple's connection, others)... > ........ > > // This finalize all simpleweb's threads > Runtime.getRuntime().runFinalization(); > } > > public final static void shutdown() { > // Shutdown your Simple server and exit! > Runtime.getRuntime().exit(0); > } > > protected MyServer() { > Thread shutdownHook = new Thread(this, "shutdown-hook"); > > Runtime.getRuntime().addShutdownHook(shutdownHook); > } > } > > Regards, > Pat > |
From: <sth...@go...> - 2007-04-06 14:05:15
|
2007/4/6, Niall Gallagher <gal...@ya...>: > Hi, > > Yes the signalling framework will be included in the next release. Excellent! > Quite a bit of work has been added for the next release, however I think it will be a couple of months yet before I can completely finish it. > Too bad! Do you see any chance to release an early alpha including those features? What's on your list of features for the next release besides of the singals framework, anyways? That asked - have you ever thought about migrating to maven as build tool or at least to provide a POM - so Simple could be published to Maven's central repository? I'd be happy to help you there in one or the other way. Cheers, Stefan |
From: Niall G. <gal...@ya...> - 2007-04-06 13:42:38
|
Hi,=0A=0AYes the signalling framework will be included in the next release.= Quite a bit of work has been added for the next release, however I think i= t will be a couple of months yet before I can completely finish it.=0A=0ANi= all=0A=0A----- Original Message ----=0AFrom: Stefan H=FCbner <sthuebner@goo= glemail.com>=0ATo: Simple support and user issues <simpleweb-support@lists.= sourceforge.net>=0ASent: Friday, April 6, 2007 6:22:24 AM=0ASubject: Re: [S= impleweb-Support] How to shutdown?=0A=0AHi Niall, thanks for the explanatio= ns.=0A=0A2007/4/6, Niall Gallagher <gal...@ya...>:=0A> Hi Stef= an,=0A>=0A> You can make use of the signal framework by making your threads= Daemon objects. So instead of extending thread or using a thread use a Dae= mon object.=0A=0ASo any custom threads my services would execute should be = Daemons. Ok,=0AI got that.=0A=0AIs this behaviour planned to be incorporate= d into the existing classes=0Amaybe? I.e. will Simple 3.2 provide this shut= down facility for its own=0Acore classes? The current 3.2's sources don't s= eem to do so right now.=0AOr do you prefer custom implementations to make u= se of the=0Ashutdown-mechanism?=0A=0A> This object will recieve a shutdown = signal when the Signaller is asked to shutdown. Also a Module is like the D= aemon, however instead of using it with threads you would use the Module wi= th arbitrary objects that want to listen for a shutdown signal. Using it in= this way the Signaller can send signals to parts of the server that wish t= o shutdown gracefully.=0A=0AE.g. I would make my Resources or Services exte= nd Module or just have=0Athem implement the Shutdown-Interface? That way th= ey will receive a=0Ashutdown()-signal. Ok, that sounds nice.=0A=0A>=0A> Nia= ll Gallagher=0A>=0A> ----- Original Message ----=0A> From: Stefan H=FCbner = <sth...@go...>=0A> To: Simple support and user issues <simplewe= b-s...@li...>=0A> Sent: Wednesday, April 4, 2007 4:28:20= PM=0A> Subject: Re: [Simpleweb-Support] How to shutdown?=0A>=0A> Niall,=0A= >=0A> I had a look at the new signal-framework but couldn't get much out of= =0A> it. Could you be so kind to provide an example of how to make use of= =0A> the new Module-class? I.e. what would I use a Module for?=0A>=0A> And = whats your suggestion for how to shut down a PipelineHandler and=0A> it's P= rocessors?=0A>=0A> My use case is to emulate (implemented as a Simple Resou= rce) some web=0A> services providing backend communication for a component= under unit=0A> test. I want to configure the http services in different wa= ys,=0A> depending on the unit test to be run. To reconfigure I need to be a= ble=0A> to start and stop the service completely.=0A> Is this possible usin= g Simple and it's signal framework?=0A>=0A> Regards,=0A> Stefan=0A>=0A> 200= 7/3/22, Niall Gallagher <gal...@ya...>:=0A> > Hi,=0A> >=0A> > = I have written a signalling framework which will be used in Simple so send = signals to all threads and processes within the server when something happe= ns. For instance a shutdown signal will be distributed to all threads to al= low them to shutdown cleanly. When I get the time to finally release the ne= xt version this will be included it is located at:=0A> >=0A> > https://svn.= sourceforge.net/svnroot/simpleweb/branches/3.2/src/simple/signal/=0A> >=0A>= > Niall Gallagher=0A> >=0A------------------------------------------------= -------------------------=0ATake Surveys. Earn Cash. Influence the Future o= f IT=0AJoin SourceForge.net's Techsay panel and you'll get the chance to sh= are your=0Aopinions on IT & business topics through brief surveys-and earn = cash=0Ahttp://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&C= ID=3DDEVDEV=0A_______________________________________________=0ASimpleweb-S= upport mailing list=0AS...@li...=0Ahttps://lis= ts.sourceforge.net/lists/listinfo/simpleweb-support=0A=0A=0A=0A=0A=0A =0A__= ___________________________________________________________________________= _______=0AIt's here! Your new message! =0AGet new email alerts with the fr= ee Yahoo! Toolbar.=0Ahttp://tools.search.yahoo.com/toolbar/features/mail/ |
From: <sth...@go...> - 2007-04-06 13:22:35
|
SGkgTmlhbGwsIHRoYW5rcyBmb3IgdGhlIGV4cGxhbmF0aW9ucy4KCjIwMDcvNC82LCBOaWFsbCBH YWxsYWdoZXIgPGdhbGxhZ2hlcl9uaWFsbEB5YWhvby5jb20+Ogo+IEhpIFN0ZWZhbiwKPgo+IFlv dSBjYW4gbWFrZSB1c2Ugb2YgdGhlIHNpZ25hbCBmcmFtZXdvcmsgYnkgbWFraW5nIHlvdXIgdGhy ZWFkcyBEYWVtb24gb2JqZWN0cy4gU28gaW5zdGVhZCBvZiBleHRlbmRpbmcgdGhyZWFkIG9yIHVz aW5nIGEgdGhyZWFkIHVzZSBhIERhZW1vbiBvYmplY3QuCgpTbyBhbnkgY3VzdG9tIHRocmVhZHMg bXkgc2VydmljZXMgd291bGQgZXhlY3V0ZSBzaG91bGQgYmUgRGFlbW9ucy4gT2ssCkkgZ290IHRo YXQuCgpJcyB0aGlzIGJlaGF2aW91ciBwbGFubmVkIHRvIGJlIGluY29ycG9yYXRlZCBpbnRvIHRo ZSBleGlzdGluZyBjbGFzc2VzCm1heWJlPyBJLmUuIHdpbGwgU2ltcGxlIDMuMiBwcm92aWRlIHRo aXMgc2h1dGRvd24gZmFjaWxpdHkgZm9yIGl0cyBvd24KY29yZSBjbGFzc2VzPyBUaGUgY3VycmVu dCAzLjIncyBzb3VyY2VzIGRvbid0IHNlZW0gdG8gZG8gc28gcmlnaHQgbm93LgpPciBkbyB5b3Ug cHJlZmVyIGN1c3RvbSBpbXBsZW1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VnYXJkcywK PiBTdGVmYW4KPgo+IDIwMDcvMy8yMiwgTmlhbGwgR2FsbGFnaGVyIDxnYWxsYWdoZXJfbmlhbGxA eWFob28uY29tPjoKPiA+IEhpLAo+ID4KPiA+IEkgaGF2ZSB3cml0dGVuIGEgc2lnbmFsbGluZyBm cmFtZXdvcmsgd2hpY2ggd2lsbCBiZSB1c2VkIGluIFNpbXBsZSBzbyBzZW5kIHNpZ25hbHMgdG8g YWxsIHRocmVhZHMgYW5kIHByb2Nlc3NlcyB3aXRoaW4gdGhlIHNlcnZlciB3aGVuIHNvbWV0aGlu ZyBoYXBwZW5zLiBGb3IgaW5zdGFuY2UgYSBzaHV0ZG93biBzaWduYWwgd2lsbCBiZSBkaXN0cmli dXRlZCB0byBhbGwgdGhyZWFkcyB0byBhbGxvdyB0aGVtIHRvIHNodXRkb3duIGNsZWFubHkuIFdo ZW4gSSBnZXQgdGhlIHRpbWUgdG8gZmluYWxseSByZWxlYXNlIHRoZSBuZXh0IHZlcnNpb24gdGhp cyB3aWxsIGJlIGluY2x1ZGVkIGl0IGlzIGxvY2F0ZWQgYXQ6Cj4gPgo+ID4gaHR0cHM6Ly9zdm4u c291cmNlZm9yZ2UubmV0L3N2bnJvb3Qvc2ltcGxld2ViL2JyYW5jaGVzLzMuMi9zcmMvc2ltcGxl L3NpZ25hbC8KPiA+Cj4gPiBOaWFsbCBHYWxsYWdoZXIKPiA+Cg== |
From: Niall G. <gal...@ya...> - 2007-04-06 12:53:52
|
Hi, With relation to recent comments on improvements and features to be added to the framework I have added the following: 1) A new @Text annotation This annotation will allow free text to be deserialized from an XML document using structures such as <element attr1="value1" attr2="value2"> This is free text </element> The @Text annotation can not be used with the @Element, @ElementList, or @ElementArray within a single class. Also only one @Text annotation can be used per class. 2) Loose mappings The @Root annotation has been given a new attribute called "strict". This is used as follows: @Root(name="example", strict=false) public class Example { @Element(name="foo") private String foo; } The above can be used to deserialize something such as: <example attr1="value1"> <foo>Example string</foo> <ignore attr="blah">Ignore this text</ignore> </example> The loose mapping (i.e strict=false) allows the deserialization to ignore some attributes or elements. This has not yet been released as an official version as I am currently debating whether the strict attribute for the @Root annotation is the best way to specify loose mappings. The beta can be downloaded from : http://svn.sourceforge.net/viewvc/simple/trunk/download/stream/target/1.2-beta/ Niall Gallagher ____________________________________________________________________________________ Be a PS3 game guru. Get your game face on with the latest PS3 news and previews at Yahoo! Games. http://videogames.yahoo.com/platform?platform=120121 |
From: Niall G. <gal...@ya...> - 2007-04-06 08:50:29
|
Hi Stefan,=0A=0AYou can make use of the signal framework by making your thr= eads Daemon objects. So instead of extending thread or using a thread use a= Daemon object. This object will recieve a shutdown signal when the Signall= er is asked to shutdown. Also a Module is like the Daemon, however instead = of using it with threads you would use the Module with arbitrary objects th= at want to listen for a shutdown signal. Using it in this way the Signaller= can send signals to parts of the server that wish to shutdown gracefully.= =0A =0ANiall Gallagher=0A=0A----- Original Message ----=0AFrom: Stefan H=FC= bner <sth...@go...>=0ATo: Simple support and user issues <simpl= ewe...@li...>=0ASent: Wednesday, April 4, 2007 4:28:2= 0 PM=0ASubject: Re: [Simpleweb-Support] How to shutdown?=0A=0ANiall,=0A=0AI= had a look at the new signal-framework but couldn't get much out of=0Ait. = Could you be so kind to provide an example of how to make use of=0Athe new = Module-class? I.e. what would I use a Module for?=0A=0AAnd whats your sugge= stion for how to shut down a PipelineHandler and=0Ait's Processors?=0A=0AMy= use case is to emulate (implemented as a Simple Resource) some web=0Aservi= ces providing backend communication for a component under unit=0Atest. I w= ant to configure the http services in different ways,=0Adepending on the un= it test to be run. To reconfigure I need to be able=0Ato start and stop the= service completely.=0AIs this possible using Simple and it's signal framew= ork?=0A=0ARegards,=0AStefan=0A=0A2007/3/22, Niall Gallagher <gallagher_nial= l...@ya...>:=0A> Hi,=0A>=0A> I have written a signalling framework which w= ill be used in Simple so send signals to all threads and processes within t= he server when something happens. For instance a shutdown signal will be di= stributed to all threads to allow them to shutdown cleanly. When I get the = time to finally release the next version this will be included it is locate= d at:=0A>=0A> https://svn.sourceforge.net/svnroot/simpleweb/branches/3.2/sr= c/simple/signal/=0A>=0A> Niall Gallagher=0A>=0A> ----- Original Message ---= -=0A> From: Stefan H=FCbner <sth...@go...>=0A> To: Simple suppo= rt and user issues <sim...@li...>=0A> Sent: Wedn= esday, March 21, 2007 7:54:23 PM=0A> Subject: Re: [Simpleweb-Support] How t= o shutdown?=0A>=0A> Hi Oscar,=0A>=0A> 2007/3/21, Oscar Perez <os_carp@telef= onica.net>:=0A> > Hi,=0A> > I don't have an answer to you, but I faced the = same problem just a week=0A> > ago and what I did was to track all the star= ted threads to kill them at=0A> > shutdown time. I'll not post my code here= now, but I'll advise you to=0A> > not do as me, as I lost a lot of hours t= racking threads and debugging...=0A>=0A> Thank you for that :-)=0A>=0A> > I= guess LoaderEngine was not designed to have a clean shutdown?=0A> >=0A> Wh= at I figured out, when I had a second look into Simple's code, is=0A> that = there is at least the opportunity to close() the ServerSocket the=0A> conne= ction is connect()ed with. After close() Simple won't serve any=0A> request= sent to the port the socket was serving.=0A>=0A> But getting rid of all th= ose threads seems like a mission impossible,=0A> given how much Simple reli= es on Singletons. One hardly gets the chance=0A> to get hold of all those h= idden instances, I guess.=0A>=0A> Cheers,=0A> Stefan=0A> >=0A> > En/na Stef= an H=FCbner ha escrit:=0A> > > Hi,=0A> > >=0A> > > Excuse me, if this has b= een asked before, but how do I shutdown a=0A> > > LoaderEngine? Is there a = way to do so?=0A> > >=0A> > > Cheers,=0A> > > Stefan=0A> > >=0A> > > ------= -------------------------------------------------------------------=0A> > >= Take Surveys. Earn Cash. Influence the Future of IT=0A> > > Join SourceFor= ge.net's Techsay panel and you'll get the chance to share your=0A> > > opin= ions on IT & business topics through brief surveys-and earn cash=0A> > > ht= tp://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID=3DDEVD= EV=0A> > > _______________________________________________=0A> > > Simplewe= b-Support mailing list=0A> > > Sim...@li...=0A> = > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support=0A> > >= =0A> > >=0A> > >=0A> >=0A> >=0A> > ----------------------------------------= ---------------------------------=0A> > Take Surveys. Earn Cash. Influence = the Future of IT=0A> > Join SourceForge.net's Techsay panel and you'll get = the chance to share your=0A> > opinions on IT & business topics through bri= ef surveys-and earn cash=0A> > http://www.techsay.com/default.php?page=3Djo= in.php&p=3Dsourceforge&CID=3DDEVDEV=0A> > _________________________________= ______________=0A> > Simpleweb-Support mailing list=0A> > Simpleweb-Support= @lists.sourceforge.net=0A> > https://lists.sourceforge.net/lists/listinfo/s= impleweb-support=0A> >=0A> ------------------------------------------------= -------------------------=0A> Take Surveys. Earn Cash. Influence the Future= of IT=0A> Join SourceForge.net's Techsay panel and you'll get the chance t= o share your=0A> opinions on IT & business topics through brief surveys-and= earn cash=0A> http://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourc= eforge&CID=3DDEVDEV=0A> _______________________________________________=0A>= Simpleweb-Support mailing list=0A> Sim...@li...= =0A> https://lists.sourceforge.net/lists/listinfo/simpleweb-support=0A>=0A>= =0A>=0A>=0A>=0A>=0A> ______________________________________________________= ______________________________=0A> We won't tell. Get more on shows you hat= e to love=0A> (and love to hate): Yahoo! TV's Guilty Pleasures list.=0A> ht= tp://tv.yahoo.com/collections/265=0A>=0A> ---------------------------------= ----------------------------------------=0A> Take Surveys. Earn Cash. Influ= ence the Future of IT=0A> Join SourceForge.net's Techsay panel and you'll g= et the chance to share your=0A> opinions on IT & business topics through br= ief surveys-and earn cash=0A> http://www.techsay.com/default.php?page=3Djoi= n.php&p=3Dsourceforge&CID=3DDEVDEV=0A> ____________________________________= ___________=0A> Simpleweb-Support mailing list=0A> Simpleweb-Support@lists.= sourceforge.net=0A> https://lists.sourceforge.net/lists/listinfo/simpleweb-= support=0A>=0A-------------------------------------------------------------= ------------=0ATake Surveys. Earn Cash. Influence the Future of IT=0AJoin S= ourceForge.net's Techsay panel and you'll get the chance to share your=0Aop= inions on IT & business topics through brief surveys-and earn cash=0Ahttp:/= /www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID=3DDEVDEV= =0A_______________________________________________=0ASimpleweb-Support mail= ing list=0AS...@li...=0Ahttps://lists.sourcefo= rge.net/lists/listinfo/simpleweb-support=0A=0A=0A=0A=0A=0A =0A_____________= _______________________________________________________________________=0AF= ood fight? Enjoy some healthy debate =0Ain the Yahoo! Answers Food & Drink = Q&A.=0Ahttp://answers.yahoo.com/dir/?link=3Dlist&sid=3D396545367 |
From: <sth...@go...> - 2007-04-04 23:28:25
|
TmlhbGwsCgpJIGhhZCBhIGxvb2sgYXQgdGhlIG5ldyBzaWduYWwtZnJhbWV3b3JrIGJ1dCBjb3Vs ZG4ndCBnZXQgbXVjaCBvdXQgb2YKaXQuIENvdWxkIHlvdSBiZSBzbyBraW5kIHRvIHByb3ZpZGUg YW4gZXhhbXBsZSBvZiBob3cgdG8gbWFrZSB1c2Ugb2YKdGhlIG5ldyBNb2R1bGUtY2xhc3M/IEku ZS4gd2hhdCB3b3VsZCBJIHVzZSBhIE1vZHVsZSBmb3I/CgpBbmQgd2hhdHMgeW91ciBzdWdnZXN0 aW9uIGZvciBob3cgdG8gc2h1dCBkb3duIGEgUGlwZWxpbmVIYW5kbGVyIGFuZAppdCdzIFByb2Nl c3NvcnM/CgpNeSB1c2UgY2FzZSBpcyB0byBlbXVsYXRlIChpbXBsZW1lbnRlZCBhcyBhIFNpbXBs ZSBSZXNvdXJjZSkgc29tZSB3ZWIKc2VydmljZXMgcHJvdmlkaW5nIGJhY2tlbmQgY29tbXVuaWNh dGlvbiAgZm9yIGEgY29tcG9uZW50IHVuZGVyIHVuaXQKdGVzdC4gSSB3YW50IHRvIGNvbmZpZ3Vy ZSB0aGUgaHR0cCBzZXJ2aWNlcyBpbiBkaWZmZXJlbnQgd2F5cywKZGVwZW5kaW5nIG9uIHRoZSB1 bml0IHRlc3QgdG8gYmUgcnVuLiBUbyByZWNvbmZpZ3VyZSBJIG5lZWQgdG8gYmUgYWJsZQp0byBz dGFydCBhbmQ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bmQgbG92ZSB0byBoYXRlKTogWWFob28hIFRWJ3MgR3VpbHR5IFBsZWFzdXJl cyBsaXN0Lgo+IGh0dHA6Ly90di55YWhvby5jb20vY29sbGVjdGlvbnMvMjY1Cj4KPiAtLS0tLS0t LS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0t LS0tLS0tLS0tCj4gVGFrZSBTdXJ2ZXlzLiBFYXJuIENhc2guIEluZmx1ZW5jZSB0aGUgRnV0dXJl IG9mIElUCj4gSm9pbiBTb3VyY2VGb3JnZS5uZXQncyBUZWNoc2F5IHBhbmVsIGFuZCB5b3UnbGwg Z2V0IHRoZSBjaGFuY2UgdG8gc2hhcmUgeW91cgo+IG9waW5pb25zIG9uIElUICYgYnVzaW5lc3Mg dG9waWNzIHRocm91Z2ggYnJpZWYgc3VydmV5cy1hbmQgZWFybiBjYXNoCj4gaHR0cDovL3d3dy50 ZWNoc2F5LmNvbS9kZWZhdWx0LnBocD9wYWdlPWpvaW4ucGhwJnA9c291cmNlZm9yZ2UmQ0lEPURF VkRFVgo+IF9fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fCj4g U2ltcGxld2ViLVN1cHBvcnQgbWFpbGluZyBsaXN0Cj4gU2ltcGxld2ViLVN1cHBvcnRAbGlzdHMu c291cmNlZm9yZ2UubmV0Cj4gaHR0cHM6Ly9saXN0cy5zb3VyY2Vmb3JnZS5uZXQvbGlzdHMvbGlz dGluZm8vc2ltcGxld2ViLXN1cHBvcnQKPgo= |
From: R P. <pat...@gm...> - 2007-03-29 11:53:49
|
Sent again with a correct message's obejct (sorry)... Hi Stephan, Something that works perfectly for me: public class MyServer implements Runnable { public void run() { System.err.println("Server is shutting down..."); // Close all (simple's connection, others)... ........ // This finalize all simpleweb's threads Runtime.getRuntime().runFinalization(); } public final static void shutdown() { // Shutdown your Simple server and exit! Runtime.getRuntime().exit(0); } protected MyServer() { Thread shutdownHook = new Thread(this, "shutdown-hook"); Runtime.getRuntime().addShutdownHook(shutdownHook); } } Regards, Pat 2007/3/29, sim...@li... < sim...@li...>: > > Send Simpleweb-Support mailing list submissions to > sim...@li... > > To subscribe or unsubscribe via the World Wide Web, visit > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > or, via email, send a message with subject or body 'help' to > sim...@li... > > You can reach the person managing the list at > sim...@li... > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of Simpleweb-Support digest..." > > > Today's Topics: > > 1. Re: Simpleweb-Support Digest, Vol 7, Issue 3 (R Pat) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 29 Mar 2007 08:05:32 +0100 > From: "R Pat" <pat...@gm...> > Subject: Re: [Simpleweb-Support] Simpleweb-Support Digest, Vol 7, > Issue 3 > To: sim...@li... > Message-ID: > <e75...@ma...> > Content-Type: text/plain; charset="iso-8859-1" > > Hi Stephan, > > Something that works perfectly for me: > > public class MyServer implements Runnable { > > public void run() { > System.err.println("Server is shutting down..."); > > // Close all (simple's connection, others)... > ........ > > // This finalize all simpleweb's threads > Runtime.getRuntime().runFinalization(); > } > > public final static void shutdown() { > // Shutdown your Simple server and exit! > Runtime.getRuntime().exit(0); > } > > protected MyServer() { > Thread shutdownHook = new Thread(this, "shutdown-hook"); > > Runtime.getRuntime().addShutdownHook(shutdownHook); > } > } > > > 2007/3/28, sim...@li... < > sim...@li...>: > > > > Send Simpleweb-Support mailing list submissions to > > sim...@li... > > > > To subscribe or unsubscribe via the World Wide Web, visit > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > or, via email, send a message with subject or body 'help' to > > sim...@li... > > > > You can reach the person managing the list at > > sim...@li... > > > > When replying, please edit your Subject line so it is more specific > > than "Re: Contents of Simpleweb-Support digest..." > > > > > > Today's Topics: > > > > 1. DomainHandler with HTTP 1.0 (Jeff Nichols) > > 2. Re: DomainHandler with HTTP 1.0 (Jeff Nichols) > > 3. How to shutdown? ( Stefan H?bner ) > > 4. Re: How to shutdown? (Oscar Perez) > > 5. Re: How to shutdown? ( Stefan H?bner ) > > 6. Re: How to shutdown? (Niall Gallagher) > > 7. Re: How to shutdown? ( Stefan H?bner ) > > > > > > ---------------------------------------------------------------------- > > > > Message: 1 > > Date: Fri, 16 Mar 2007 13:17:13 +0100 > > From: Jeff Nichols <je...@ne...> > > Subject: [Simpleweb-Support] DomainHandler with HTTP 1.0 > > To: Simple support and user issues > > <sim...@li...> > > Message-ID: <5C0...@ne...> > > Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed > > > > Hello Niall (and all), > > > > After a tedious 2 day debugging session, I finally figured out why > > PayPal's IPN (Instant Payment Notification) system was not working > > with my server. > > > > I'm using the virtual hosting facilities of Simple (through the > > DomainHandler) and PayPal is (for whatever reason) sending their > > notifications with HTTP/1.0. This creates a problem, as the > > DomainHandler only works with HTTP/1.1 requests (which should include > > a 'Host' header). > > > > Is there any way around this? I thought of writing a specialized > > DomainHandler that would fall back to parsing its own 'Host' if none > > was available, but I cannot find anywhere in the Request where the > > entire URL is available. > > > > Any help is greatly appreciated. > > > > Jeff > > > > > > > > ------------------------------ > > > > Message: 2 > > Date: Fri, 16 Mar 2007 14:11:26 +0100 > > From: Jeff Nichols <je...@ne...> > > Subject: Re: [Simpleweb-Support] DomainHandler with HTTP 1.0 > > To: Simple support and user issues > > <sim...@li...> > > Message-ID: <C2F...@ne...> > > Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed > > > > An update: > > > > In the Simple API docs for DomainHandler.handle(Request,Response) it > > states: > > > > "For compatibility with HTTP/1.0 clients that do not support the Host > > header this delegates the processing of requests without the Host > > header to a default ProtocolHandler." > > > > Depending on how this statement is interpreted, it is not entirely > > correct, as this method does not look for a 'Host' header unless HTTP/ > > 1.1 is being used. > > > > Well low and behold, the PayPal HTTP/1.0 request seems to include a > > 'Host' header. So a workaround (for me) seems possible by > > subclassing DomainHandler and overriding 'handle'. > > > > Jeff > > > > > > > > On Mar 16, 2007, at 1:17 PM, Jeff Nichols wrote: > > > > > Hello Niall (and all), > > > > > > After a tedious 2 day debugging session, I finally figured out why > > > PayPal's IPN (Instant Payment Notification) system was not working > > > with my server. > > > > > > I'm using the virtual hosting facilities of Simple (through the > > > DomainHandler) and PayPal is (for whatever reason) sending their > > > notifications with HTTP/1.0. This creates a problem, as the > > > DomainHandler only works with HTTP/1.1 requests (which should include > > > a 'Host' header). > > > > > > Is there any way around this? I thought of writing a specialized > > > DomainHandler that would fall back to parsing its own 'Host' if none > > > was available, but I cannot find anywhere in the Request where the > > > entire URL is available. > > > > > > Any help is greatly appreciated. > > > > > > Jeff > > > > > > ---------------------------------------------------------------------- > > > --- > > > Take Surveys. Earn Cash. Influence the Future of IT > > > Join SourceForge.net's Techsay panel and you'll get the chance to > > > share your > > > opinions on IT & business topics through brief surveys-and earn cash > > > http://www.techsay.com/default.php? > > > page=join.php&p=sourceforge&CID=DEVDEV > > > _______________________________________________ > > > Simpleweb-Support mailing list > > > Sim...@li... > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > > > ------------------------------ > > > > Message: 3 > > Date: Wed, 21 Mar 2007 18:26:11 +0100 > > From: " Stefan H?bner " <sth...@go...> > > Subject: [Simpleweb-Support] How to shutdown? > > To: sim...@li... > > Message-ID: > > <a36...@ma...> > > Content-Type: text/plain; charset=UTF-8; format=flowed > > > > Hi, > > > > Excuse me, if this has been asked before, but how do I shutdown a > > LoaderEngine? Is there a way to do so? > > > > Cheers, > > Stefan > > > > > > > > ------------------------------ > > > > Message: 4 > > Date: Wed, 21 Mar 2007 18:31:42 +0100 > > From: Oscar Perez <os...@te...> > > Subject: Re: [Simpleweb-Support] How to shutdown? > > To: Simple support and user issues > > <sim...@li...> > > Message-ID: <460...@te...> > > Content-Type: text/plain; charset=ISO-8859-1; format=flowed > > > > Hi, > > I don't have an answer to you, but I faced the same problem just a week > > ago and what I did was to track all the started threads to kill them at > > shutdown time. I'll not post my code here now, but I'll advise you to > > not do as me, as I lost a lot of hours tracking threads and debugging... > > I guess LoaderEngine was not designed to have a clean shutdown? > > > > > > En/na Stefan H?bner ha escrit: > > > Hi, > > > > > > Excuse me, if this has been asked before, but how do I shutdown a > > > LoaderEngine? Is there a way to do so? > > > > > > Cheers, > > > Stefan > > > > > > > > > ------------------------------------------------------------------------- > > > Take Surveys. Earn Cash. Influence the Future of IT > > > Join SourceForge.net's Techsay panel and you'll get the chance to > share > > your > > > opinions on IT & business topics through brief surveys-and earn cash > > > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > _______________________________________________ > > > Simpleweb-Support mailing list > > > Sim...@li... > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > > > > > > > > > ------------------------------ > > > > Message: 5 > > Date: Wed, 21 Mar 2007 20:54:23 +0100 > > From: " Stefan H?bner " <sth...@go...> > > Subject: Re: [Simpleweb-Support] How to shutdown? > > To: "Simple support and user issues" > > <sim...@li...> > > Message-ID: > > <a36...@ma...> > > Content-Type: text/plain; charset=UTF-8; format=flowed > > > > Hi Oscar, > > > > 2007/3/21, Oscar Perez <os...@te...>: > > > Hi, > > > I don't have an answer to you, but I faced the same problem just a > week > > > ago and what I did was to track all the started threads to kill them > at > > > shutdown time. I'll not post my code here now, but I'll advise you to > > > not do as me, as I lost a lot of hours tracking threads and > debugging... > > > > Thank you for that :-) > > > > > I guess LoaderEngine was not designed to have a clean shutdown? > > > > > What I figured out, when I had a second look into Simple's code, is > > that there is at least the opportunity to close() the ServerSocket the > > connection is connect()ed with. After close() Simple won't serve any > > request sent to the port the socket was serving. > > > > But getting rid of all those threads seems like a mission impossible, > > given how much Simple relies on Singletons. One hardly gets the chance > > to get hold of all those hidden instances, I guess. > > > > Cheers, > > Stefan > > > > > > En/na Stefan H?bner ha escrit: > > > > Hi, > > > > > > > > Excuse me, if this has been asked before, but how do I shutdown a > > > > LoaderEngine? Is there a way to do so? > > > > > > > > Cheers, > > > > Stefan > > > > > > > > > > > ------------------------------------------------------------------------- > > > > Take Surveys. Earn Cash. Influence the Future of IT > > > > Join SourceForge.net's Techsay panel and you'll get the chance to > > share your > > > > opinions on IT & business topics through brief surveys-and earn cash > > > > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > > _______________________________________________ > > > > Simpleweb-Support mailing list > > > > Sim...@li... > > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > Take Surveys. Earn Cash. Influence the Future of IT > > > Join SourceForge.net's Techsay panel and you'll get the chance to > share > > your > > > opinions on IT & business topics through brief surveys-and earn cash > > > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > _______________________________________________ > > > Simpleweb-Support mailing list > > > Sim...@li... > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > ------------------------------ > > > > Message: 6 > > Date: Thu, 22 Mar 2007 02:42:52 -0700 (PDT) > > From: Niall Gallagher <gal...@ya...> > > Subject: Re: [Simpleweb-Support] How to shutdown? > > To: Simple support and user issues > > <sim...@li...> > > Message-ID: <695...@we...> > > Content-Type: text/plain; charset=iso-8859-1 > > > > Hi, > > > > I have written a signalling framework which will be used in Simple so > send > > signals to all threads and processes within the server when something > > happens. For instance a shutdown signal will be distributed to all > threads > > to allow them to shutdown cleanly. When I get the time to finally > release > > the next version this will be included it is located at: > > > > > > > https://svn.sourceforge.net/svnroot/simpleweb/branches/3.2/src/simple/signal/ > > > > Niall Gallagher > > > > ----- Original Message ---- > > From: Stefan H?bner <sth...@go...> > > To: Simple support and user issues < > > sim...@li...> > > Sent: Wednesday, March 21, 2007 7:54:23 PM > > Subject: Re: [Simpleweb-Support] How to shutdown? > > > > Hi Oscar, > > > > 2007/3/21, Oscar Perez <os...@te...>: > > > Hi, > > > I don't have an answer to you, but I faced the same problem just a > week > > > ago and what I did was to track all the started threads to kill them > at > > > shutdown time. I'll not post my code here now, but I'll advise you to > > > not do as me, as I lost a lot of hours tracking threads and > debugging... > > > > Thank you for that :-) > > > > > I guess LoaderEngine was not designed to have a clean shutdown? > > > > > What I figured out, when I had a second look into Simple's code, is > > that there is at least the opportunity to close() the ServerSocket the > > connection is connect()ed with. After close() Simple won't serve any > > request sent to the port the socket was serving. > > > > But getting rid of all those threads seems like a mission impossible, > > given how much Simple relies on Singletons. One hardly gets the chance > > to get hold of all those hidden instances, I guess. > > > > Cheers, > > Stefan > > > > > > En/na Stefan H?bner ha escrit: > > > > Hi, > > > > > > > > Excuse me, if this has been asked before, but how do I shutdown a > > > > LoaderEngine? Is there a way to do so? > > > > > > > > Cheers, > > > > Stefan > > > > > > > > > > > ------------------------------------------------------------------------- > > > > Take Surveys. Earn Cash. Influence the Future of IT > > > > Join SourceForge.net's Techsay panel and you'll get the chance to > > share your > > > > opinions on IT & business topics through brief surveys-and earn cash > > > > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > > _______________________________________________ > > > > Simpleweb-Support mailing list > > > > Sim...@li... > > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > Take Surveys. Earn Cash. Influence the Future of IT > > > Join SourceForge.net's Techsay panel and you'll get the chance to > share > > your > > > opinions on IT & business topics through brief surveys-and earn cash > > > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > _______________________________________________ > > > Simpleweb-Support mailing list > > > Sim...@li... > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to share > > your > > opinions on IT & business topics through brief surveys-and earn cash > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > > Simpleweb-Support mailing list > > Sim...@li... > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > > > > > > > ____________________________________________________________________________________ > > We won't tell. Get more on shows you hate to love > > (and love to hate): Yahoo! TV's Guilty Pleasures list. > > http://tv.yahoo.com/collections/265 > > > > > > > > ------------------------------ > > > > Message: 7 > > Date: Wed, 28 Mar 2007 16:43:59 +0200 > > From: " Stefan H?bner " <sth...@go...> > > Subject: Re: [Simpleweb-Support] How to shutdown? > > To: "Simple support and user issues" > > <sim...@li...> > > Message-ID: > > <a36...@ma...> > > Content-Type: text/plain; charset=UTF-8; format=flowed > > > > Ah, sorry for the delay. Thanks Niall, I'll have a look in the next > days! > > > > Cheers, > > Stefan > > > > 2007/3/22, Niall Gallagher <gal...@ya...>: > > > Hi, > > > > > > I have written a signalling framework which will be used in Simple so > > send signals to all threads and processes within the server when > something > > happens. For instance a shutdown signal will be distributed to all > threads > > to allow them to shutdown cleanly. When I get the time to finally > release > > the next version this will be included it is located at: > > > > > > > > > https://svn.sourceforge.net/svnroot/simpleweb/branches/3.2/src/simple/signal/ > > > > > > Niall Gallagher > > > > > > ----- Original Message ---- > > > From: Stefan H?bner <sth...@go...> > > > To: Simple support and user issues < > > sim...@li...> > > > Sent: Wednesday, March 21, 2007 7:54:23 PM > > > Subject: Re: [Simpleweb-Support] How to shutdown? > > > > > > Hi Oscar, > > > > > > 2007/3/21, Oscar Perez <os...@te...>: > > > > Hi, > > > > I don't have an answer to you, but I faced the same problem just a > > week > > > > ago and what I did was to track all the started threads to kill them > > at > > > > shutdown time. I'll not post my code here now, but I'll advise you > to > > > > not do as me, as I lost a lot of hours tracking threads and > > debugging... > > > > > > Thank you for that :-) > > > > > > > I guess LoaderEngine was not designed to have a clean shutdown? > > > > > > > What I figured out, when I had a second look into Simple's code, is > > > that there is at least the opportunity to close() the ServerSocket the > > > connection is connect()ed with. After close() Simple won't serve any > > > request sent to the port the socket was serving. > > > > > > But getting rid of all those threads seems like a mission impossible, > > > given how much Simple relies on Singletons. One hardly gets the chance > > > to get hold of all those hidden instances, I guess. > > > > > > Cheers, > > > Stefan > > > > > > > > En/na Stefan H?bner ha escrit: > > > > > Hi, > > > > > > > > > > Excuse me, if this has been asked before, but how do I shutdown a > > > > > LoaderEngine? Is there a way to do so? > > > > > > > > > > Cheers, > > > > > Stefan > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > > > Take Surveys. Earn Cash. Influence the Future of IT > > > > > Join SourceForge.net's Techsay panel and you'll get the chance to > > share your > > > > > opinions on IT & business topics through brief surveys-and earn > cash > > > > > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > > > _______________________________________________ > > > > > Simpleweb-Support mailing list > > > > > Sim...@li... > > > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > > Take Surveys. Earn Cash. Influence the Future of IT > > > > Join SourceForge.net's Techsay panel and you'll get the chance to > > share your > > > > opinions on IT & business topics through brief surveys-and earn cash > > > > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > > _______________________________________________ > > > > Simpleweb-Support mailing list > > > > Sim...@li... > > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > ------------------------------------------------------------------------- > > > Take Surveys. Earn Cash. Influence the Future of IT > > > Join SourceForge.net's Techsay panel and you'll get the chance to > share > > your > > > opinions on IT & business topics through brief surveys-and earn cash > > > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > _______________________________________________ > > > Simpleweb-Support mailing list > > > Sim...@li... > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > > > > > > > > > > > > > > ____________________________________________________________________________________ > > > We won't tell. Get more on shows you hate to love > > > (and love to hate): Yahoo! TV's Guilty Pleasures list. > > > http://tv.yahoo.com/collections/265 > > > > > > > > > ------------------------------------------------------------------------- > > > Take Surveys. Earn Cash. Influence the Future of IT > > > Join SourceForge.net's Techsay panel and you'll get the chance to > share > > your > > > opinions on IT & business topics through brief surveys-and earn cash > > > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > _______________________________________________ > > > Simpleweb-Support mailing list > > > Sim...@li... > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > ------------------------------ > > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to share > > your > > opinions on IT & business topics through brief surveys-and earn cash > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > > ------------------------------ > > > > _______________________________________________ > > Simpleweb-Support mailing list > > Sim...@li... > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > End of Simpleweb-Support Digest, Vol 7, Issue 3 > > *********************************************** > > > -------------- next part -------------- > An HTML attachment was scrubbed... > > ------------------------------ > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > ------------------------------ > > _______________________________________________ > Simpleweb-Support mailing list > Sim...@li... > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > End of Simpleweb-Support Digest, Vol 7, Issue 4 > *********************************************** > |
From: R P. <pat...@gm...> - 2007-03-29 07:05:33
|
Hi Stephan, Something that works perfectly for me: public class MyServer implements Runnable { public void run() { System.err.println("Server is shutting down..."); // Close all (simple's connection, others)... ........ // This finalize all simpleweb's threads Runtime.getRuntime().runFinalization(); } public final static void shutdown() { // Shutdown your Simple server and exit! Runtime.getRuntime().exit(0); } protected MyServer() { Thread shutdownHook = new Thread(this, "shutdown-hook"); Runtime.getRuntime().addShutdownHook(shutdownHook); } } 2007/3/28, sim...@li... < sim...@li...>: > > Send Simpleweb-Support mailing list submissions to > sim...@li... > > To subscribe or unsubscribe via the World Wide Web, visit > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > or, via email, send a message with subject or body 'help' to > sim...@li... > > You can reach the person managing the list at > sim...@li... > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of Simpleweb-Support digest..." > > > Today's Topics: > > 1. DomainHandler with HTTP 1.0 (Jeff Nichols) > 2. Re: DomainHandler with HTTP 1.0 (Jeff Nichols) > 3. How to shutdown? ( Stefan H?bner ) > 4. Re: How to shutdown? (Oscar Perez) > 5. Re: How to shutdown? ( Stefan H?bner ) > 6. Re: How to shutdown? (Niall Gallagher) > 7. Re: How to shutdown? ( Stefan H?bner ) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Fri, 16 Mar 2007 13:17:13 +0100 > From: Jeff Nichols <je...@ne...> > Subject: [Simpleweb-Support] DomainHandler with HTTP 1.0 > To: Simple support and user issues > <sim...@li...> > Message-ID: <5C0...@ne...> > Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed > > Hello Niall (and all), > > After a tedious 2 day debugging session, I finally figured out why > PayPal's IPN (Instant Payment Notification) system was not working > with my server. > > I'm using the virtual hosting facilities of Simple (through the > DomainHandler) and PayPal is (for whatever reason) sending their > notifications with HTTP/1.0. This creates a problem, as the > DomainHandler only works with HTTP/1.1 requests (which should include > a 'Host' header). > > Is there any way around this? I thought of writing a specialized > DomainHandler that would fall back to parsing its own 'Host' if none > was available, but I cannot find anywhere in the Request where the > entire URL is available. > > Any help is greatly appreciated. > > Jeff > > > > ------------------------------ > > Message: 2 > Date: Fri, 16 Mar 2007 14:11:26 +0100 > From: Jeff Nichols <je...@ne...> > Subject: Re: [Simpleweb-Support] DomainHandler with HTTP 1.0 > To: Simple support and user issues > <sim...@li...> > Message-ID: <C2F...@ne...> > Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed > > An update: > > In the Simple API docs for DomainHandler.handle(Request,Response) it > states: > > "For compatibility with HTTP/1.0 clients that do not support the Host > header this delegates the processing of requests without the Host > header to a default ProtocolHandler." > > Depending on how this statement is interpreted, it is not entirely > correct, as this method does not look for a 'Host' header unless HTTP/ > 1.1 is being used. > > Well low and behold, the PayPal HTTP/1.0 request seems to include a > 'Host' header. So a workaround (for me) seems possible by > subclassing DomainHandler and overriding 'handle'. > > Jeff > > > > On Mar 16, 2007, at 1:17 PM, Jeff Nichols wrote: > > > Hello Niall (and all), > > > > After a tedious 2 day debugging session, I finally figured out why > > PayPal's IPN (Instant Payment Notification) system was not working > > with my server. > > > > I'm using the virtual hosting facilities of Simple (through the > > DomainHandler) and PayPal is (for whatever reason) sending their > > notifications with HTTP/1.0. This creates a problem, as the > > DomainHandler only works with HTTP/1.1 requests (which should include > > a 'Host' header). > > > > Is there any way around this? I thought of writing a specialized > > DomainHandler that would fall back to parsing its own 'Host' if none > > was available, but I cannot find anywhere in the Request where the > > entire URL is available. > > > > Any help is greatly appreciated. > > > > Jeff > > > > ---------------------------------------------------------------------- > > --- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to > > share your > > opinions on IT & business topics through brief surveys-and earn cash > > http://www.techsay.com/default.php? > > page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > > Simpleweb-Support mailing list > > Sim...@li... > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > ------------------------------ > > Message: 3 > Date: Wed, 21 Mar 2007 18:26:11 +0100 > From: " Stefan H?bner " <sth...@go...> > Subject: [Simpleweb-Support] How to shutdown? > To: sim...@li... > Message-ID: > <a36...@ma...> > Content-Type: text/plain; charset=UTF-8; format=flowed > > Hi, > > Excuse me, if this has been asked before, but how do I shutdown a > LoaderEngine? Is there a way to do so? > > Cheers, > Stefan > > > > ------------------------------ > > Message: 4 > Date: Wed, 21 Mar 2007 18:31:42 +0100 > From: Oscar Perez <os...@te...> > Subject: Re: [Simpleweb-Support] How to shutdown? > To: Simple support and user issues > <sim...@li...> > Message-ID: <460...@te...> > Content-Type: text/plain; charset=ISO-8859-1; format=flowed > > Hi, > I don't have an answer to you, but I faced the same problem just a week > ago and what I did was to track all the started threads to kill them at > shutdown time. I'll not post my code here now, but I'll advise you to > not do as me, as I lost a lot of hours tracking threads and debugging... > I guess LoaderEngine was not designed to have a clean shutdown? > > > En/na Stefan H?bner ha escrit: > > Hi, > > > > Excuse me, if this has been asked before, but how do I shutdown a > > LoaderEngine? Is there a way to do so? > > > > Cheers, > > Stefan > > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > > opinions on IT & business topics through brief surveys-and earn cash > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > > Simpleweb-Support mailing list > > Sim...@li... > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > ------------------------------ > > Message: 5 > Date: Wed, 21 Mar 2007 20:54:23 +0100 > From: " Stefan H?bner " <sth...@go...> > Subject: Re: [Simpleweb-Support] How to shutdown? > To: "Simple support and user issues" > <sim...@li...> > Message-ID: > <a36...@ma...> > Content-Type: text/plain; charset=UTF-8; format=flowed > > Hi Oscar, > > 2007/3/21, Oscar Perez <os...@te...>: > > Hi, > > I don't have an answer to you, but I faced the same problem just a week > > ago and what I did was to track all the started threads to kill them at > > shutdown time. I'll not post my code here now, but I'll advise you to > > not do as me, as I lost a lot of hours tracking threads and debugging... > > Thank you for that :-) > > > I guess LoaderEngine was not designed to have a clean shutdown? > > > What I figured out, when I had a second look into Simple's code, is > that there is at least the opportunity to close() the ServerSocket the > connection is connect()ed with. After close() Simple won't serve any > request sent to the port the socket was serving. > > But getting rid of all those threads seems like a mission impossible, > given how much Simple relies on Singletons. One hardly gets the chance > to get hold of all those hidden instances, I guess. > > Cheers, > Stefan > > > > En/na Stefan H?bner ha escrit: > > > Hi, > > > > > > Excuse me, if this has been asked before, but how do I shutdown a > > > LoaderEngine? Is there a way to do so? > > > > > > Cheers, > > > Stefan > > > > > > > ------------------------------------------------------------------------- > > > Take Surveys. Earn Cash. Influence the Future of IT > > > Join SourceForge.net's Techsay panel and you'll get the chance to > share your > > > opinions on IT & business topics through brief surveys-and earn cash > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > _______________________________________________ > > > Simpleweb-Support mailing list > > > Sim...@li... > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > > opinions on IT & business topics through brief surveys-and earn cash > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > > Simpleweb-Support mailing list > > Sim...@li... > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > ------------------------------ > > Message: 6 > Date: Thu, 22 Mar 2007 02:42:52 -0700 (PDT) > From: Niall Gallagher <gal...@ya...> > Subject: Re: [Simpleweb-Support] How to shutdown? > To: Simple support and user issues > <sim...@li...> > Message-ID: <695...@we...> > Content-Type: text/plain; charset=iso-8859-1 > > Hi, > > I have written a signalling framework which will be used in Simple so send > signals to all threads and processes within the server when something > happens. For instance a shutdown signal will be distributed to all threads > to allow them to shutdown cleanly. When I get the time to finally release > the next version this will be included it is located at: > > > https://svn.sourceforge.net/svnroot/simpleweb/branches/3.2/src/simple/signal/ > > Niall Gallagher > > ----- Original Message ---- > From: Stefan H?bner <sth...@go...> > To: Simple support and user issues < > sim...@li...> > Sent: Wednesday, March 21, 2007 7:54:23 PM > Subject: Re: [Simpleweb-Support] How to shutdown? > > Hi Oscar, > > 2007/3/21, Oscar Perez <os...@te...>: > > Hi, > > I don't have an answer to you, but I faced the same problem just a week > > ago and what I did was to track all the started threads to kill them at > > shutdown time. I'll not post my code here now, but I'll advise you to > > not do as me, as I lost a lot of hours tracking threads and debugging... > > Thank you for that :-) > > > I guess LoaderEngine was not designed to have a clean shutdown? > > > What I figured out, when I had a second look into Simple's code, is > that there is at least the opportunity to close() the ServerSocket the > connection is connect()ed with. After close() Simple won't serve any > request sent to the port the socket was serving. > > But getting rid of all those threads seems like a mission impossible, > given how much Simple relies on Singletons. One hardly gets the chance > to get hold of all those hidden instances, I guess. > > Cheers, > Stefan > > > > En/na Stefan H?bner ha escrit: > > > Hi, > > > > > > Excuse me, if this has been asked before, but how do I shutdown a > > > LoaderEngine? Is there a way to do so? > > > > > > Cheers, > > > Stefan > > > > > > > ------------------------------------------------------------------------- > > > Take Surveys. Earn Cash. Influence the Future of IT > > > Join SourceForge.net's Techsay panel and you'll get the chance to > share your > > > opinions on IT & business topics through brief surveys-and earn cash > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > _______________________________________________ > > > Simpleweb-Support mailing list > > > Sim...@li... > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > > opinions on IT & business topics through brief surveys-and earn cash > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > > Simpleweb-Support mailing list > > Sim...@li... > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Simpleweb-Support mailing list > Sim...@li... > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > ____________________________________________________________________________________ > We won't tell. Get more on shows you hate to love > (and love to hate): Yahoo! TV's Guilty Pleasures list. > http://tv.yahoo.com/collections/265 > > > > ------------------------------ > > Message: 7 > Date: Wed, 28 Mar 2007 16:43:59 +0200 > From: " Stefan H?bner " <sth...@go...> > Subject: Re: [Simpleweb-Support] How to shutdown? > To: "Simple support and user issues" > <sim...@li...> > Message-ID: > <a36...@ma...> > Content-Type: text/plain; charset=UTF-8; format=flowed > > Ah, sorry for the delay. Thanks Niall, I'll have a look in the next days! > > Cheers, > Stefan > > 2007/3/22, Niall Gallagher <gal...@ya...>: > > Hi, > > > > I have written a signalling framework which will be used in Simple so > send signals to all threads and processes within the server when something > happens. For instance a shutdown signal will be distributed to all threads > to allow them to shutdown cleanly. When I get the time to finally release > the next version this will be included it is located at: > > > > > https://svn.sourceforge.net/svnroot/simpleweb/branches/3.2/src/simple/signal/ > > > > Niall Gallagher > > > > ----- Original Message ---- > > From: Stefan H?bner <sth...@go...> > > To: Simple support and user issues < > sim...@li...> > > Sent: Wednesday, March 21, 2007 7:54:23 PM > > Subject: Re: [Simpleweb-Support] How to shutdown? > > > > Hi Oscar, > > > > 2007/3/21, Oscar Perez <os...@te...>: > > > Hi, > > > I don't have an answer to you, but I faced the same problem just a > week > > > ago and what I did was to track all the started threads to kill them > at > > > shutdown time. I'll not post my code here now, but I'll advise you to > > > not do as me, as I lost a lot of hours tracking threads and > debugging... > > > > Thank you for that :-) > > > > > I guess LoaderEngine was not designed to have a clean shutdown? > > > > > What I figured out, when I had a second look into Simple's code, is > > that there is at least the opportunity to close() the ServerSocket the > > connection is connect()ed with. After close() Simple won't serve any > > request sent to the port the socket was serving. > > > > But getting rid of all those threads seems like a mission impossible, > > given how much Simple relies on Singletons. One hardly gets the chance > > to get hold of all those hidden instances, I guess. > > > > Cheers, > > Stefan > > > > > > En/na Stefan H?bner ha escrit: > > > > Hi, > > > > > > > > Excuse me, if this has been asked before, but how do I shutdown a > > > > LoaderEngine? Is there a way to do so? > > > > > > > > Cheers, > > > > Stefan > > > > > > > > > ------------------------------------------------------------------------- > > > > Take Surveys. Earn Cash. Influence the Future of IT > > > > Join SourceForge.net's Techsay panel and you'll get the chance to > share your > > > > opinions on IT & business topics through brief surveys-and earn cash > > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > > _______________________________________________ > > > > Simpleweb-Support mailing list > > > > Sim...@li... > > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > Take Surveys. Earn Cash. Influence the Future of IT > > > Join SourceForge.net's Techsay panel and you'll get the chance to > share your > > > opinions on IT & business topics through brief surveys-and earn cash > > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > _______________________________________________ > > > Simpleweb-Support mailing list > > > Sim...@li... > > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > > opinions on IT & business topics through brief surveys-and earn cash > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > > Simpleweb-Support mailing list > > Sim...@li... > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > > > > > > > > ____________________________________________________________________________________ > > We won't tell. Get more on shows you hate to love > > (and love to hate): Yahoo! TV's Guilty Pleasures list. > > http://tv.yahoo.com/collections/265 > > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > > opinions on IT & business topics through brief surveys-and earn cash > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > > Simpleweb-Support mailing list > > Sim...@li... > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > ------------------------------ > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > ------------------------------ > > _______________________________________________ > Simpleweb-Support mailing list > Sim...@li... > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > End of Simpleweb-Support Digest, Vol 7, Issue 3 > *********************************************** > |
From: <sth...@go...> - 2007-03-28 14:44:01
|
QWgsIHNvcnJ5IGZ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dHkgUGxlYXN1cmVzIGxpc3QuCj4gaHR0cDovL3R2Lnlh aG9vLmNvbS9jb2xsZWN0aW9ucy8yNjUKPgo+IC0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0t LS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0KPiBUYWtlIFN1cnZl eXMuIEVhcm4gQ2FzaC4gSW5mbHVlbmNlIHRoZSBGdXR1cmUgb2YgSVQKPiBKb2luIFNvdXJjZUZv cmdlLm5ldCdzIFRlY2hzYXkgcGFuZWwgYW5kIHlvdSdsbCBnZXQgdGhlIGNoYW5jZSB0byBzaGFy ZSB5b3VyCj4gb3BpbmlvbnMgb24gSVQgJiBidXNpbmVzcyB0b3BpY3MgdGhyb3VnaCBicmllZiBz dXJ2ZXlzLWFuZCBlYXJuIGNhc2gKPiBodHRwOi8vd3d3LnRlY2hzYXkuY29tL2RlZmF1bHQucGhw P3BhZ2U9am9pbi5waHAmcD1zb3VyY2Vmb3JnZSZDSUQ9REVWREVWCj4gX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KPiBTaW1wbGV3ZWItU3VwcG9ydCBtYWls aW5nIGxpc3QKPiBTaW1wbGV3ZWItU3VwcG9ydEBsaXN0cy5zb3VyY2Vmb3JnZS5uZXQKPiBodHRw czovL2xpc3RzLnNvdXJjZWZvcmdlLm5ldC9saXN0cy9saXN0aW5mby9zaW1wbGV3ZWItc3VwcG9y dAo+Cg== |
From: Niall G. <gal...@ya...> - 2007-03-22 09:43:00
|
Hi,=0A=0AI have written a signalling framework which will be used in Simple= so send signals to all threads and processes within the server when someth= ing happens. For instance a shutdown signal will be distributed to all thre= ads to allow them to shutdown cleanly. When I get the time to finally relea= se the next version this will be included it is located at:=0A=0Ahttps://sv= n.sourceforge.net/svnroot/simpleweb/branches/3.2/src/simple/signal/=0A =0AN= iall Gallagher=0A=0A----- Original Message ----=0AFrom: Stefan H=FCbner <st= hu...@go...>=0ATo: Simple support and user issues <simpleweb-sup= po...@li...>=0ASent: Wednesday, March 21, 2007 7:54:23 PM=0A= Subject: Re: [Simpleweb-Support] How to shutdown?=0A=0AHi Oscar,=0A=0A2007/= 3/21, Oscar Perez <os...@te...>:=0A> Hi,=0A> I don't have an ans= wer to you, but I faced the same problem just a week=0A> ago and what I did= was to track all the started threads to kill them at=0A> shutdown time. I'= ll not post my code here now, but I'll advise you to=0A> not do as me, as I= lost a lot of hours tracking threads and debugging...=0A=0AThank you for t= hat :-)=0A=0A> I guess LoaderEngine was not designed to have a clean shutdo= wn?=0A>=0AWhat I figured out, when I had a second look into Simple's code, = is=0Athat there is at least the opportunity to close() the ServerSocket the= =0Aconnection is connect()ed with. After close() Simple won't serve any=0Ar= equest sent to the port the socket was serving.=0A=0ABut getting rid of all= those threads seems like a mission impossible,=0Agiven how much Simple rel= ies on Singletons. One hardly gets the chance=0Ato get hold of all those hi= dden instances, I guess.=0A=0ACheers,=0AStefan=0A>=0A> En/na Stefan H=FCbne= r ha escrit:=0A> > Hi,=0A> >=0A> > Excuse me, if this has been asked before= , but how do I shutdown a=0A> > LoaderEngine? Is there a way to do so?=0A> = >=0A> > Cheers,=0A> > Stefan=0A> >=0A> > ----------------------------------= ---------------------------------------=0A> > Take Surveys. Earn Cash. Infl= uence the Future of IT=0A> > Join SourceForge.net's Techsay panel and you'l= l get the chance to share your=0A> > opinions on IT & business topics throu= gh brief surveys-and earn cash=0A> > http://www.techsay.com/default.php?pag= e=3Djoin.php&p=3Dsourceforge&CID=3DDEVDEV=0A> > ___________________________= ____________________=0A> > Simpleweb-Support mailing list=0A> > Simpleweb-S= up...@li...=0A> > https://lists.sourceforge.net/lists/list= info/simpleweb-support=0A> >=0A> >=0A> >=0A>=0A>=0A> ----------------------= ---------------------------------------------------=0A> Take Surveys. Earn = Cash. Influence the Future of IT=0A> Join SourceForge.net's Techsay panel a= nd you'll get the chance to share your=0A> opinions on IT & business topics= through brief surveys-and earn cash=0A> http://www.techsay.com/default.php= ?page=3Djoin.php&p=3Dsourceforge&CID=3DDEVDEV=0A> _________________________= ______________________=0A> Simpleweb-Support mailing list=0A> Simpleweb-Sup= po...@li...=0A> https://lists.sourceforge.net/lists/listinfo= /simpleweb-support=0A>=0A--------------------------------------------------= -----------------------=0ATake Surveys. Earn Cash. Influence the Future of = IT=0AJoin SourceForge.net's Techsay panel and you'll get the chance to shar= e your=0Aopinions on IT & business topics through brief surveys-and earn ca= sh=0Ahttp://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID= =3DDEVDEV=0A_______________________________________________=0ASimpleweb-Sup= port mailing list=0AS...@li...=0Ahttps://lists= .sourceforge.net/lists/listinfo/simpleweb-support=0A=0A=0A=0A=0A=0A =0A____= ___________________________________________________________________________= _____=0AWe won't tell. Get more on shows you hate to love =0A(and love to h= ate): Yahoo! TV's Guilty Pleasures list.=0Ahttp://tv.yahoo.com/collections/= 265 |
From: <sth...@go...> - 2007-03-21 19:54:31
|
SGkgT3NjYXIsCgoyMDA3LzMvMjEsIE9zY2FyIFBlcmV6IDxvc19jYXJwQHRlbGVmb25pY2EubmV0 PjoKPiBIaSwKPiBJIGRvbid0IGhhdmUgYW4gYW5zd2VyIHRvIHlvdSwgYnV0IEkgZmFjZWQgdGhl IHNhbWUgcHJvYmxlbSBqdXN0IGEgd2Vlawo+IGFnbyBhbmQgd2hhdCBJIGRpZCB3YXMgdG8gdHJh Y2sgYWxsIHRoZSBzdGFydGVkIHRocmVhZHMgdG8ga2lsbCB0aGVtIGF0Cj4gc2h1dGRvd24gdGlt ZS4gSSdsbCBub3QgcG9zdCBteSBjb2RlIGhlcmUgbm93LCBidXQgSSdsbCBhZHZpc2UgeW91IHRv Cj4gbm90IGRvIGFzIG1lLCBhcyBJIGxvc3QgYSBsb3Qgb2YgaG91cnMgdHJhY2tpbmcgdGhyZWFk cyBhbmQgZGVidWdnaW5nLi4uCgpUaGFuayB5b3UgZm9yIHRoYXQgOi0pCgo+IE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MtYW5kIGVhcm4gY2FzaAo+IGh0dHA6Ly93d3cudGVjaHNheS5j b20vZGVmYXVsdC5waHA/cGFnZT1qb2luLnBocCZwPXNvdXJjZWZvcmdlJkNJRD1ERVZERVYKPiBf X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fXwo+IFNpbXBsZXdl Yi1TdXBwb3J0IG1haWxpbmcgbGlzdAo+IFNpbXBsZXdlYi1TdXBwb3J0QGxpc3RzLnNvdXJjZWZv cmdlLm5ldAo+IGh0dHBzOi8vbGlzdHMuc291cmNlZm9yZ2UubmV0L2xpc3RzL2xpc3RpbmZvL3Np bXBsZXdlYi1zdXBwb3J0Cj4K |
From: Oscar P. <os...@te...> - 2007-03-21 17:31:56
|
Hi, I don't have an answer to you, but I faced the same problem just a week ago and what I did was to track all the started threads to kill them at shutdown time. I'll not post my code here now, but I'll advise you to not do as me, as I lost a lot of hours tracking threads and debugging... I guess LoaderEngine was not designed to have a clean shutdown? En/na Stefan Hübner ha escrit: > Hi, > > Excuse me, if this has been asked before, but how do I shutdown a > LoaderEngine? Is there a way to do so? > > Cheers, > Stefan > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Simpleweb-Support mailing list > Sim...@li... > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > |
From: <sth...@go...> - 2007-03-21 17:26:20
|
Hi, Excuse me, if this has been asked before, but how do I shutdown a LoaderEngine? Is there a way to do so? Cheers, Stefan |
From: Jeff N. <je...@ne...> - 2007-03-16 13:11:38
|
An update: In the Simple API docs for DomainHandler.handle(Request,Response) it states: "For compatibility with HTTP/1.0 clients that do not support the Host header this delegates the processing of requests without the Host header to a default ProtocolHandler." Depending on how this statement is interpreted, it is not entirely correct, as this method does not look for a 'Host' header unless HTTP/ 1.1 is being used. Well low and behold, the PayPal HTTP/1.0 request seems to include a 'Host' header. So a workaround (for me) seems possible by subclassing DomainHandler and overriding 'handle'. Jeff On Mar 16, 2007, at 1:17 PM, Jeff Nichols wrote: > Hello Niall (and all), > > After a tedious 2 day debugging session, I finally figured out why > PayPal's IPN (Instant Payment Notification) system was not working > with my server. > > I'm using the virtual hosting facilities of Simple (through the > DomainHandler) and PayPal is (for whatever reason) sending their > notifications with HTTP/1.0. This creates a problem, as the > DomainHandler only works with HTTP/1.1 requests (which should include > a 'Host' header). > > Is there any way around this? I thought of writing a specialized > DomainHandler that would fall back to parsing its own 'Host' if none > was available, but I cannot find anywhere in the Request where the > entire URL is available. > > Any help is greatly appreciated. > > Jeff > > ---------------------------------------------------------------------- > --- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to > share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php? > page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Simpleweb-Support mailing list > Sim...@li... > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > |
From: Jeff N. <je...@ne...> - 2007-03-16 12:17:29
|
Hello Niall (and all), After a tedious 2 day debugging session, I finally figured out why PayPal's IPN (Instant Payment Notification) system was not working with my server. I'm using the virtual hosting facilities of Simple (through the DomainHandler) and PayPal is (for whatever reason) sending their notifications with HTTP/1.0. This creates a problem, as the DomainHandler only works with HTTP/1.1 requests (which should include a 'Host' header). Is there any way around this? I thought of writing a specialized DomainHandler that would fall back to parsing its own 'Host' if none was available, but I cannot find anywhere in the Request where the entire URL is available. Any help is greatly appreciated. Jeff |
From: Oscar P. <os...@te...> - 2007-03-12 08:34:41
|
Thanks for your response. Now I'm using PipelineHandler and PipelineFactory as you suggested and performance has grown to a very high level. Now I'm almost sure I'll be able to met project contraints! :-D (I breathe again! :-) ) Oscar En/na Niall Gallagher ha escrit: > Hi Oscar, > > > > Typically I can complete approx 3000 requests per second on a 2GHz > pentium centrino on linux with about 1000 concurrent clients serving an 8k image. It is impossible for me to give you an exact configuration as I do not know how you are measuring response times, what client you are using, or how you are serving your files. I would experiment with the following: > > 1) Remember simple is not a servlet container, at its core it enables asynchronous processing, which makes it very different from a servlet container. This adds an extra requirement, you must always always explicitly close the output stream like so. > > OutputStream out = resp.getOutputStream(); > // your code here > out.close(); // always close when finished > > 2) Test with each response having a "Connection: close" set in the header, like so > > response.set("Connection: close") > > If this improves performance, then you know client requests are intermittent. > > 3) Ensure that your maximum idle time for a connection is low, this means you need to create a PipelineHandler from the PipelineHandlerFactory > > ProtocolHandler proto = new MyProtocolHandler(); > PipelineHandler handler = PipelineHandlerFactory.getInstance(proto, 10, 100) > > This ensures that at most an open connection will be idle for 100ms. This feature will have many improvements in the next release. > > 4) Use buffering output, this ensures that interaction with TCP is good > > PipelineFactory factory = new BufferedPipelineFactory(2086); > Connection connection = ConnectionFactory.getConnection(handler, factory); > > Experimenting with these should provide you with some clues as to why you are getting poor performance. > Niall Gallagher > > ----- Original Message ---- > From: Oscar Perez <os...@te...> > To: Simple support and user issues <sim...@li...> > Sent: Sunday, March 11, 2007 3:09:14 AM > Subject: Re: [Simpleweb-Support] Speed in serving requests > > Hi, > server load will be about 10 to 15 clients (it's a closed system) > issuing continuous requests (basically thumbnails pages) and I need to > have load times of less than 0.5 seconds. By the moment I'm testing with > only one client and the response time is of about 2-3 seconds, so it's > too slow. > I'm serving files by reading them (with a 4kb buffer) and writing to > response's OutputStream directly. But I'm caching files in memory, so > files are only read the first time they are requested. I'll try > FileEngine and test if it improves performance. > > Thank you very much. > > Òscar Pérez > > > En/na Jeff Nichols ha escrit: > >> Hi Oscar, >> >> Where is your performance issue? Raw speed when handling a single >> request, or only under load? >> >> Also, how are you serving those files? Are you reading and writing >> them manually, or are you using the built-in FileEngine? >> >> Jeff >> >> >> On Mar 10, 2007, at 1:18 PM, Oscar Perez wrote: >> >> >> >>> Hi, >>> first of all, I would like to congratulate Simpleweb's creators for >>> their work. Now it's really easy to embbed a web server into an >>> existing >>> Java application. >>> But I've got a question: is there a way to tune performance. I mean, >>> I've implemented a server with just one service. This service simply >>> reads files from the filesystem and returns them to the client. But >>> I'm >>> unable to achieve the required performance and I wonder if I can >>> tune it >>> to be faster. >>> >>> Thanks a lot for your help and congratulations again! >>> >>> Oscar Pérez. >>> >>> ---------------------------------------------------------------------- >>> --- >>> Take Surveys. Earn Cash. Influence the Future of IT >>> Join SourceForge.net's Techsay panel and you'll get the chance to >>> share your >>> opinions on IT & business topics through brief surveys-and earn cash >>> http://www.techsay.com/default.php? >>> page=join.php&p=sourceforge&CID=DEVDEV >>> _______________________________________________ >>> Simpleweb-Support mailing list >>> Sim...@li... >>> https://lists.sourceforge.net/lists/listinfo/simpleweb-support >>> >>> >>> >> ------------------------------------------------------------------------- >> Take Surveys. Earn Cash. Influence the Future of IT >> Join SourceForge.net's Techsay panel and you'll get the chance to share your >> opinions on IT & business topics through brief surveys-and earn cash >> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV >> _______________________________________________ >> Simpleweb-Support mailing list >> Sim...@li... >> https://lists.sourceforge.net/lists/listinfo/simpleweb-support >> >> >> > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Simpleweb-Support mailing list > Sim...@li... > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > ____________________________________________________________________________________ > Be a PS3 game guru. > Get your game face on with the latest PS3 news and previews at Yahoo! Games. > http://videogames.yahoo.com/platform?platform=120121 > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Simpleweb-Support mailing list > Sim...@li... > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > |
From: Niall G. <gal...@ya...> - 2007-03-11 13:54:49
|
Hi Oscar,=0A=0A=0A=0ATypically I can complete approx 3000 requests per seco= nd on a 2GHz=0Apentium centrino on linux with about 1000 concurrent clients= serving an 8k image. It is impossible for me to give you an exact configur= ation as I do not know how you are measuring response times, what client yo= u are using, or how you are serving your files. I would experiment with the= following:=0A=0A1) Remember simple is not a servlet container, at its core= it enables asynchronous processing, which makes it very different from a s= ervlet container. This adds an extra requirement, you must always always ex= plicitly close the output stream like so.=0A=0AOutputStream out =3D resp.ge= tOutputStream();=0A// your code here=0Aout.close(); // always close when fi= nished=0A=0A2) Test with each response having a "Connection: close" set in = the header, like so=0A=0Aresponse.set("Connection: close")=0A=0AIf this imp= roves performance, then you know client requests are intermittent.=0A=0A3) = Ensure that your maximum idle time for a connection is low, this means you = need to create a PipelineHandler from the PipelineHandlerFactory=0A=0AProto= colHandler proto =3D new MyProtocolHandler();=0APipelineHandler handler =3D= PipelineHandlerFactory.getInstance(proto, 10, 100)=0A=0AThis ensures that = at most an open connection will be idle for 100ms. This feature will have m= any improvements in the next release.=0A=0A4) Use buffering output, this en= sures that interaction with TCP is good=0A=0APipelineFactory factory =3D ne= w BufferedPipelineFactory(2086);=0AConnection connection =3D ConnectionFact= ory.getConnection(handler, factory);=0A=0AExperimenting with these should p= rovide you with some clues as to why you are getting poor performance. =0A= Niall Gallagher=0A=0A----- Original Message ----=0AFrom: Oscar Perez <os_ca= rp...@te...>=0ATo: Simple support and user issues <simpleweb-support@= lists.sourceforge.net>=0ASent: Sunday, March 11, 2007 3:09:14 AM=0ASubject:= Re: [Simpleweb-Support] Speed in serving requests=0A=0AHi,=0Aserver load w= ill be about 10 to 15 clients (it's a closed system) =0Aissuing continuous = requests (basically thumbnails pages) and I need to =0Ahave load times of l= ess than 0.5 seconds. By the moment I'm testing with =0Aonly one client and= the response time is of about 2-3 seconds, so it's =0Atoo slow.=0AI'm serv= ing files by reading them (with a 4kb buffer) and writing to =0Aresponse's = OutputStream directly. But I'm caching files in memory, so =0Afiles are onl= y read the first time they are requested. I'll try =0AFileEngine and test i= f it improves performance.=0A=0AThank you very much.=0A=0A=D2scar P=E9rez= =0A=0A=0AEn/na Jeff Nichols ha escrit:=0A> Hi Oscar,=0A>=0A> Where is your = performance issue? Raw speed when handling a single =0A> request, or only= under load?=0A>=0A> Also, how are you serving those files? Are you readin= g and writing =0A> them manually, or are you using the built-in FileEngine= ?=0A>=0A> Jeff=0A>=0A>=0A> On Mar 10, 2007, at 1:18 PM, Oscar Perez wrote:= =0A>=0A> =0A>> Hi,=0A>> first of all, I would like to congratulate Simple= web's creators for=0A>> their work. Now it's really easy to embbed a web se= rver into an =0A>> existing=0A>> Java application.=0A>> But I've got a que= stion: is there a way to tune performance. I mean,=0A>> I've implemented a = server with just one service. This service simply=0A>> reads files from the= filesystem and returns them to the client. But =0A>> I'm=0A>> unable to a= chieve the required performance and I wonder if I can =0A>> tune it=0A>> t= o be faster.=0A>>=0A>> Thanks a lot for your help and congratulations again= !=0A>>=0A>> Oscar P=E9rez.=0A>>=0A>> --------------------------------------= -------------------------------- =0A>> ---=0A>> Take Surveys. Earn Cash. In= fluence the Future of IT=0A>> Join SourceForge.net's Techsay panel and you'= ll get the chance to =0A>> share your=0A>> opinions on IT & business topic= s through brief surveys-and earn cash=0A>> http://www.techsay.com/default.p= hp? =0A>> page=3Djoin.php&p=3Dsourceforge&CID=3DDEVDEV=0A>> _______________= ________________________________=0A>> Simpleweb-Support mailing list=0A>> S= imp...@li...=0A>> https://lists.sourceforge.net/l= ists/listinfo/simpleweb-support=0A>>=0A>> =0A>=0A>=0A> ----------------= ---------------------------------------------------------=0A> Take Surveys.= Earn Cash. Influence the Future of IT=0A> Join SourceForge.net's Techsay p= anel and you'll get the chance to share your=0A> opinions on IT & business = topics through brief surveys-and earn cash=0A> http://www.techsay.com/defau= lt.php?page=3Djoin.php&p=3Dsourceforge&CID=3DDEVDEV=0A> ___________________= ____________________________=0A> Simpleweb-Support mailing list=0A> Simplew= eb-...@li...=0A> https://lists.sourceforge.net/lists/li= stinfo/simpleweb-support=0A>=0A> =0A=0A=0A-------------------------------= ------------------------------------------=0ATake Surveys. Earn Cash. Influ= ence the Future of IT=0AJoin SourceForge.net's Techsay panel and you'll get= the chance to share your=0Aopinions on IT & business topics through brief = surveys-and earn cash=0Ahttp://www.techsay.com/default.php?page=3Djoin.php&= p=3Dsourceforge&CID=3DDEVDEV=0A____________________________________________= ___=0ASimpleweb-Support mailing list=0AS...@li...urceforge.= net=0Ahttps://lists.sourceforge.net/lists/listinfo/simpleweb-support=0A=0A= =0A=0A=0A=0A =0A___________________________________________________________= _________________________=0ABe a PS3 game guru.=0AGet your game face on wit= h the latest PS3 news and previews at Yahoo! Games.=0Ahttp://videogames.yah= oo.com/platform?platform=3D120121 |
From: Oscar P. <os...@te...> - 2007-03-11 10:16:54
|
Hi Niall, 1) I'm not sure... I'm new to simpleweb and I don't know what you're asking about pipelines... but I guess I'm using connection close, because I did not use any class or method with a name similar to "*Pipeline*". 2) file lengths differ. I'm serving some HTML pages of about 3kb and some images of about 100kb. But I guess in the future I'll have to serve images up to 300-400 Kb. 3) I don't need to serve high concurrency. As I said in a previous mail, I'll have about a dozen clients making requests continuously, so for me it's more important to handle one request very fast than a lot of requests slowly. Thanks for your help. Òscar En/na Niall Gallagher ha escrit: > Hi Oscar, > > There are several ways to tune the performance. Depending on your requirements, in order tune it I would need to know: > > 1) Are you using pipelines or connection close? > 2) How large are the files you are serving? > 3) What kind of concurrency do you need to serve? > > By default the server is configured to deal with high concurrency, as a result responsiveness may not be optimal. > > Niall Gallagher > > ----- Original Message ---- > From: Oscar Perez <os...@te...> > To: sim...@li... > Sent: Saturday, March 10, 2007 4:18:04 AM > Subject: [Simpleweb-Support] Speed in serving requests > > Hi, > first of all, I would like to congratulate Simpleweb's creators for > their work. Now it's really easy to embbed a web server into an existing > Java application. > But I've got a question: is there a way to tune performance. I mean, > I've implemented a server with just one service. This service simply > reads files from the filesystem and returns them to the client. But I'm > unable to achieve the required performance and I wonder if I can tune it > to be faster. > > Thanks a lot for your help and congratulations again! > > Oscar Pérez. > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Simpleweb-Support mailing list > Sim...@li... > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > > > > > ____________________________________________________________________________________ > Need Mail bonding? > Go to the Yahoo! Mail Q&A for great tips from Yahoo! Answers users. > http://answers.yahoo.com/dir/?link=list&sid=396546091 > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Simpleweb-Support mailing list > Sim...@li... > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > |