www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.announce - Opensourced my web server written in D

reply "Danny Arends" <Danny.Arends gmail.com> writes:
I wrote a small web server in D to learn the language.
It's not done yet (what software ever is) but I wanted to show it 
off anyway. As always of-course any feedback is welcome

See it here: https://github.com/DannyArends/DaNode

Gr,
Danny Arends
http://www.dannyarends.nl
Feb 03 2014
next sibling parent reply Rory McGuire <rjmcguire gmail.com> writes:
Interesting, are you using any event libraries or did you roll your own?


On Mon, Feb 3, 2014 at 12:02 PM, Danny Arends <Danny.Arends gmail.com>wrote:

 I wrote a small web server in D to learn the language.
 It's not done yet (what software ever is) but I wanted to show it off
 anyway. As always of-course any feedback is welcome

 See it here: https://github.com/DannyArends/DaNode

 Gr,
 Danny Arends
 http://www.dannyarends.nl
Feb 03 2014
parent "Danny Arends" <Danny.Arends gmail.com> writes:
Rolled my own, It's purely to learn the language, but it has been 
tested by running my own website for almost 6 months now.

The only dependency is Deimos & openSSL for the HTTPS 
connections. which are still untested and kind of unstable

Gr,
Danny


On Monday, 3 February 2014 at 14:17:22 UTC, Rory McGuire wrote:
 Interesting, are you using any event libraries or did you roll 
 your own?


 On Mon, Feb 3, 2014 at 12:02 PM, Danny Arends 
 <Danny.Arends gmail.com>wrote:

 I wrote a small web server in D to learn the language.
 It's not done yet (what software ever is) but I wanted to show 
 it off
 anyway. As always of-course any feedback is welcome

 See it here: https://github.com/DannyArends/DaNode

 Gr,
 Danny Arends
 http://www.dannyarends.nl
Feb 03 2014
prev sibling next sibling parent reply Andrei Alexandrescu <SeeWebsiteForEmail erdani.org> writes:
On 2/3/14, 2:02 AM, Danny Arends wrote:
 I wrote a small web server in D to learn the language.
 It's not done yet (what software ever is) but I wanted to show it off
 anyway. As always of-course any feedback is welcome

 See it here: https://github.com/DannyArends/DaNode

 Gr,
 Danny Arends
 http://www.dannyarends.nl
Vote up! http://www.reddit.com/r/programming/comments/1x0625/small_opensource_web_server_written_in_d/ Andrei
Feb 04 2014
parent "Danny Arends" <Danny.Arends gmail.com> writes:
Thanks for posting,

I just posted it here because I mentioned I wrote it to someone 
who then wanted a look. So why not open it up for everyone. But 
the whole reddit attention already got me 10 stars ! yay !

I am planning on making a blog post series out of it describing 
the components, there is a little write up already in the DDOC of 
the files (I love DDOC), to generate run:

./sh/doc

Then the documentation will be at: http://localhost/ddoc
or just: cd www/localhost/ddoc

Anywayz will keep you guys posted.
Danny Arends

On Tuesday, 4 February 2014 at 18:21:32 UTC, Andrei Alexandrescu 
wrote:
 On 2/3/14, 2:02 AM, Danny Arends wrote:
 I wrote a small web server in D to learn the language.
 It's not done yet (what software ever is) but I wanted to show 
 it off
 anyway. As always of-course any feedback is welcome

 See it here: https://github.com/DannyArends/DaNode

 Gr,
 Danny Arends
 http://www.dannyarends.nl
Vote up! http://www.reddit.com/r/programming/comments/1x0625/small_opensource_web_server_written_in_d/ Andrei
Feb 04 2014
prev sibling parent reply Martin Nowak <code dawg.eu> writes:
On 02/03/2014 11:02 AM, Danny Arends wrote:
 I wrote a small web server in D to learn the language.
 It's not done yet (what software ever is) but I wanted to show it off
 anyway. As always of-course any feedback is welcome

 See it here: https://github.com/DannyArends/DaNode

 Gr,
 Danny Arends
 http://www.dannyarends.nl
Sorry to read that a compiler update broke your code. http://www.reddit.com/r/programming/comments/1x0625/small_opensource_web_server_written_in_d/cf8ftqv It would be interesting to get some more feedback for this. What was the old and the new version? Do you remember what broke? Thanks, Martin
Feb 07 2014
parent reply "Danny Arends" <Danny.Arends gmail.com> writes:
It was related to the update of std.process,

I was using the 'bad way' just building a string and then
executing it. Using the old API I could just get back the stdout 
and stderr
as strings. And when the new API came in
the old version got deprecated or something else I don't know
exactly, it broke the execution of external code but the original
code was bad code anyway.

The new API is much cleaner and I now use the spawnShell command,
which allows to use pipes. This means the server can read data in
nice chunks, and that I could tweak the throughput/chunksize
based on the amount accepted by a client.

I could look up in the old repository when/where. but in general
I dont mind a little breakage because in general bad code breaks..

Gr,
Danny Arends
http://www.dannyarends.nl


On Friday, 7 February 2014 at 17:06:58 UTC, Martin Nowak wrote:
 On 02/03/2014 11:02 AM, Danny Arends wrote:
 I wrote a small web server in D to learn the language.
 It's not done yet (what software ever is) but I wanted to show 
 it off
 anyway. As always of-course any feedback is welcome

 See it here: https://github.com/DannyArends/DaNode

 Gr,
 Danny Arends
 http://www.dannyarends.nl
Sorry to read that a compiler update broke your code. http://www.reddit.com/r/programming/comments/1x0625/small_opensource_web_server_written_in_d/cf8ftqv It would be interesting to get some more feedback for this. What was the old and the new version? Do you remember what broke? Thanks, Martin
Feb 09 2014
parent Martin Nowak <code dawg.eu> writes:
On 02/09/2014 07:18 PM, Danny Arends wrote:
 It was related to the update of std.process,

 The new API is much cleaner and I now use the spawnShell command,
 which allows to use pipes. This means the server can read data in
 nice chunks, and that I could tweak the throughput/chunksize
 based on the amount accepted by a client.
Interesting. I agree, the new std.process is so much better, that I didn't mind a few rewrites myself.
Feb 09 2014