ENTRIES TAGGED "javascript"

What every Java developer needs to know about Java 9

Introducing updated HTTP client support and JSON API integration.

What every Java developer needs to know about Java 9Java 8 may only have been released a few months ago, but Oracle has already announced the first set of features that will be targeted for Java 9. On August 11th, Mark Reinhold, a Chief Architect for Java, made available an initial feature set to subscribers on the jdk9-dev mailing list.

The crop of features are being run under a relatively new process, known as Java Enhancement Proposals (JEP). This process allows new language and VM features to be prototyped and explored without the full weight of the normal Java standardization process, although the expectation is that suitable, successful JEPs would go on to formal standardization. There will, of course, be many other new features that will be introduced in Java 9, but in this post we are going to focus on two major enhancements — and examine how they relate to features added in Java 7 and 8.

Read more…

Comment

The Future of AngularJS

Charting the progress towards AngularJS 2.0

sextantAngularJS, for me, was a revelation the first time I encountered it. I was coming from using GWT (Google Web Toolkit), and seeing our large application shrink in lines of code by 90% was close to a spiritual experience. I was a convert from day one, because I knew how bad things were otherwise. Ever since, I have been associated with AngularJS in one way or another, and have seen how it makes things absolutely simple with data binding, templating, routing, unit testing, and so much more. But the more I used it, some things didn’t make sense, from naming to concepts. I got the hang of it, but I never really got to like why directives needed to be so complex, or how the built-in routing was quite limiting. While AngularJS made it trivial to write applications, it also made it trivial to write slow, hard-to-maintain applications if you didn’t understand how it all worked together.

Read more…

Comments: 4
Four short links: 8 August 2014

Four short links: 8 August 2014

Synchronization, Security Pi, YouTube Stardom, and Javascript Logging

  1. Everything You Wanted to Know About Synchronization But Were Too Afraid to Ask (PDF) — This paper presents the most exhaustive study of synchronization to date. We span multiple layers, from hardware cache-coherence protocols up to high-level concurrent software. We do so on different types of architectures, from single-socket — uniform and non- uniform — to multi-socket — directory and broadcast-based many-cores. We draw a set of observations that, roughly speaking, imply that scalability of synchronization is mainly a property of the hardware.
  2. Raspberry Pi as Low-Cost Security Camera (Instructables) — $120 HD motion-sensing web-viewable security camera.
  3. Inside YouTube’s Fame Factory (FastCompany) — great article about the tipping point where peer-to-peer fame becomes stage-managed corporate fame, as Vidcon grows. See also Variety: If YouTube stars are swallowed by Hollywood, they are in danger of becoming less authentic versions of themselves, and teenagers will be able to pick up on that,” Sehdev says. “That could take away the one thing that makes YouTube stars so appealing.”
  4. Sherlog.js (Github) — Javascript error and event tracker application. Honestly, I have no idea if this is any good but the name is golden. I’m such a sucker.
Comment
Four short links: 7 August 2014

Four short links: 7 August 2014

Material Design, Stewart's Slack, Sketching in Javascript, and Neural Networks and Deep Learning

  1. Material Design in the Google I/O App (Medium) — steps through design thinking as they put Google’s new design metaphor in place. I’ve been chewing on material design. It brings an internal consistency and logic to the Android world that Apple’s iOS and OS X visual worlds have been losing over the years. How long until web users expect this consistency too?
  2. Stewart and Slack (Wired) — profile of Foo Stewart Butterfield and his shiny Slack startup.
  3. p5js — a new Processing-inspired code-as-sketching in Javascript. Using the original metaphor of a software sketchbook, p5.js has a full set of drawing functionality. However, you’re not limited to your drawing canvas, you can think of your whole browser page as your sketch!
  4. Neural Networks and Deep Learning — a free online book to teach you … well, neural networks and deep learning.
Comment
Four short links: 31 July 2014

Four short links: 31 July 2014

OCR in Javascript, Insecure IoT, USB Considered Insecure, and Use AdBlock Plus

  1. Ocrad.js — open source OCR in Javascript, a port of GNU Ocrad software.
  2. HP’s IoT Security Research (PDF) — 70% of devices use unencrypted network services, 90% of devices collected at least one piece of personal information, 60% of those that have UIs are vulnerable to things like XSS, 60% didn’t use encryption when downloading software updates, …
  3. USB Security Flawed From Foundation (Wired) — The element of Nohl and Lell’s research that elevates it above the average theoretical threat is the notion that the infection can travel both from computer to USB and vice versa. Any time a USB stick is plugged into a computer, its firmware could be reprogrammed by malware on that PC, with no easy way for the USB device’s owner to detect it. And likewise, any USB device could silently infect a user’s computer. “It goes both ways,” Nohl says. “Nobody can trust anybody.” [...] “In this new way of thinking, you can’t trust a USB just because its storage doesn’t contain a virus. Trust must come from the fact that no one malicious has ever touched it,” says Nohl. “You have to consider a USB infected and throw it away as soon as it touches a non-trusted computer. And that’s incompatible with how we use USB devices right now.”
  4. AdBlock vs AdBlock Plus — short answer: the genuinely open source AdBlock Plus, because AdBlock resiled from being open source, phones home, has misleading changelog entries, …. No longer trustworthy.
