-->
Home » » Yaws is a HTTP high perfomance 1.1 webserver particularly well suited for dynamic-content webapplications
Tuesday
26 January 2010

Yaws is a HTTP high perfomance 1.1 webserver particularly well suited for dynamic-content webapplications

Yaws (Yet another web server) is a web server written in Erlang by Claes (klacke) Wikström.

Yaws can be embedded into other Erlang-based applications or run as a regular standalone web server.

Because Yaws uses Erlang's lightweight threading system, it performs well under high concurrency.

A load test conducted in 2002 comparing Yaws and Apache found that with the hardware tested, Apache 2.0.39 with the worker MPM failed at 4,000 concurrent connections, while Yaws continued functioning with over 80,000 concurrent connections.

Last stable relase: 1.87 (2010-01-05)

Two separate modes of operations are supported.

* Standalone mode where Yaws runs as a regular webserver daemon. This is the default mode.
* Embedded mode where Yaws runs as an embedded webserver in another erlang application.

Updates:

* websocket support (davide and wde)
* conditional compile of websockets, only use if the chosen erl supports it (klacke/steve)
* patch by Andrei Soroker to strip the port part in #redir_self records - this patch may break some code, users that use redir_self() and unconditionally strip off their optional port number are affected
* support some extra status codes in code_to_phrase (steve)
* drop spaces before parsing ints - patch by Colm Dougan
* proper handling of "/" appmod with excluded paths (patch from wde)
* Added new unit tests for appmods, with both / and non-/ tests. The / tests include exclude_paths testing. (steve)
* patch from wde solving a problem with appmod exclude paths and verify_upgrade
* yaws_server: fixed the test for whether to close the socket. The yaws:outh_get_doclose() doesn't return a boolean and it requires the outh dicionary entry to be set (sometimes it isn't). (davide)
* do not pass the --id option if the default id is used (steve)

Download.

Get Chitika | Premium



Let us not forget the famous comparison between Yaws and Apache. In a denial of service attack, the number of parallel connections needed to crash the Erlang web server was about 20 times as many as an Apache web server running on the same hardware. Apache (blue and green) dies when subject to a load of concurrent 4,000 parallel requests. Yaws (red) works till 80,000 concurrent requests.


I will try to give you a simple example about how to create a simple dynamic web page with Yaws.

This a simple Hello world to Yaws.

<html>
<h1> Title</h1>
<erl>
out(Arg) -> {html, “Hello World"}.
</erl>
<h1> Something</h1>
</html>

Thanks to Yariv Sadan’s effort to involve Erlang in the web development community using ErlyWeb which is a web framework that helps you easily build database-driven applications using the MVC architecture. It's similar to Ruby on Rails, except that it's written in Erlang. There is also ErlyDB a database abstraction layer generator. ErlyDB taps into Erlang’s runtime metaprogramming powers to generate an abstraction layer for your database on the fly.


Adserver 610x250


I am going to propose an architecture for web development using Erlang. It will consists of five layers:

* Hardware/ Operating System: This layer represents the physical layer of the system. It can be a Linux system running on a network file system(NFS) to make use of the concurrency and distribution features in Erlang.
* DBMS: This layer represents the persistence layer of the system. It can be either Mnesia or MySQL.
* Data Base Abstraction Layer.
* Erlang/Open Telecom Platform: It is the standard libraries of the Erlang language.
* Presentation Layer: This layer consists of two components. Yaws as a web server and ErlyWeb as rapid development framework.


If you liked this article, subscribe to the feed by clicking the image below to keep informed about new contents of the blog:

Related Post

Linux Links

0 commenti:

Post a Comment

Random Posts

  • Antiprism is a set of programs for generating, manipulating, transforming and visualising polyhedra.
    03.03.2012 - 0 Comments
    Antiprism project is a suite of programs for the generation, manipulation, and visualisation of polyhedra. Make a cubeThis can be done with unipoly, which can be used to make all the uniform polyhedra. unipoly cube > cube.off Display withoff2pov…
  • Apache incubator Project: Projects Graduated from Incubation.
    11.02.2013 - 0 Comments
    Apache Incubator is the gateway for open-source projects intended to become fully fledged Apache Software Foundation projects. The Incubator project was created in October 2002 to provide an entry path to the Apache Software Foundation for projects…
  • Improve your French and Italian languages' skills with Verbiste, versatile verb conjugation utility.
    30.12.2012 - 0 Comments
    Verbiste is a French conjugation system. It contains a C++ library, two programs that can be run from the command line or from another program, and a GNOME application. This application shows a text field in the GNOME Panel where the user can enter…
  • Aumix adjusts an audio mixer from X, the console, a terminal, the command line or a script.
    16.09.2012 - 0 Comments
    Aumix adjusts an audio mixer from X11, the console, a terminal, the command line or a script. It uses the Open Sound System API and works on OpenBSD, NetBSD, FreeBSD, and Linux. aumix 2.9.1 Version 2.9.1 was released 6 May 2010. Thanks to…
  • Selective Colorization using The GIMP.
    03.05.2013 - 0 Comments
    In this tutorial I will explain how to convert a color photograph to a B&W one with color restored to selective areas. With the right subject this can give really striking results, as you can see for yourself. This technique is elsewhere…
  • Released the new version of 4MLinux 29.0 minimalist and lightweight distribution.
    11.06.2019 - 2 Comments
    4MLinux is a lightweight distribution made for both the 32 bit and 64 bit architectures. It is named "4MLinux" since it has 4 main components of the OS. Maintenance (it can be used a rescue Live CD), Multimedia (There is inbuilt support for almost…
  • Unity Linux is a Mandriva-based minimalist distribution with the Openbox window manager
    14.12.2009 - 0 Comments
    Unity Linux is a Mandriva-based minimalist distribution with the Openbox window manager and Smart advanced package management tool.The project's main goal is to provide a core operating system upon which more complete solutions can be built.The…
  • Gentoo Linux, Based on the Portage Management System
    04.02.2008 - 1 Comments
    The Gentoo Linux operating system is a Linux distribution based on the Portage package management system. The development project and its products are named after the Gentoo penguin. Gentoo package management is designed to be modular, portable,…
  • EvilEntity, a distro for the desktop-not a server
    22.09.2009 - 0 Comments
    EvilEntity Linux is a i686 based multimedia-focused desktop OS designed for desktop home computers and professional multimedia productivity. It provides the Linux user with a Linux system optimized for audio, video, and desktop work. Download …
  • Linux Compared with DOS/Windows
    24.07.2009 - 0 Comments
    So you've heard about Linux, and now you're thinking, I wonder if it's the answer to the problems I've been having with Windows? The good news is that there's a clear and unequivocal answer: Maybe. Linux will appeal to you if: You are the type…

Recent Posts

Recent Posts Widget

Popular Posts

Labels

Archive

page counter follow us in feedly
 
Copyright © 2014 Linuxlandit & The Conqueror Penguin
-->