Programming MapReduce with Scalding – Using Hadoop & Scala to do some Big Data – #programming #bookreview

Programming MapReduce with Scalding

Programming MapReduce with Scalding

A practical guide to designing, testing, and implementing complex MapReduce applications in Scala

Antonios Chalkiopoulos

(Packt Publishing - paperback, Kindle)

 

Antonio Chalkiopoulos’s new book has three key goals, and it meets each of them in good, readable fashion.

It describes how MapReduce, Hadoop, and Scalding can work together. It suggests some useful design patterns and idioms. And, it provides numerous code examples of “real implementations for common use cases.”

The book also briefly introduces the Scala programming language and the Cascading platform, two elements vital to the Scalding framework.

Right here, a few brief definitions need to be offered.

According to a Wikipedia definition, MapReduce is both a programming model and “an associated implementation for processing and generating large data sets with a parallel, distributed algorithm on a cluster.”

Meanwhile, the Apache Hadoop website states: “Hadoop MapReduce is a software framework for easily writing applications which process vast amounts of data (multi-terabyte data-sets) in-parallel on large clusters (thousands of nodes) of commodity hardware in a reliable, fault-tolerant manner.”

And: “The Hadoop Distributed File System (HDFS) is a distributed file system designed to run on commodity hardware” and “is highly fault-tolerant….”

Continuing, the Cascading.org website promotes Cascading as “the proven application development platform for building data applications on Hadoop.” Plus, Scalding, it explains, is  “an extension to Cascading that enables application development with Scala, a powerful language for solving functional problems.” Indeed, Scalding is “[a] Scala API for Cascading,” and it provides functionality from custom join algorithms to multiple APIs (Fields-based, Type-safe, Matrix) for developers to build robust data applications. Scalding is built and maintained by Twitter.”

Scalding “makes MapReduce computations look very similar to Scala’s collection API. It’s also a wrapper for Cascading to simplify jobs, tests and data sources on HDFS or local disk.”

Okay, that’s a lot to digest, especially if you are making some of your first forays into the world of Big Data.

Fortunately, Programming MapReduce with Scalding offers clear, well-illustrated, smoothly paced how-to steps, as well as easy-to-digest definitions and descriptions. It takes the reader from setting up and running a Hadoop mini-cluster and local-development environment to applying  Scalding to real-use cases, as well as developing good test and test-driven development methodologies, running Scalding in production, using external data stores, and applying matrix calculations and machine learning.

The book is written for developers who have “a basic understanding” of Hadoop and MapReduce, but is also intended for experienced Hadoop developers who may be “enlightened by this alternative methodology of developing MapReduce applications with Scalding.”

In this book, “[a] Linux operating system is the preferred environment for Hadoop.” And the author includes instructions for how to install and use a Kiji Bento Box, “a zero-configuration bundle that provides a suitable environment for testing and prototyping projects that use HDFS, MapReduce, and HBase with minimal setup time.”  It’s an easy way to get Apache Hadoop up and running in as little as five minutes or so.

Or, if you prefer, you can manually install the required software packages. Either way, you can learn a lot and do a lot with a Hadoop mini-cluster. And, with this book, you can get a very good handle on the Scalding API.

It does help to be somewhat familiar with MapReduce, Scalding, Scala, Hadoop, Maven, Eclipse and the Linux environment.  But Antonio Chalkiopoulo does a good job of keeping the examples accessible even when readers are new to some of the packages. Still, be prepared to take your time and be prepared to do some additional research on the web and ask questions in forums, particularly if any of the required software is new to you.

