Re: [Simpleweb-Support] Unable to get scheme/port/domain from incoming Request
Brought to you by:
niallg
From: Niall G. <gal...@ya...> - 2012-11-10 13:29:31
|
Also just an FYI, Ill be releasing Simple HTTP 5.0 within a week or two, although its pretty much the same, there are some noticeable differences that may break existing code written on the 4.x versions. --- On Sat, 10/11/12, Niall Gallagher <gal...@ya...> wrote: > From: Niall Gallagher <gal...@ya...> > Subject: Re: [Simpleweb-Support] Unable to get scheme/port/domain from incoming Request > To: "Simple support and user issues" <sim...@li...> > Received: Saturday, 10 November, 2012, 5:25 AM > You have to get it from the "Host" > header, its required for HTTP/1.1 however HTTP/1.0 requests > might not have it. Just do Request.get("Host"). > > --- On Sat, 10/11/12, Tom Denley <t.d...@ca...> > wrote: > > > From: Tom Denley <t.d...@ca...> > > Subject: [Simpleweb-Support] Unable to get > scheme/port/domain from incoming Request > > To: sim...@li... > > Received: Saturday, 10 November, 2012, 2:43 AM > > Hi, > > > > I'm trying to develop a Clojure ring adapter for > Simple, > > and I'm having trouble determining the http scheme, > > server hostname, and server port for incoming Simple > > Requests. > > > > I find that each of the following returns null: > > > > > > request.getAddress().getScheme() > > request.getAddress().getDomain() > > request.getAddress().getPort() > > > > I'd appreciate any advice. > > > > If you are able to read Clojure code, and think it > might > > help, then my source is on GitHub here: > > > > > > https://github.com/netmelody/ring-simpleweb-adapter/blob/master/src/ring/adapter/simpleweb.clj > > > > Regards, > > > > Tom Denley > > > > > > -----Inline Attachment Follows----- > > > > > ------------------------------------------------------------------------------ > > Everyone hates slow websites. So do we. > > Make your web apps faster with AppDynamics > > Download AppDynamics Lite for free today: > > http://p.sf.net/sfu/appdyn_d2d_nov > > -----Inline Attachment Follows----- > > > > _______________________________________________ > > Simpleweb-Support mailing list > > Sim...@li... > > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > > > > ------------------------------------------------------------------------------ > Everyone hates slow websites. So do we. > Make your web apps faster with AppDynamics > Download AppDynamics Lite for free today: > http://p.sf.net/sfu/appdyn_d2d_nov > _______________________________________________ > Simpleweb-Support mailing list > Sim...@li... > https://lists.sourceforge.net/lists/listinfo/simpleweb-support > |