Comment

Next-generation Web apps with full stack JavaScript

Power scalable Web apps with 100% JavaScript

stones-1652-BSince its introduction, JavaScript was often seen as a limited object-oriented language that had many “bad” parts. The situation today is almost the opposite.

In competition with Java, C#, and Ruby, JavaScript is developing one of the largest ecosystems for web applications today. Why, as it seems, is a language made for web browsers gaining traction for building next-generation web applications on the server-side too?

In fact, you can see another example of disruptive innovation at work. As Clayton Christensen explained in his innovation theory, affordability and access are important drivers behind technology shifts. While the LAMP stack and its peers with Ruby, Python, Java, and C# provide the foundations for many server-side web applications today, JavaScript ships natively with web browsers, which enables a much larger part of the digital population to experiment with web development. In addition to lower costs of infrastructure and easier installation, companies get access to a larger pool of web developers.
Read more…

Comments: 3
Four short links: 30 June 2014

Four short links: 30 June 2014

Interacting with Connected Objects, Continuous Security Review, Chess AI, and Scott Hanselman is Hilarious

  1. Interacting with a World of Connected Objects (Tom Coates) — notes from one of my favourite Foo Camp sessions.
  2. Security Considerations with Continuous Deployment (IBM) — rundown of categories of security issues your org might face, and how to tackle them in the continuous deployment cycle. (via Emma Jane Westby)
  3. The Chess Master and the Computer (Garry Kasparov) — Increasingly, a move isn’t good or bad because it looks that way or because it hasn’t been done that way before. It’s simply good if it works and bad if it doesn’t. Although we still require a strong measure of intuition and logic to play well, humans today are starting to play more like computers. (via Alexis Madrigal)
  4. Virtual Machines, Javascript, and Assembler (YouTube) — hilarious Velocity keynote by Scott Hanselman.
Comment: 1

It’s time for a web page diet

Site speed is essential to business success, yet many pages are getting bigger and slower.

Illustration of scaleEarlier this year, I was researching online consumer preferences for a client and discovered, somewhat unsurprisingly, that people expect web sites to be fast and responsive, particularly when they’re shopping. What did surprised me, however, were findings in Radware’s “State of the Union Report Spring 2014” (registration required) that showed web sites, on average, were becoming bigger in bytes and slower in response time every year. In fact, the average Alexa 1000 web page has grown from around 780KB and 86 resources in 2011 to more than 1.4MB and 99 resources by the time of the early “2014 State of the Union Winter Report.”

As an experiment, I measured the resources loaded for Amazon.com on my own computer: 2.6MB loaded with 252 requests!

This seemed so odd. Faster is more profitable, yet companies were actually building fatter and slower web sites. What was behind all these bytes? Had web development become so sophisticated that all the technology would bust the seams of the browser window? Read more…

Comments: 2
Four short links: 18 June 2014

Four short links: 18 June 2014

Browser Crypto, Real Time Consistency, Exploring CS, and CS as Social Movement

  1. Javascript Cryptography Considered Harmful — tl;dr: “don’t”. If you don’t trust the network to deliver a password, or, worse, don’t trust the server not to keep user secrets, you can’t trust them to deliver security code. The same attacker who was sniffing passwords or reading diaries before you introduce crypto is simply hijacking crypto code after you do.
  2. Eventual Consistency in Real Time Apps — answering How do you ensure that your local model is in sync with what’s stored on the backend?
  3. Exploring CSBoth courses are designed to teach the fundamental concepts and big ideas of computing along with coding, and to inspire kids about computer science’s creative potential to transform society.
  4. Why Computer Literacy Is Key To Winning the 21st Century (Mother Jones) — [teaching CS to] middle and high schoolers at the UCLA Community School, an experimental new public K-12 school. “I saw this as a new frontier in the social-justice fight,” she says. “I tell my students, ‘I don’t necessarily want to teach you how to get rich. I want to teach you to be a good citizen.'”
Comment: 1
Four short links: 13 June 2014

Four short links: 13 June 2014

Decentralized Web, Reproducibility Talk, Javascript Microcontroller, and Docker Maturity

  1. Mapping the Decentralized Movement (Jon Udell) — the pendulum is about to swing back toward a more distributed Web.
  2. John Ioannidis: Reproducible Research, True or False? (YouTube) — his talk at Google. (via Paul Kedrosky)
  3. Tessel — a microcontroller that runs Javascript. For those who can’t handle C.</troll>
  4. Docker MisconceptionsThis is not impossible and can all be done – several large companies are already using Docker in production, but it’s definitely non-trivial. This will change as the ecosystem around Docker matures (via Flynn, Docker container hosting, etc), but currently if you’re going to attempt using Docker seriously in production, you need to be pretty skilled at systems management and orchestration.
Comment