(The book also can be purchased direct from Packt Publishing at http://goo.gl/Tyw4Sh.)

 

Si Dunn

 

 

 

 

No Stone Unturned and Styx & Stone – An entertaining, engrossing mystery series – #bookreview

No Stone_cover

No Stone Unturned

An Ellie Stone Mystery

James W. Ziskin

(Seventh Street Books - paperback, Kindle)

***

 Styx & Stone

An Ellie Stone Mystery

James W. Ziskin

(Seventh Street Books - paperback, Kindle)

***

 Looking for a new mystery series and investigator to follow? Check out these two engrossing, entertaining novels from James W. Ziskin and Seventh Street Books.

Set in 1960, Styx & Stone, the series debut, and the recently published No Stone Unturned focus on Ellie Stone, a young reporter and photographer working for a small-town newspaper in Upstate New York. She’s struggling to hang onto her first professional job after graduating from the prestigious Columbia Journalism School.

It is a time well before women’s liberation, so Ellie is fighting both to stay afloat and advance  in a career that is still “a man’s world.” Yet, despite the nerve-wracking challenges and the men who fall over themselves as they try to get her into bed, she is glad to have work that doesn’t simply involve “shorthand and fetching coffee.”

Still, Ellie is tired of writing filler copy. She wants to get her hands on some real stories for a change. But she is competing in a male-dominated business and in a male-dominated town where everyone essentially knows everyone else. Thus, everything she does or says is scrutinized and subject to criticism by someone. And she sometimes has a tough time figuring out who really wants to help her and who is just trying to score enough points to make out with her.

Intrepidly, she pushes ahead. And she has a trait born of bravado and curiosity, as well as desperation to keep her job. She is not afraid to confront people and ask questions that others, including the police, have not thought of–or, more dangerously, have not wished to ask.

In Styx & Stone, Ellie leaves Upstate New York long enough to go back home to New York City after her estranged father, a famous Dante scholar and professor, is savagely beaten. The police think he was attacked by burglars, but Ellie is convinced it was a murder attempt and starts asking questions. Soon, another professor is killed, and a second attempt is made on Ellie’s father’s life. Later, he dies of his injuries.

Ellie is so thorough, demanding and even brazen in her probings that, at one point, Detective-Sergeant Jimmo McKeever of the NYPD, complains:  “Are you planning to solve every crime in New York during your stay?” Yet later, while helping her solve the murders,  he concedes a bit awkwardly: “If you were a man, you’d make a good detective.”

Meanwhile, in No Stone Unturned, Ellie is back in Upstate New York, at her newspaper job in the community of New Holland. She is wanting to prove to her boss and her fellow employes that she is a good journalist.

She intends to write  the main, front-page story about a newly discovered murder. But to beat the newspaper’s veteran (and male) crime reporter to the task, she must also solve the murder–quickly.

That means taking dangerous risks and hurriedly confronting powerful people in the community with sharp questions that create more enemies than friends. Along the way, she also must defend herself from being fired from her job. And she must find the inner courage to stick with her fledgling–though currently floundering–newspaper career.

James W. Ziskin’s Ellie Stone is an engaging, intelligent and ambitious young woman who knows both how to fight crime and how to fight her way through many of the historical, social and economic barriers that again restricted American women’s freedoms after World War II.

Si Dunn

Muerte en una estrella – Shooting Star: An excellent, disturbing novel in first English translation – #fiction #bookreview

 

 Muerte-en-una-estrella-350x550

Muerte en Una Estrella – Shooting Star

Sergio D. Elizondo

English Translation by Rosaura Sánchez and Beatriz Pita

(Arte Público Presspaperback)

Available for the first time in English, this excellent and troubling bilingual novel imagines the dying thoughts of two Mexican youths after they were shot by Austin police in March, 1968, apparently while running away from a shouted order to “Halt!”

Originally published in 1984, the novel is a eulogy for Oscar Balboa, 16, and Valentín Rodriguez, 19, who were both unarmed and on leave from Camp Gary, a Job Corps training facility near San Marcos, Texas.

Their deaths occurred during a nationally troubled time that was rife with bigotry and racial discrimination. And Shooting Star gives some important insights into efforts and actions by the Chicano civil rights movement during that time period.

In the novel’s English translation, Oscar Balboa and  Valentín Rodriguez are described as “strutting icons of Raza manhood worthy of a guitar ballad.” And after they are shot, their dying thoughts cover a wide and often moving range of memories, thoughts and impressions. As one example, Oscar remembers coming north from Mexico to work in the fields, and he remembers taking part in farm worker protest marches with his father. Meanwhile, Valentín is not really sure if he has been shot or not, but he knows he cannot move, nor make Oscar hear him. And he feels what he thinks is dew on his back as he recalls some of his own life and his brief time with Oscar.

Shooting Star definitely is worthy of its praise as “a classic” in Mexican-American literature. This excellent first English translation will introduce the author and the book and its insights to many more readers.

Si Dunn

 

The Valley – Estampas del valle: Now in bilingual paperback for the first time – #bookreview

The-Valley-350x550

The Valley / Estampas del valle

Rolando Hinojosa

(Arte Público Press - paperback)

The long-turbulent Texas-Mexico border is in the news once again. So this is a timely moment to introduce or reintroduce readers to the famed Klail City Death Trip Series, fifteen books written by Rolando Hinojosa. The series is in a mythical Texas county on America’s southern frontier, in the Lower Rio Grande Valley.

The first book in that series, The Valley, introduces readers to life in Belken County, where Anglo Texans and Mexican Texans live side by side, and people die, or encounter death, on nearly every page. Their stories of everyday events, including love, weddings, births, friendships, affairs, discrimination and dying, are told mostly in short, well-written vignettes that cover the time period generally from World War I to 1970.

Arte Público Press recently has published the first bilingual, English-Spanish edition of The Valley, which initially appeared as Estampas del Valle in the early 1970s. And this is a noteworthy literary event for fans of both Hispanic literature and American literature in general.

Rolando Hinojosa’s fictional Belken County has been compared very favorably with William Faulkner’s Yoknapatawpha County and with Gabriel García Márquez’s fictional city, Macondo, in One Hundred Years of Solitude. Klail City is just one of several fictional towns in that appear as settings in Hinojosa’s imaginary county.

Hinojosa has spent his entire–lengthy–writing career bringing new characters, situations and locations to the Death Trip Series. And his books have won numerous prestigious writing awards, including The National Book Critics Circle Ivan Sandrof Lifetime Achievement Award and, in 1976, the most prestigious prize in Latin American Fiction, Casa de las Américanas, for the best  Spanish American novel. He is now a professor of creative writing at the University of Texas in Austin.

Si Dunn

 

Node.js Blueprints – A good how-to book that covers plenty of JS frameworks and tools – #programming #bookreview

7338OS_Node.js Blueprints (1)

 

Node.js Blueprints

Develop stunning web and desktop applications with the definitive Node.js

Krasimir Tsonev

(Packt Publishing - paperback, Kindle)

 

Krasimir Tsonev’s new Node.js Blueprints book has proven helpful for me as I try to become more adept at using Node.js and a few of the many software packages that can work with it, such as AngularJS, Backbone.js, Ember.js, ExpressJS, Grunt.js and Gulp.js.

If you’ve never used Node.js before, here is its official description from the Nodejs.org site operated by Joyent, Inc.:

“Node.js is a platform built on Chrome’s JavaScript runtime for easily building fast, scalable network applications. Node.js uses an event-driven, non-blocking I/O model that makes it lightweight and efficient, perfect for data-intensive real-time applications that run across distributed devices.”

The focus of Node.js Blueprints is on showing readers the basics of how to use various frameworks, libraries and tools that can help them develop real-world applications that run with Node.js.

Tsonev’s approach is to introduce several popular frameworks, libraries and tools, provide code examples and explain the roles of various sections or modules within the code. The goal in each chapter is to help the reader learn how to work with a framework or other package and create a simple application — a blueprint for something bigger — that can run with Node.js

The book is aimed at intermediate-level JavaScript developers, especially “web developer[s] with experience in writing client-side JavaScript,” who are interested in using Node.js in web and desktop applications.

The 12-chapter, 268-page book is structured as follows:

  • Chapter 1, Common Programming Paradigms, focuses on how “common design patterns known in JavaScript” can be applied in Node.js, as well.
  • Chapter 2, Developing a Basic Site with Node.js and Express, shows how to use ExpressJS, “one of the top frameworks on the market,” in applications “using the built-in Express modules and…your own modules.”
  • Chapter 3, Writing a Blog Application with Node.js and AngularJS, explains how to use the Angular frontend framework with Node.js, MongoDB and MySQL to create “a dynamic application that works with real databases.”
  • Chapter 4, Developing a Chat with Socket.IO, points out that “every big web app uses real-time data” and how it is “important to show instant results to the users.” And it covers “the creation of a simple real-time chat,” while emphasizing that “[t]he same concept can be used to create an automatically updatable HTML component.”
  • Chapter 5, Creating a To-do Application with Backbone.js, notes that “Backbone.js was one of the first frameworks that introduced data binding at the frontend of applications.” A simple (but useful) to-do application is used to illustrate how to use the powerful framework along with Node.js.
  • Chapter 6, Using Node.js as a Command-line Tool, explains that many command-line tools have been written with Node.js, and this chapter shows how to create one. The result is “a simple application which grabs all the images in a directory and uploads them to Flickr.”
  • Chapter 7, Showing a Social Feed with Ember.js, is centered on producing “an Ember.js example that will read a Twitter feed and display the latest posts. That’s actually a common task of every developer,” Tsonev says, “because a lot of applications need to visualize social activity.” (Reviewer’s caution: Ember.js has a long learning curve, and this chapter just barely gets you started.)
  • Chapter 8,  Developing Web App Workflow with Grunt and Gulp, explains how to use two popular task runners. “Grunt is the de facto standard” for simplifying and managing tasks such as concatenation, minification, templating and other operations before an application is delivered to users. Gulp, meanwhile, is a popular build system. The projects in this chapter include generating a cache manifest file using Grunt, and concatenating and minifying using Gulp.
  • Chapter 9, Automating Your Testing with Node.js, is especially aimed at fans (and forced-by-employer “enthusiasts”) of test-driven development and behavior-driven development. The chapter introduces how to use the Node.js versiosn of the Jasmine and Mocha frameworks for testing JavaScript code and how to use the headless browser PhantomJS to test user interfaces. You also are shown how to use DalekJS, a Node.js module that allows you to control major browsers such as Google Chrome, Internet Explorer and Firefox while doing interface tests.
  • Chapter 10, Writing Flexible and Modular CSS, emphasizes how “[t]he Web is built on the basis of three languages–HTML, CSS, and JavaScript” and “Node.js provides really helpful instruments to write CSS…and improve our style sheets.” Other topics include the Less preprocessor, the Stylus preprocessor, the Sass preprocessor, and the AbsurdJS preprocessor.
  • Chapter 11, Writing a REST API, focuses on building a Representational State Transfer (REST) Application Programming Interface (API). The chapter’s Node.js project is “an API of a simple online books library. The resources are the books, and they will be accessed through the REST API.” Tsonev notes that “Node.js is very often used to build REST APIs. Also, because it is a common tool, we have several possible approaches.” In this chapter, however, the emphasis is “to build our REST API from scratch, because it will be more interesting and challenging.”
  • Chapter 12, Developing Desktop Apps with Node.js, declares that “Node.js can be used to produce desktop programs, and w don’t have to learn a new language or use a new tool.” In this chapter, Tsonev shows how to use node-webkit to create a file browser that runs as a desktop program, reads files from the hard drive, displays the files on-screen, and also displays images.

Tsonev’s well-written book introduces a lot of good material to help you get started. After that, you have to do the work to get better at using the various frameworks and tools. But the writer gives you plenty of possibilities to start with in your quest to become a better developer.

You may encounter an occasional typo in the book’s printed code. Thus, be sure to download the available code examples for reference, even if you prefer to type in code by hand (one of my favorite ways to learn, too).

And, during the lengthy process to write, edit, and publish the book, some of the software has changed to newer versions than are called for in the text–which may affect how something works in certain small areas of code.  Indeed, in programming books that rely on several different software packages, changes always happen, and those changes seldom are convenient to the printing deadline.

So if something doesn’t work the way you expect, and you are positive your hand-typed code has no known mistakes, don’t yell at the author. Download the code examples. Look for the publisher’s errata files. Seek out comments at book sites such as the readers’ reviews on Amazon, as well as comments on social media sites and specialized sites where JavaScript and Node.js developers hang out. Also take a look at the “official” websites for the frameworks and tools.

I have been wanting to learn more about working with Node.js, and Node.js Blueprints definitely is filling that need.

Si Dunn

The Sony a7 and a7R: The Unofficial Quintessential Guide – #photography #bookreview

sony_a7_a7r

The Sony a7 and a7R

The Unofficial Quintessential Guide

Brian Matsumoto and Carol F. Roulland

(Rocky Nook - paperback, Kindle)

 

Rocky Nook has gained a hard-earned reputation for publishing excellent digital camera how-to guides. And this new one does not disappoint.

The Sony a7 and a7R: The Unofficial Quintessential Guide is aimed at both professional photographers and newcomers who recently have acquired, or are still considering, various elements of the Sony a7 and a7R digital photography and video system, including camera bodies, lenses and accessories.

The authors, who both have extensive photography experience, praise the a7 and a7R as “a breakthrough camera design…the lightest, least expensive, full-frame interchangeable lens cameras available to professional and amateur photographers” at the time their book was written.

The a7/a7R system has some innovations, including, for example, “a completely electronic viewfinder” that provides “immediate feedback on errors in white balance, focus, and exposure.” You also can use the viewfinder to “preview the image with additional artistic elements, such as saturated vivid colors, or muted colors and subtle shades, to decide how to create the proper ambience for the scene.” You also can preview the image in black-and-white.

But Matsumoto and Roulland offer a caution, as well. The a7 and a7R cameras are not well-suited for “taking action shots with a rapid-fire burst capability.” They recommend some of the “heavier digital SLRs,” instead.  The a7 and a7R, they contend, are “eminently suitable for those photographers who are interested in taking pictures at a more deliberate rate, who are concerned about critical composition, and whose aim is to take landscapes close-ups, portraits, or scientific photographs.”

Their 11-chapter, 362-page book wisely includes a chapter titled the “Basics of Digital Photography” near the front of the book, so users new to the a7 and a7R series–particularly those moving up from simple point-and-shoot cameras can learn to how to set their cameras on Intelligent Auto mode or Superior Auto mode and take good pictures while they are becoming familiar with menus, options and features.  (Superior Auto mode “is able to fine-tune the camera settings to create a better-quality image,” the two authors point out.)

Like many other of today’s digital cameras, the a7 and a7R offer “scores of menu commands and options, which can discourage even the most experienced user” if time and care are not taken to learn the ones you will use most often.

Matsumoto’s and Roulland’s excellent how-to book begins with chapters on “Getting Started” and learning the basics of photography, including f/stops, ISO numbers and some essential settings when shooting pictures or video.

The remaining chapters cover:

  • Managing Your Images
  • Automatic Settings
  • Taking Control of the Camera
  • Manual Control
  • Additional Features
  • Working with the Camera’s Wireless Functions
  • Accessory Lenses
  • Flash Photography
  • Making Movies

Two appendices also are included. Appendix A covers menu commands. Appendix B focuses on error messages and warning messages and how to resolve them.

A caution is offered for those who may use the a7R with telescopes, long telescopic lenses, or microscopes. “In comparison to the a7, movement of the a7R’s mechanical shutter can generate significant vibration which can blur the image.”  However, Matsumoto and Roulland also offer some tips to minimize the vibration’s effects.

If you have or are considering this new Sony camera system, The Sony a7 and a7R: The Unofficial Quintessential Guide packs a lot more clear and useful information than you will find in the official user manuals.

The book is richly illustrated, and it provides clear, step-by-step procedures and recommendations for every feature. You’ll need and want it in your library and in your camera case.

Si Dunn

 

Enemies at Home: A Flavia Albia Novel – A cool detective procedural set in ancient Rome – #mystery #bookreview

 

Lindsey Davis Enemies at Home

 

Enemies at Home

A Flavia Albia Novel

Lindsey Davis

 ( Minotaur Books, hardback, Kindle )

Can a 29-year-old widow make it as a private detective in first century A.D. Rome?

Flavia Albia has some friends in semi-high places. And she has one very important family connection: She is the adopted daughter of Marcus Didius Falco, one of Rome’s best-known “private informers,” the ancient equivalent of a modern private eye.

Flavia has taken over her father’s office, and she keeps needing new cases.  But in the private informer business, it’s “no win, no pay.” So,  she is always on the lookout for a case she can both win and profit from, in a legal system where women have no rights in matters of law and where she must compete with male private informers who do have rights.

Unfortunately, the case that suddenly lands in Flavia’s lap in Enemies at Home does not seem to hold much promise:

“Even before I started, I knew I should say no,” Flavia states at the book’s beginning.

“There are rules for private informers accepting a new case. Never take on clients who cannot pay you. Never do favors for friends. Don’t work with relatives, Think carefully about legal work. If, like me, you are a woman, keep clear of men you find attractive. The Aviola inquiry broke every one of those rules, not the least because the clients had no money, yet I took it on. Will I never learn?”

 Not yet. She meets up with a magistrate, an aedile, named Tiberius Manlius Faustus, with whom she has worked before and finds attractive. (Can “Manlius” be viewed as a Latinized pun on “manly”? Yep.) Faustus has just been assigned to deal with a very complicated case within his jurisdiction, and he needs Flavia’s help to try to sort things out.

A man and his wife have been brutally murdered and robbed, apparently by intruders, and the couples’ slaves have fled to the Temple of Ceres, desperately hoping to get asylum so they can save their lives.

“The slaves got wind of their plight,” Flavia informs us. “They knew the notorious Roman law when a head of household was murdered at home. By instinct the authorities went after the wife, but that was no use if she was dead too. So unless the dead man had another obvious enemy, his slaves fell under suspicion. Whether guilty or not, they were put to death. All of them.”

Flavia’s task, of course, is to attempt to help exonerate the slaves. But Roman law literally is a vicious beast, sometimes. Criminals and those merely suspected of a crime can be thrown to the lions or sewn into large bags along with dangerous animals and dropped into the sea. And that’s just two of the many ways capital punishment can be meted out in the Roman Empire.

Flavia is the slaves’ only hope. And she is armed with nothing but curiosity, questions and bluster, plus some occasional help from the aedile, Manlius Faustus, as she goes where no woman typically has gone before, at least in recent years, in Roman society.

Enemies at Home features a very big cast of characters (spanning two pages at the front of the book). And it is somewhat easy to grow confused by (and a bit wearied of) virtually every male name ending in “-us” and almost every female name ending in “-a.”

For the most part, however, this second Flavia Albia novel is fun and informative reading. Lindsey Davis is a master at moving her characters about in ancient Roman settings. She keeps them both human and limited by the pace, technology, laws and social mores of the Roman Empire (during the reign of the allegedly paranoid emperor, Domitian). Her dialogue often is wickedly sharp and funny, and, except for an occasional Latin word here and there, no effort is made to have the characters speak in any tongue other than modern lingo.

If you have been hoping Falco will reappear and have a cameo role in this new book, be prepared to wait for the next novel in the series and see if he shows up there. Flavia Albia is now her own woman. She emerges strongly from her father’s shadow in Enemies at Home and demonstrates why she also deserves to be known as one of the very best public informers in first-century Rome.

Si Dunn

Matzo Frogs – A hopping-good children’s book about acts of kindness – #bookreview #children’s books

Matzo Frogs

Sally Rosenthal (author) and David Sheldon (illustrations)

(NewSouth Books - hardcover)

Matzo Frogs is a fun tale, delightfully told and superbly illustrated. It tells and shows how one act of kindness can lead to another:  “Mitzvah goreret mitzvah.”

The book has been created for children and for parents of children who are still learning to read. But adults also need to be reminded about the special powers of kindness and working together. Matzo Frogs can help with that task, too.

Matzo Frogs tells the story of kind-hearted Minnie Feinsilver. Her favorite cousins are coming over for Shabbat dinner, and Minnie is up early, fixing matzo ball soup. Unfortunately, Minnie has an accident and spills the soup. And she doesn’t have time to prepare a new batch. She has promised to spend the day helping a friend who is bedridden with a broken leg. So she goes off to do that good deed.

Her next-door neighbors, a colony of frogs living in a pond, know what has happened to Minnie, and they decide to help, to do a mitzvah, by preparing a new batch of matzo soup in her kitchen.

David Sheldon’s artwork brings the cooking adventure to hilarious life as the frogs hop into action, opening the recipe book, gathering the special ingredients, making the matzo balls, cooking the soup and jumping back home just before Minnie returns home to her surprise.

Minnie realizes that while she was out helping her friend, someone else has helped her by saving her Shabbat dinner for her cousins. And, when she finally figures out who did the mitzvah, she thanks them in a kind and special way.

The book’s author, Sally Rosenthal, is an Emmy Award-winning documentary film producer. Matzo Frogs is her first book. The illustrator, David Sheldon, has created artwork for more than 80 children’s books.

By the way, if you are hungry for some matzo soup but don’t want to gather  up and cook the ingredients or wait for kind frogs to fix it for you, here’s a link to a well-known packaged mix.

Si Dunn

 

 

 

Ember.js in Action – An ambitious overview, with glitches – #programming #bookreview

Ember.js in Action

Joachim Haagen Skeie

(Manning - paperback)

 

The Ember.js JavaScript framework has “a steep learning curve,” Joachim Haagen Skeie cautions readers repeatedly in his new book.

Indeed, Ember does. I’ve watched that learning curve confuse and frustrate several experienced JavaScript and Ruby on Rails developers. And I’ve banged my own (thick) skull against the Ember.js framework several times while (1) trying to learn it from an assortment of books and websites, including emberjs.com, and (2) building a few basic apps.

Skeie’s new book is an ambitious overview of software that bills itself as “a framework for creating ambitious web applications.” And Skeie ambitiously does not start out with a lame “Hello, World!” example. Right in Chapter 1, you dive into building a real-world application for creating, editing, posting and deleting notes. ” The source code for the Notes application weighs in at about 200 lines of code and 130 lines of CSS, including the templates and JavaScript source code,” Skeie points out. “You should be able to develop and run this application on any Windows-, Mac-, or Linux-based platform using only a text editor.”

I got  the Notes app to (mostly) run on a Windows machine and a Linux machine. But I can’t get it to save the contents of notes, even though I downloaded the book’s code samples, and my code seems to match what the author highlights in his book. (Still trying to sort out the problem. Perhaps something is wrong in my setups?)

I hate writing mixed reviews. It takes enormous effort and thought to create and finish a book. And I have been looking and hoping for a solid how-to text on Ember. For me, however, this book has two key downsides. First, the code examples are written for Ember.js 1.0.0, and as this review is being written, Ember.js 1.5.1 is the latest release (with 1.6 in beta). Second, the book’s opening chapter is very difficult for beginners to follow.

Some other reviewers also have noticed problems with the book’s example code –which, for me, forms the heart of a good how-to book. And they have taken issue with how the code is presented in the text.

Still, there is much to like here, especially if you are experienced in JavaScript and in model-view-controller (MVC) frameworks and have been curious about Ember.js.

I am fairly new to Ember, so some of the chapters most helpful to me have included using Handlebars js, testing Ember.js applications and creating custom Ember.js components–areas not given much notice in the other Ember books I have read.

If you are new to JavaScript and to frameworks, do not attempt to dive into Ember.js in Action as your first Ember exposure. Start with the Ember.js website and some simpler books first. Then, consider this book.

Hopefully, in the next edition, the all-important opening chapter will be reworked, and the code examples will be presented in a clearer and more complete fashion.

Si Dunn

 

Learning Dart – A solid guide to basic development using Google’s Dart #programming language – #bookreview

Learning Dart

Learn how to program applications with Dart 1.0, a language specifically designed to produce better-structured, high performance applications 

Ivo Balbaert and Dzenan Ridjanovic

(Packt - Kindle, paperback)

 

The programming language Dart was introduced in late 2011 by Google as a potential replacement for aging JavaScript. But JavaScript, of course, has continued to spread all over the Internet and planet since it first appeared in 1995.

Not surprisingly, Google found itself getting some pushback from software developers and others who have a lot of time, education, sweat and money invested into creating, supporting and modernizing files that have .js extensions.

Dart today is billed as “a new platform for scalable web app engineering.” It is a long way from replacing JavaScript. Indeed, it compiles to JavaScript.

At the same time,  Dart is a good and powerful Open Source language. And, while it is not yet seen on most lists of top languages to know, it is gaining momentum and followers in the software world.

“Dart looks instantly familiar to the majority of today’s programmers coming from a Java, C#, or JavaScript/ActionScript background; you will feel at ease with Dart,” write the authors of Learning Dart.

“However, this does not mean it [Dart] is only a copy of what already exists; it takes the best features of the statically typed ‘Java-C#’ world and combines these with features more commonly found in dynamic languages such as JavaScript, Python, and Ruby. On the nimble, dynamic side[,] Dart allows rapid prototyping, evolving into a more structured development familiar to business app developers when application requirements become more complex.”

In their recent book,  Balbaert and Ridjanovic note this about Dart: “Its main emphasis lies on building complex (if necessary), high-performance, and scalable-rich client apps for the modern web.”

Likewise, they point out that  “Dart can also run independently on servers. Because Dart clients and servers can communicate through web sockets (a persistent connection that allows both parties to start sending data at any time), it is in fact an end-to-end solution. It is perfect on the frontend for developing web components with all the necessary application logic, nicely integrated with HTML5 and the browser document model (DOM).

“On the backend server side, it can be used to develop web services, for example, to access databases, or cloud solutions in Google App Engine or other cloud infrastructures. Moreover, it is ready to be used in the multicore world (remember, even your cell phone is multicore nowadays) because a Dart program can divide its work amongst any number of separate processes, called isolates, an actor-based concurrency model as in Erlang.”

Their well-written book, from Packt Publishing, delivers a structured and nicely paced overview of how to use the Dart programming language. The book is suited for inexperienced developers and experienced developers alike who are curious about, or ready to dig into, Dart .

The intended audience, the authors state, includes “…web application programmers, game developers, and other software engineers. Because of its dual focus (Dart and HTML5), the book can appeal to both web developers who want to learn a modern way of developing web applications, and to developers who seek guidance on how to use HTML5.”

Indeed, in the first chapter, you get more than the obligatory “Hello, World!” program. You also learn how to use the Eclipse-based Dart Editor to create some simple command-line and web applications.

From there, the 12-chapter work focuses on topics and software examples that range from variables, classes and libraries, to combining HTML forms with Dart, building games with HTML5 and Dart, developing business apps with Polymer web components, using Dart with MVC web and UI frameworks, working with local data and client-server communications, and creating data-driven web applications using Dart and MySQL or MongoDB.

I have tested some of the book’s code examples both on Linux and Windows machines and have enjoyed working with the Dart Editor. However, I did find a couple of code typos in the print version while hand-typing some of the shorter examples. The better choice is to download and use the book’s code examples found on the Packt website.

One other matter that some new Dartisans may encounter: Norton 360 antivirus software currently tends to throw dart.exe into quarantine on Windows machines–and that stops Dart cold. There is a fairly simple way to retrieve the file from quarantine and tell Norton 360 to let it run. However, check the Dart community page on Google+ for info on that and some other approaches to avoiding the problem.

Learning Dart was published soon after Dart 1.0 was released, and Dart has continued to evolve fairly quickly. (Its stable version was 1.4.3 at the time this was written.) So there will be some small differences in screen displays and other matters.

If you want to learn Dart and get up to speed for using it in application development, Learning Dart can be your handy and solid how-to guide.

Si Dunn

 ***

Ready to get Learning Dart? Click here: Kindlepaperback