Download Building Web Applications with Erlang: Working with REST and by Zachary Kessin PDF

By Zachary Kessin

Why decide upon Erlang for internet functions? detect the reply hands-on by means of construction an easy net carrier with this e-book. If you’re an skilled internet developer who understands simple Erlang, you’ll the right way to paintings with relaxation, dynamic content material, internet sockets, and concurrency via numerous examples. within the strategy, you’ll see first-hand that Erlang is perfect for development business-critical services.

Erlang used to be designed for fault-tolerant, continuous telecom structures, and construction functions with it calls for a wide set of abilities. by way of the top of the ebook, you’ll have the data you want to construct a uncomplicated net provider and get it running.
* discover the ability of Erlang and relaxation for construction internet prone
* Serve static and dynamic content material with the Yaws net server
* Use diversified equipment for outputting info to person, corresponding to encoding Erlang facts buildings into JSON or XML
* construct an software to hear for HTTP requests, technique them, shop info, and go back priceless info
* transcend the request-response model—push information to consumers with internet sockets
* Use Erlang and Yaws to move facts from the server to a consumer

"A publication that's really wanted and may support get Erlang to the following level."

—Francesco Cesarini, CEO of Erlang ideas, writer of Erlang Programming.

Show description

Read or Download Building Web Applications with Erlang: Working with REST and Web Sockets on Yaws PDF

Best programming books

Pro Design Patterns in Swift

The quick programming language has remodeled the realm of iOS improvement and commenced a brand new age of contemporary improvement. seasoned layout styles in quick indicates you ways to harness the facility and adaptability of speedy to use an important and enduring layout styles in your purposes, taking your improvement tasks to grasp point.

Multi-objective Group Decision Making: Methods, Software and Applications With Fuzzy Set Techniques

This publication proposes a collection of types to explain fuzzy multi-objective determination making (MODM), fuzzy multi-criteria determination making (MCDM), fuzzy team determination making (GDM) and fuzzy multi-objective staff decision-making difficulties, respectively. It additionally provides a suite of similar equipment (including algorithms) to unravel those difficulties.

Principles and Practice of Constraint Programming - CP 2005: 11th International Conference, CP 2005, Sitges, Spain, October 1-5, 2005. Proceedings

This e-book constitutes the refereed court cases of the eleventh foreign convention on rules and perform of Constraint Programming, CP 2005, held in Sitges, Spain, in October 2005. The forty eight revised complete papers and 22 revised brief papers awarded including prolonged abstracts of four invited talks and forty abstracts of contributions to the doctoral scholars application in addition to 7 abstracts of contributions to a platforms demonstration consultation have been rigorously reviewed and chosen from 164 submissions.

Integer Programming and Combinatorial Optimization: 7th International IPCO Conference Graz, Austria, June 9–11, 1999 Proceedings

This ebook constitutes the refereed complaints of the seventh overseas convention on Integer Programming and Combinatorial Optimization, IPCO'99, held in Graz, Austria, in June 1999. The 33 revised complete papers awarded have been rigorously reviewed and chosen from a complete of ninety nine submissions. one of the subject matters addressed are theoretical, computational, and application-oriented features of approximation algorithms, department and certain algorithms, computational biology, computational complexity, computational geometry, slicing aircraft algorithms, diaphantine equations, geometry of numbers, graph and community algorithms, on-line algorithms, polyhedral combinatorics, scheduling, and semidefinite courses.

Additional info for Building Web Applications with Erlang: Working with REST and Web Sockets on Yaws

Example text

If a cookie is not set, this function will return empty HTML. Example 3-4. cookie, Prefs = yaws_api:find_cookie_val("Prefs", Cookie), {html, Prefs}. Yaws also includes a set of interfaces to create session tracking with cookies (see “Session Handling” on page 36). Session Handling Yaws provides a nice API for handling sessions with cookies with the yaws_api:new_cookie_session/1-3 functions. The basic function new_cookie_session/ 1 takes a state record that can be specified by the application.

The most basic form is template:render/1, which will return {ok, Content} or {error, Error}. There is also a template:render/2 version that allows some customization of the template function. It is possible to pass a locale, a translation function that will work on {% trans %} tags. For a full list of options, see the ErlyDTL web page. beam file with standard functions for the templates that can be used just like any other functions. Django templates put symbols in double bracket escaping, as in Example 2-17.

Erlang file, which Yaws will read when it first starts up. This file should contain valid Erlang code and should live in the user’s home directory. When Yaws is started it will print out a few lines of information that look similar to Example 2-1 and then drop into the Erlang REPL. At this point Yaws is fully functional and will serve any requests that you send it. It may take a second or two from when you start the Yaws executable to when it is ready to serve content to users. By default, Yaws will be set up to listen on port 8000 (Example 2-1 changes it to 8081 due to something else using that port).

Download PDF sample

Rated 4.13 of 5 – based on 3 votes