Archive | Big Data RSS feed for this section

Using R for Scalable Data Analytics

1 Apr

At the recent Strata conference in San Jose, several members of the Microsoft Data Science team presented the tutorial Using R for Scalable Data Analytics: Single Machines to Spark Clusters. The materials are all available online, including the presentation slides and hands-on R scripts. You can follow along with the materials at home, using the Data Science Virtual Machine for Linux, which provides all the necessary components like Spark and Microsoft R Server. (If you don’t already have an Azure account, you can get $200 credit with the Azure free trial.)

The tutorial covers many different techniques for training predictive models at scale, and deploying the trained models as predictive engines within production environments. Among the technologies you’ll use are Microsoft R Server running on Spark, the SparkR package, the sparklyr package and H20 (via the rsparkling package). It also touches on some non-Spark methods, like the bigmemory and ff packages for R (and various other packages that make use of them), and using the foreach package for coarse-grained parallel computations. You’ll also learn how to create prediction engines from these trained models using the mrsdeploy package.

Mrsdeploy

The tutorial also includes scripts for comparing the performance of these various techniques, both for training the predictive model:

Training

and for generating predictions from the trained model:

Scoring

(The above tests used 4 worker nodes and 1 edge node, all with with 16 cores and 112Gb of RAM.)

You can find the tutorial details, including slides and scripts, at the link below.

Strata + Hadoop World 2017, San Jose: Using R for scalable data analytics: From single machines to Hadoop Spark clusters

 

Source: http://blog.revolutionanalytics.com/big-data/

Streaming Big Data: Storm, Spark and Samza

1 Apr

There are a number of distributed computation systems that can process Big Data in real time or near-real time. This article will start with a short description of three Apache frameworks, and attempt to provide a quick, high-level overview of some of their similarities and differences.

Apache Storm

In Storm, you design a graph of real-time computation called a topology, and feed it to the cluster where the master node will distribute the code among worker nodes to execute it. In a topology, data is passed around between spouts that emit data streams as immutable sets of key-value pairs called tuples, and bolts that transform those streams (count, filter etc.). Bolts themselves can optionally emit data to other bolts down the processing pipeline.

storm-architecture4

Apache Spark

Spark Streaming (an extension of the core Spark API) doesn’t process streams one at a time like Storm. Instead, it slices them in small batches of time intervals before processing them. The Spark abstraction for a continuous stream of data is called a DStream (for Discretized Stream). A DStream is a micro-batch of RDDs (Resilient Distributed Datasets). RDDs are distributed collections that can be operated in parallel by arbitrary functions and by transformations over a sliding window of data (windowed computations).

spark-architecture4

Apache Samza

Samza ’s approach to streaming is to process messages as they are received, one at a time. Samza’s stream primitive is not a tuple or a Dstream, but a message. Streams are divided into partitions and each partition is an ordered sequence of read-only messages with each message having a unique ID (offset). The system also supports batching, i.e. consuming several messages from the same stream partition in sequence. Samza`s Execution & Streaming modules are both pluggable, although Samza typically relies on Hadoop’s YARN (Yet Another Resource Negotiator) and Apache Kafka.

samza4

Common Ground

All three real-time computation systems are open-source, low-latencydistributed, scalable and fault-tolerant. They all allow you to run your stream processing code through parallel tasks distributed across a cluster of computing machines with fail-over capabilities. They also provide simple APIs to abstract the complexity of the underlying implementations.

The three frameworks use different vocabularies for similar concepts:

Apache-concepts2

Comparison Matrix

A few of the differences are summarized in the table below:

Apaches

There are three general categories of delivery patterns:

  1. At-most-once: messages may be lost. This is usually the least desirable outcome.
  2. At-least-once: messages may be redelivered (no loss, but duplicates). This is good enough for many use cases.
  3. Exactly-once: each message is delivered once and only once (no loss, no duplicates). This is a desirable feature although difficult to guarantee in all cases.

Another aspect is state management. There are different strategies to store state. Spark Streaming writes data into the distributed file system (e.g. HDFS). Samza uses an embedded key-value store. With Storm, you’ll have to either roll your own state management at your application layer, or use a higher-level abstraction called Trident.

Use Cases

All three frameworks are particularly well-suited to efficiently process continuous, massive amounts of real-time data. So which one to use? There are no hard rules, at most a few general guidelines.

If you want a high-speed event processing system that allows for incremental computations, Storm would be fine for that. If you further need to run distributed computations on demand, while the client is waiting synchronously for the results, you’ll have Distributed RPC (DRPC) out-of-the-box. Last but not least, because Storm uses Apache Thrift, you can write topologies in any programming language. If you need state persistence and/or exactly-once delivery though, you should look at the higher-level Trident API, which also offers micro-batching.

A few companies using Storm: Twitter, Yahoo!, Spotify, The Weather Channel...

Speaking of micro-batching, if you must have stateful computations, exactly-once delivery and don’t mind a higher latency, you could consider Spark Streaming…specially if you also plan for graph operations, machine learning or SQL access. The Apache Spark stack lets you combine several libraries with streaming (Spark SQL, MLlibGraphX) and provides a convenient unifying programming model. In particular, streaming algorithms (e.g. streaming k-means) allow Spark to facilitate decisions in real-time.

spark-stack

A few companies using Spark: Amazon, Yahoo!, NASA JPL, eBay Inc., Baidu…

If you have a large amount of state to work with (e.g. many gigabytes per partition), Samza co-locates storage and processing on the same machines, allowing to work efficiently with state that won’t fit in memory. The framework also offers flexibility with its pluggable API: its default execution, messaging and storage engines can each be replaced with your choice of alternatives. Moreover, if you have a number of data processing stages from different teams with different codebases, Samza ‘s fine-grained jobs would be particularly well-suited, since they can be added/removed with minimal ripple effects.

A few companies using Samza: LinkedIn, Intuit, Metamarkets, Quantiply, Fortscale…

Conclusion

We only scratched the surface of The Three Apaches. We didn’t cover a number of other features and more subtle differences between these frameworks. Also, it’s important to keep in mind the limits of the above comparisons, as these systems are constantly evolving.

How artificial intelligence is disrupting your organization

26 Feb

robot  women in technology background

Whoever reads a science fiction novel ends up thinking about smart machines that can sense, learn, communicate and interact with human beings. The idea of Artificial Intelligence is not new, but there is a reason if big players like Google, Microsoft or Amazon are betting precisely on this technology right now.
After decades of broken promises, the AI is finally reaching its full potential. It has the power to disrupt your entire business. The question is: How can you harness this technology to shape the future of your organization?

Ever since the human has learned to dream, he has dreamed about ‘automata’, objects able to carry out complex actions automatically. The mythologies of many cultures – Ancient China and Greece, for example – are full of examples of mechanical servants.
Engineers and inventors in different ages attempted to build self-operating machines, resembling animals and humans. Then, in 1920, the Czech writer Karel Čapek used for the first time the term ‘Robot’ to indicate artificial automata.
The rest is history, with the continuing effort to take the final step from mechanical robots to intelligent machines. And here we are, talking about a market expected to reach over five billion dollars by 2020 (Markets & Markets).
The stream of news about the driverless cars, the Internet of Things, and the conversational agents is a clear evidence of the growing interest. Behind the obvious, though, we can find more profitable developments and implications for the Artificial Intelligence.

Back in 2015, while reporting our annual trip at the SXSW, we said that the future of the customer experience goes inevitably through the interconnection of smart objects.
The AI is a top choice when talking about the technologies that will revolutionize the retail store and the physical experience we have with places, products, and people.
The hyperconnected world we live in has a beating heart of chips, wires, and bytes. This is not a science fiction scenario anymore; this is what is happening, here and now, even when you do not see it.
The future of products and services appears more and more linked to the development of intelligent functions and features. Take a look at what has been done already with the embedded AI, that can enable your product to:

  • Communicate with the mobile connected ecosystem – Just think about what we can already do using Google Assistant on the smartphone, or the Amazon Alexa device.
  • Interact with other smart objects that surround us – The Internet of Things has completely changed the way we experience the retail store (and our home, with the domotics).
  • Assist the customer, handling a wider range of requests – The conversational interfaces, like Siri and the chatbots, act as a personal tutor embedded in the device.

As the years pass by, the gap between weak and strong AI widens increasingly. A theory revived by a recent report by Altimeter, not by chance titled “The Age of AI – How Artificial Intelligence Is Transforming Organizations”.
The difference can be defined in terms of the ability to take advantage of the data to learn and improve. Big data and machine learning, in fact, are the two prerequisites of the modern smart technology.
So, on the one hand, we have smart objects that can replace the humans on a specific use case – i.e. to free us from heavy and exhausting duties – but do not learn or evolve in time.
On the other hand, we have the strong AI, the most promising outlook: An intelligence so broad and strong that is able to replicate the general intelligence of human beings. It can mimic the way we think, act and communicate.

The “pure AI” is aspirational but – apart from the Blade Runner charm – this is the field where all the tech giants are willing to bet heavily. The development and implementation of intelligent machines will define the competitive advantage in the age of AI.
According to BCG, “structural flexibility and agility – for both man and machine – become imperative to address the rate and degree of change.

Source: http://www.broadband4europe.com/how-artificial-intelligence-is-disrupting-your-organization/

EU Privacy Rules Can Cloud Your IoT Future

24 Feb

When technology companies and communication service providers gather together at the Mobile World Congress (MWC) next week in Barcelona, don’t expect the latest bells-and-whistles of smartphones to stir much industry debate.

Smartphones are maturing.

In contrast, the Internet of Things (IoT) will still be hot. Fueling IoT’s continued momentum is the emergence of fully standardized NB-IoT, a new narrowband radio technology.

However, the market has passed its initial euphoria — when many tech companies and service providers foresaw a brave new world of everything connected to the Internet.

In reality, not everything needs an Internet connection, and not every piece of data – generated by an IoT device – needs a Cloud visit for processing, noted Sami Nassar, vice president of Cybersecurity at NXP Semiconductors, in a recent phone interview with EE Times.

For certain devices such as connected cars, “latency is a killer,” and “security in connectivity is paramount,” he explained. As the IoT market moves to its next phase, “bolting security on top of the Internet type of architecture” won’t be just acceptable, he added.

Looming large for the MWC crowd this year are two unresolved issues: the security and privacy of connected devices, according to Nassar.

GDPR’s Impact on IoT

Whether a connected vehicle, a smart meter or a wearable device, IoT devices are poised to be directly affected by the new General Data Protection Regulation (GDPR), scheduled to take effect in just two years – May 25, 2018.

Companies violating these EU privacy regulations could face penalties of up to 4% of their worldwide revenue (or up to 20 million euros).

In the United States, where many consumers willingly trade their private data for free goods and services, privacy protection might seem an antiquated concept.

Not so in Europe.

There are some basic facts about the GDPR every IoT designer should know.

If you think GDPR is just a European “directive,” you’re mistaken. This is a “regulation” that can take effect without requiring each national government in Europe to pass the enabling legislation.

If you believe GDPR applies to only European companies? Wrong again. The regulation also applies to organizations based outside the EU if they process the personal data of EU residents.

Lastly, if you suspect that GDPR will only affect big data processing companies such as Google, Facebook, Microsoft and Amazon, you’re misled. You aren’t off the hook. Big data processors will be be initially affected first in the “phase one,” said Nassar. Expect “phase two” [of GDPR enforcement] to come down on IoT devices, he added.

EU's GDPR -- a long time in the making (Source: DLA Piper)
Click here for larger image

EU’s GDPR — a long time in the making (Source: DLA Piper)
Click here for larger image

Of course, U.S. consumers are not entirely oblivious to their privacy rights. One reminder was the recent case brought against Vizio. Internet-connected Vizio TV sets were found to be automatically tracking what consumers were watching and transmitting the data to its servers. Consumers didn’t know their TVs were spying on them. When they found out, many objected.

The case against Vizio resulted in a $1.5 million payment to the FTC and an additional civil penalty in New Jersey for a total of $2.2 million.

Although this was seemingly a big victory for consumer rights in the U.S., the penalty could have been a much bigger in Europe. Before the acquisition by LeEco was announced last summer, Vizio had a revenue of $2.9 billion in the year ended in Dec. 2015.

Unlike in the United States where each industry applies and handles violation of privacy rules differently, the EU’s GDPR are sweeping regulations enforced with all industries. A violators like Vizio could have faced much heftier penalty.

What to consider before designing IoT devices
If you design an IoT device, which features and designs must you review and assess to ensure that you are not violating the GDPR?

When we posed the question to DLA Piper, a multinational law firm, its partner Giulio Coraggio told EE Times, “All the aspects of a device that imply the processing of personal data would be relevant.”

Antoon Dierick, lead lawyer at DLA Piper, based in Brussels, added that it’s “important to note that many (if not all) categories of data generated by IoT devices should be considered personal data, given the fact that (a) the device is linked to the user, and (b) is often connected to other personal devices, appliances, apps, etc.” He said, “A good example is a smart electricity meter: the energy data, data concerning the use of the meter, etc. are all considered personal data.”

In particular, as Coraggio noted, the GDPR applies to “the profiling of data, the modalities of usage, the storage period, the security measures implemented, the sharing of data with third parties and others.”

It’s high time now for IoT device designers to “think through” the data their IoT device is collecting and ask if it’s worth that much, said NXP’s Nassar. “Think about privacy by design.”

 

Why does EU's GDPR matter to IoT technologies? (Source: DLA Piper)

Why does EU’s GDPR matter to IoT technologies? (Source: DLA Piper)

Dierick added that the privacy-by-design principle would “require the manufacturer to market devices which are privacy-friendly by default. This latter aspect will be of high importance for all actors in the IoT value chain.”

Other privacy-by-design principles include: being proactive not reactive, privacy embedded into design, full lifecycle of protection for privacy and security, and being transparent with respect to user privacy (keep it user-centric). After all, the goal of the GDPR is for consumers to control their own data, Nassar concluded.

Unlike big data guys who may find it easy to sign up consumers as long as they offer them what they want in exchange, the story of privacy protection for IoT devices will be different, Nassar cautioned. Consumers are actually paying for an IoT device and the cost of services associated with it. “Enforcement of GDPR will be much tougher on IoT, and consumers will take privacy protection much more seriously,” noted Nassar.

NXP on security, privacy
NXP is positioning itself as a premier chip vendor offering security and privacy solutions for a range of IoT devices.

Many GDPR compliance issues revolve around privacy policies that must be designed into IoT devices and services. To protect privacy, it’s critical for IoT device designers to consider specific implementations related to storage, transfer and processing of data.

NXP’s Nassar explained that one basic principle behind the GDPR is to “disassociate identity from authenticity.” Biometric information in fingerprints, for example, is critical to authenticate the owner of the connected device, but data collected from the device should be processed without linking it to the owner.

Storing secrets — securely
To that end, IoT device designers should ensure that their devices can separately store private or sensitive information — such as biometric templates — from other information left inside the connected device, said Nassar.

At MWC, NXP is rolling out a new embedded Secure Element and NFC solution dubbed PN80T.

PN80T is the first 40nm secure element “to be in mass production and is designed to ease development and implementation of an extended range of secure applications for any platform” including smartphones, wearables to the Internet of Things (IoT), the company explained. Charles Dach, vice president and general manager of mobile transactions at NXP, noted that the PN80T, which is built on the success of NFC applications such as mobile payment and transit, “can be implemented in a range of new security applications that are unrelated to NFC usages.”

In short, NXP is positioning the PN80T as a chip crucial to hardware security for storing secrets.

Key priorities for the framers of the GDPR include secure storage of keys (in tamper resistant HW), individual device identity, secure user identities that respecting a user’s privacy settings, and secure communication channels.

Noting that the PN80T is capable of meeting“security and privacy by design” demands, NXP’s Dach said, “Once you can architect a path to security and isolate it, designing the rest of the platform can move faster.”

Separately, NXP is scheduled to join an MWC panel entitled a “GDPR and the Internet of Things: Protecting the Identity, ‘I’ in the IoT” next week. Others on the panel include representatives from the European Commission, Deutsche Telecom, Qualcomm, an Amsterdam-based law firm called Arthur’s Legal Legal and an advocacy group, Access Now.

Source: http://www.eetimes.com/document.asp?doc_id=1331386&

 

 

What is the difference between Consumer IoT and Industrial IoT (IIoT)?

19 Feb

Internet of Things (IoT) began as an emerging trend and has now become one of the key element of Digital Transformation that is driving the world in many respects.

If your thermostat or refrigerator is connected to the Internet, then it is part of the consumer IoT.  If your factory equipment have sensors connected to internet, then it is part of Industrial IoT(IIoT).

IoT has an impact on end consumers, while IIoT has an impact on industries like Manufacturing, Aviation, Utility, Agriculture, Oil & Gas, Transportation, Energy and Healthcare.

IoT refers to the use of “smart” objects, which are everyday things from cars and home appliances to athletic shoes and light switches that can connect to the Internet, transmitting and receiving data and connecting the physical world to the digital world.

IoT is mostly about human interaction with objects. Devices can alert users when certain events or situations occur or monitor activities:

  • Google Nest sends an alert when temperature in the house dropped below 68 degrees
  • Garage door sensors alert when open
  • Turn up the heat and turn on the driveway lights a half hour before you arrive at your home
  • Meeting room that turns off lights when no one is using it
  • A/C switch off when windows are open

IIoT on the other hand, focus more workers safety, productivity & monitors activities and conditions with remote control functions ability:

  • Drones to monitor oil pipelines
  • Sensors to monitor Chemical factories, drilling equipment, excavators, earth movers
  • Tractors and sprayers in agriculture
  • Smart cities might be a mix of commercial and IIoT.

IoT is important but not critical while IIoT failure often results in life-threatening or other emergency situations.

IIoT provides an unprecedented level of visibility throughout the supply chain. Individual items, cases, pallets, containers and vehicles can be equipped with auto identification tags and tied to GPS-enabled connections to continuously update location and movement.

IoT generates medium or high volume of data while IIoT generates very huge amounts of data (A single turbine compressor blade can generate more than 500GB of data per day) so includes Big Data,Cloud computing, machine learning as necessary computing requirements.

In future, IoT will continue to enhance our lives as consumers while IIoT will enable efficient management of entire supply chain.

Source: https://simplified-analytics.blogspot.nl/2017/02/what-is-difference-between-consumer-iot.html

Making Sense of Big Data

5 Sep

Table of Contents

Hardware

  • Arduino – Arduino is an open-source electronics platform based on easy-to-use hardware and software. It’s intended for anyone making interactive projects.
  • BeagleBoard – The BeagleBoard is a low-power open-source hardware single-board computer produced by Texas Instruments in association with Digi-Key and Newark element14.
  • Intel Galileo – The Intel® Galileo Gen 2 board is the first in a family of Arduino*-certified development and prototyping boards based on Intel® architecture and specifically designed for makers, students, educators, and DIY electronics enthusiasts.
  • Microduino – Microduino and mCookie bring powerful, small, stackable electronic hardware to makers, designers, engineers, students and curious tinkerers of all ages. Build open-source projects or create innovative new ones.
  • Node MCU (ESP 8266) – NodeMCU is an open source IoT platform. It uses the Lua scripting language. It is based on the eLua project, and built on the ESP8266 SDK 0.9.5.
  • OLinuXino – OLinuXino is an Open Source Software and Open Source Hardware low cost (EUR 30) Linux Industrial grade single board computer with GPIOs capable of operating from -25°C to +85°C.
  • Particle – A suite of hardware and software tools to help you prototype, scale, and manage your Internet of Things products.
  • Pinoccio – Pinoccio is a pocket-sized, wireless sensor and microcontroller board that combines the features of an Arduino Mega board with a ZigBee compatible 2.4GHz radio.
  • Raspberry Pi – The Raspberry Pi is a low cost, credit-card sized computer that plugs into a computer monitor or TV, and uses a standard keyboard and mouse. It’s capable of doing everything you’d expect a desktop computer to do, from browsing the internet and playing high-definition video, to making spreadsheets, word-processing, and playing games.
  • Tessel – Tessel is a completely open source and community-driven IoT and robotics development platform. It encompases development boards, hardware module add-ons, and the software that runs on them.

Software

Operating systems

  • Apache Mynewt – Apache Mynewt is a real-time, modular operating system for connected IoT devices that need to operate for long periods of time under power, memory, and storage constraints. The first connectivity stack offered is BLE 4.2.
  • ARM mbed – The ARM® mbed™ IoT Device Platform provides the operating system, cloud services, tools and developer ecosystem to make the creation and deployment of commercial, standards-based IoT solutions possible at scale.
  • Contiki – Contiki is an open source operating system for the Internet of Things. Contiki connects tiny low-cost, low-power microcontrollers to the Internet.
  • FreeRTOS – FreeRTOS is a popular real-time operating system kernel for embedded devices, that has been ported to 35 microcontrollers.
  • Google Brillo – Brillo extends the Android platform to all your connected devices, so they are easy to set up and work seamlessly with each other and your smartphone.
  • OpenWrt – OpenWrt is an operating system (in particular, an embedded operating system) based on the Linux kernel, primarily used on embedded devices to route network traffic. The main components are the Linux kernel, util-linux, uClibc or musl, and BusyBox. All components have been optimized for size, to be small enough for fitting into the limited storage and memory available in home routers.
  • Snappy Ubuntu – Snappy Ubuntu Core is a new rendition of Ubuntu with transactional updates. It provides a minimal server image with the same libraries as today’s Ubuntu, but applications are provided through a simpler mechanism.
  • NodeOS – NodeOS is an operating system entirely written in Javascript, and managed by npm on top of the Linux kernel.
  • Raspbian – Raspbian is a free operating system based on Debian optimized for the Raspberry Pi hardware.
  • RIOT – The friendly Operating System for the Internet of Things.
  • Tiny OS – TinyOS is an open source, BSD-licensed operating system designed for low-power wireless devices, such as those used in sensor networks, ubiquitous computing, personal area networks, smart buildings, and smart meters.
  • Windows 10 IoT Core – Windows 10 IoT is a family of Windows 10 editions targeted towards a wide range of intelligent devices, from small industrial gateways to larger more complex devices like point of sales terminals and ATMs.

Programming languages

This sections regroups every awesome programming language, whether it is compiled, interpreted or a DSL, related to embedded development.

  • C – A general-purpose, imperative computer programming language, supporting structured programming, lexical variable scope and recursion, while a static type system prevents many unintended operations.
  • C++ – A general-purpose programming language. It has imperative, object-oriented and generic programming features, while also providing facilities for low-level memory manipulation.
  • Groovy – Groovy is a powerful, optionally typed and dynamic language, with static-typing and static compilation capabilities, for the Java platform aimed at multiplying developers’ productivity thanks to a concise, familiar and easy to learn syntax. It is used by the SmartThings development environment to create smart applications.
  • Lua – Lua is a powerful, fast, lightweight, embeddable scripting language. Lua is dynamically typed, runs by interpreting bytecode for a register-based virtual machine, and has automatic memory management with incremental garbage collection, making it ideal for configuration, scripting, and rapid prototyping.
  • eLua – eLua stands for Embedded Lua and the project offers the full implementation of the Lua Programming Language to the embedded world, extending it with specific features for efficient and portable software embedded development.
  • ELIoT – ELIoT is a very simple and small programming language specifcally designed to facilitate the configuration and control of swarms of small devices such as sensors or actuators.

Frameworks

  • AllJoyn – AllJoyn is an open source software framework that makes it easy for devices and apps to discover and communicate with each other.
  • Apple HomeKit – HomeKit is a framework for communicating with and controlling connected accessories in a user’s home.
  • Countly IoT Analytics – Countly is a general purpose analytics platform for mobile and IoT devices, available as open source.
  • Eclipse Smarthome – The Eclipse SmartHome framework is designed to run on embedded devices, such as a Raspberry Pi, a BeagleBone Black or an Intel Edison. It requires a Java 7 compliant JVM and an OSGi (4.2+) framework, such as Eclipse Equinox.
  • Iotivity – IoTivity is an open source software framework enabling seamless device-to-device connectivity to address the emerging needs of the Internet of Things.
  • Kura – Kura aims at offering a Java/OSGi-based container for M2M applications running in service gateways. Kura provides or, when available, aggregates open source implementations for the most common services needed by M2M applications.
  • Mihini – The main goal of Mihini is to deliver an embedded runtime running on top of Linux, that exposes high-level API for building M2M applications. Mihini aims at enabling easy and portable development, by facilitating access to the I/Os of an M2M system, providing a communication layer, etc.
  • OpenHAB – The openHAB runtime is a set of OSGi bundles deployed on an OSGi framework (Equinox). It is therefore a pure Java solution and needs a JVM to run. Being based on OSGi, it provides a highly modular architecture, which even allows adding and removing functionality during runtime without stopping the service.
  • Gobot – Gobot is a framework for robotics, physical computing, and the Internet of Things, written in the Go programming language.

Middlewares

  • IFTTT – IFTTT is a web-based service that allows users to create chains of simple conditional statements, called “recipes”, which are triggered based on changes to other web services such as Gmail, Facebook, Instagram, and Pinterest. IFTTT is an abbreviation of “If This Then That” (pronounced like “gift” without the “g”).
  • Huginn – Huginn is a system for building agents that perform automated tasks for you online.
  • Kaa – An open-source middleware platform for rapid creation of IoT solutions.

Libraries and Tools

  • Cylon.js – Cylon.js is a JavaScript framework for robotics, physical computing, and the Internet of Things. It makes it incredibly easy to command robots and devices.
  • Luvit – Luvit implements the same APIs as Node.js, but in Lua ! While this framework is not directly involved with IoT development, it is still a great way to rapidly build powertfull, yet memory efficient, embedded web applications.
  • Johnny-Five – Johnny-Five is the original JavaScript Robotics programming framework. Released by Bocoup in 2012, Johnny-Five is maintained by a community of passionate software developers and hardware engineers.
  • WiringPi – WiringPi is a GPIO access library written in C for the BCM2835 used in the Raspberry Pi.
  • Node-RED – A visual tool for wiring the Internet of Things.

Miscellaneous

  • Amazon Dash – Amazon Dash Button is a Wi-Fi connected device that reorders your favorite item with the press of a button.
  • Freeboard – A real-time interactive dashboard and visualization creator implementing an intuitive drag & drop interface.

Protocols and Networks

Physical layer

 – 802.15.4 (IEEE)

IEEE 802.15.4 is a standard which specifies the physical layer and media access control for low-rate wireless personal area networks (LR-WPANs). It is maintained by the IEEE 802.15 working group, which has defined it in 2003. It is the basis for the ZigBee, ISA100.11a, WirelessHART, and MiWi specifications, each of which further extends the standard by developing the upper layers which are not defined in IEEE 802.15.4. Alternatively, it can be used with 6LoWPAN and standard Internet protocols to build a wireless embedded Internet. – Wikipedia

IEEE standard 802.15.4 intends to offer the fundamental lower network layers of a type of wireless personal area network (WPAN) which focuses on low-cost, low-speed ubiquitous communication between devices. It can be contrasted with other approaches, such as Wi-Fi, which offer more bandwidth and require more power. The emphasis is on very low cost communication of nearby devices with little to no underlying infrastructure, intending to exploit this to lower power consumption even more.

 – Bluetooth (Bluetooth Special Interest Group)

Bluetooth is a wireless technology standard for exchanging data over short distances (using short-wavelength UHF radio waves in the ISM band from 2.4 to 2.485 GHz) from fixed and mobile devices, and building personal area networks (PANs). Invented by telecom vendor Ericsson in 1994, it was originally conceived as a wireless alternative to RS-232 data cables. It can connect several devices, overcoming problems of synchronization. – Wikipedia

Bluetooth is managed by the Bluetooth Special Interest Group (SIG), which has more than 25,000 member companies in the areas of telecommunication, computing, networking, and consumer electronics.

 – Bluetooth Low Energy (Bluetooth Special Interest Group)

Bluetooth low energy (Bluetooth LE, BLE, marketed as Bluetooth Smart) is a wireless personal area network technology designed and marketed by the Bluetooth Special Interest Group aimed at novel applications in the healthcare, fitness, beacons, security, and home entertainment industries. – Wikipedia

Compared to Classic Bluetooth, Bluetooth Smart is intended to provide considerably reduced power consumption and cost while maintaining a similar communication range. The Bluetooth SIG predicts that by 2018 more than 90 percent of Bluetooth-enabled smartphones will support Bluetooth Smart.

 – LoRaWAN (LoRa Alliance)

A LoRaWAN wide area network allows low bit rate communication from and to connected objects, thus participating to Internet of Things, machine-to-machine M2M, and smart city. – Wikipedia

This technology is standardized by the LoRa Alliance. It was initially developed by Cycleo, which was acquired by Semtech in 2012. LoRaWAN is an acronym for Long Range Wide-area network.

 – Sigfox (Sigfox)

Sigfox is a French firm that builds wireless networks to connect low-energy objects such as electricity meters, smart watches, and washing machines, which need to be continuously on and emitting small amounts of data. Its infrastructure is intended to be a contribution to what is known as the Internet of Things (IoT). – Wikipedia

SIGFOX describes itself as “the first and only company providing global cellular connectivity for the Internet of Things.” Its infrastructure is “completely independent of existing networks, such as telecommunications networks.” SIGFOX seeks to provide the means for the “deployment of billions of objects and thousands of new uses” with the long-term goal of “having petabytes of data produced by everyday objects”.

 – Wi-Fi (Wi-Fi Alliance)

Wi-Fi (or WiFi) is a local area wireless computer networking technology that allows electronic devices to network, mainly using the 2.4 gigahertz (12 cm) UHF and 5 gigahertz (6 cm) SHF ISM radio bands. – Wikipedia

The Wi-Fi Alliance defines Wi-Fi as any “wireless local area network” (WLAN) product based on the Institute of Electrical and Electronics Engineers’ (IEEE) 802.11 standards.[1] However, the term “Wi-Fi” is used in general English as a synonym for “WLAN” since most modern WLANs are based on these standards. “Wi-Fi” is a trademark of the Wi-Fi Alliance. The “Wi-Fi Certified” trademark can only be used by Wi-Fi products that successfully complete Wi-Fi Alliance interoperability certification testing.

Network / Transport layer

 – 6LowPan (IETF)

6LoWPAN is an acronym of IPv6 over Low power Wireless Personal Area Networks. 6LoWPAN is the name of a concluded working group in the Internet area of the IETF. – Wikipedia

The 6LoWPAN concept originated from the idea that “the Internet Protocol could and should be applied even to the smallest devices,”and that low-power devices with limited processing capabilities should be able to participate in the Internet of Things. The 6LoWPAN group has defined encapsulation and header compression mechanisms that allow IPv6 packets to be sent and received over IEEE 802.15.4 based networks. IPv4 and IPv6 are the work horses for data delivery for local-area networks, metropolitan area networks, and wide-area networks such as the Internet. Likewise, IEEE 802.15.4 devices provide sensing communication-ability in the wireless domain. The inherent natures of the two networks though, are different.

 – Thread (Thread Group)

Thread is an IPv6 based protocol for “smart” household devices to communicate on a network.

In July 2014 Google Inc’s Nest Labs announced a working group with the companies Samsung, ARM Holdings, Freescale, Silicon Labs, Big Ass Fans and the lock company Yale in an attempt to have Thread become the industry standard by providing Thread certification for products. Other protocols currently in use include ZigBee and Bluetooth Smart. Thread uses 6LoWPAN, which in turn uses the IEEE 802.15.4 wireless protocol with mesh communication, as does ZigBee and other systems. Thread however is IP-addressable, with cloud access and AES encryption. It supports over 250 devices on a network.

 – ZigBee (ZigBee Alliance)

ZigBee is a IEEE 802.15.4-based specification for a suite of high-level communication protocols used to create personal area networks with small, low-power digital radios. – Wikipedia

The technology defined by the ZigBee specification is intended to be simpler and less expensive than other wireless personal area networks (WPANs), such as Bluetooth or Wi-Fi. Applications include wireless light switches, electrical meters with in-home-displays, traffic management systems, and other consumer and industrial equipment that requires short-range low-rate wireless data transfer.

 – Z-Wave (Z-Wave Alliance)

Z-Wave is a wireless communications specification designed to allow devices in the home (lighting, access controls, entertainment systems and household appliances, for example) to communicate with one another for the purposes of home automation. – Wikipedia

Z-Wave technology minimizes power consumption so that it is suitable for battery-operated devices. Z-Wave is designed to provide, reliable, low-latency transmission of small data packets at data rates up to 100kbit/s, unlike Wi-Fi and other IEEE 802.11-based wireless LAN systems that are designed primarily for high data rates. Z-Wave operates in the sub-gigahertz frequency range, around 900 MHz.

Application layer

CoAP (IETF)

Constrained Application Protocol (CoAP) is a software protocol intended to be used in very simple electronics devices that allows them to communicate interactively over the Internet. – Wikipedia

CoAP is particularly targeted for small low power sensors, switches, valves and similar components that need to be controlled or supervised remotely, through standard Internet networks. CoAP is an application layer protocol that is intended for use in resource-constrained internet devices, such as WSN nodes.

DTLS (IETF)

The Datagram Transport Layer Security (DTLS) communications protocol provides communications security for datagram protocols. – Wikipedia

DTLS allows datagram-based applications to communicate in a way that is designed[by whom?] to prevent eavesdropping, tampering, or message forgery. The DTLS protocol is based on the stream-oriented Transport Layer Security (TLS) protocol and is intended to provide similar security guarantees.

 – Eddystone (Google)

Eddystone is a beacon technology profile released by Google in July 2015. The open source, cross-platform software gives users location and proximity data via Bluetooth low-energy beacon format. – Wikipedia

Though similar to the iBeacon released by Apple in 2013, Eddystone works on both Android and iOS, whereas iBeacon is limited to iOS platforms. A practical application of both softwares is that business owners can target potential customers based on the location of their smartphones in real time.

 – HTTP (IETF)

The Hypertext Transfer Protocol (HTTP) is an application protocol for distributed, collaborative, hypermedia information systems. HTTP is the foundation of data communication for the World Wide Web. – Wikipedia

The standards development of HTTP was coordinated by the Internet Engineering Task Force (IETF) and the World Wide Web Consortium (W3C), culminating in the publication of a series of Requests for Comments (RFCs). The first definition of HTTP/1.1, the version of HTTP in common use, occurred in RFC 2068 in 1997, although this was obsoleted by RFC 2616 in 1999.

 – iBeacon (Apple)

iBeacon is a protocol standardized by Apple and introduced at the Apple Worldwide Developers Conference in 2013. –Wikipedia

iBeacon uses Bluetooth low energy proximity sensing to transmit a universally unique identifier picked up by a compatible app or operating system. The identifier can be used to determine the device’s physical location, track customers, or trigger a location-based action on the device such as a check-in on social media or a push notification.

 – MQTT (IBM)

MQTT (formerly MQ Telemetry Transport) is a publish-subscribe based “light weight” messaging protocol for use on top of the TCP/IP protocol. It is designed for connections with remote locations where a “small code footprint” is required or the network bandwidth is limited. – Wikipedia

The publish-subscribe messaging pattern requires a message broker. The broker is responsible for distributing messages to interested clients based on the topic of a message. Andy Stanford-Clark and Arlen Nipper of Cirrus Link Solutions authored the first version of the protocol in 1999.

 – STOMP

Simple (or Streaming) Text Oriented Message Protocol (STOMP), formerly known as TTMP, is a simple text-based protocol, designed for working with message-oriented middleware (MOM). – Wikipedia

STOMP provides an interoperable wire format that allows STOMP clients to talk with any message broker supporting the protocol. It is thus language-agnostic, meaning a broker developed for one programming language or platform can receive communications from client software developed in another language.

 – Websocket

WebSocket is a protocol providing full-duplex communication channels over a single TCP connection. – Wikipedia

WebSocket is designed to be implemented in web browsers and web servers, but it can be used by any client or server application. The WebSocket Protocol is an independent TCP-based protocol. The WebSocket protocol makes more interaction between a browser and a website possible, facilitating live content and the creation of real-time games. This is made possible by providing a standardized way for the server to send content to the browser without being solicited by the client, and allowing for messages to be passed back and forth while keeping the connection open.

 – XMPP (IETF)

Extensible Messaging and Presence Protocol (XMPP) is a communications protocol for message-oriented middleware based on XML (Extensible Markup Language). – Wikipedia

It enables the near-real-time exchange of structured yet extensible data between any two or more network entities. Designed to be extensible, the protocol has also been used for publish-subscribe systems, signalling for VoIP, video, file transfer, gaming, Internet of Things (IoT) applications such as the smart grid, and social networking services.

Technologies

This sections regroups a curated list of awesome technologies that are closely related to the IoT world.

 – NFC

Near field communication (NFC) is the set of protocols that enable electronic devices to establish radio communication with each other by touching the devices together, or bringing them into proximity to a distance of typically 10cm or less. –Wikipedia

– OPCUA

OPC-UA is a not only a protocol for industrial automation but also a technology that allows semantic description and object modeling of industrial environment. Wikipedia

Standards and Alliances

Standards

  • ETSI M2M – The ETSI Technical Committee is developing standards for Machine to Machine Communications.
  • OneM2M – The purpose and goal of oneM2M is to develop technical specifications which address the need for a common M2M Service Layer that can be readily embedded within various hardware and software, and relied upon to connect the myriad of devices in the field with M2M application servers worldwide.
  • OPCUA – OPC Unified Architecture (OPC UA) is an industrial M2M communication protocol for interoperability developed by the OPC Foundation.

Alliances

  • AIOTI – The Internet of Things Innovation (AIOTI) aims to strengthen links and build new relationships between the different IoT players (industries, SMEs, startups) and sectors.
  • AllSeen Alliance – The AllSeen Alliance is a nonprofit consortium dedicated to enabling and driving the widespread adoption of products, systems and services that support the Internet of Everything with an open, universal development framework supported by a vibrant ecosystem and thriving technical community.
  • Bluetooth Special Interest Group – The Bluetooth Special Interest Group (SIG) is the body that oversees the development of Bluetooth standards and the licensing of the Bluetooth technologies and trademarks to manufacturers.
  • IPSO Alliance – The IPSO Alliance provides a foundation for industry growth by fostering awareness, providing education, promoting the industry, generating research, and creating a better understanding of IP and its role in the Internet of Things.
  • LoRa Alliance – The LoRa Alliance is an open, non-profit association of members that believes the internet of things era is now. It was initiated by industry leaders with a mission to standardize Low Power Wide Area Networks (LPWAN) being deployed around the world to enable Internet of Things (IoT), machine-to-machine (M2M), and smart city, and industrial applications.
  • OPC Foundation – The mission of the OPC Foundation is to manage a global organization in which users, vendors and consortia collaborate to create data transfer standards for multi-vendor, multi-platform, secure and reliable interoperability in industrial automation. To support this mission, the OPC Foundation creates and maintains specifications, ensures compliance with OPC specifications via certification testing and collaborates with industry-leading standards organizations.
  • Open Interconnect Consortium – The Open Interconnect Consortium (OIC) is an industry group whose stated mission is to develop standards and certification for devices involved in the Internet of Things (IoT) based around CoAP. OIC was created in July 2014 by Intel, Broadcom, and Samsung Electronics.
  • Thread Group – The Thread Group, composed of members from Nest, Samsung, ARM, Freescale, Silicon Labs, Big Ass Fans and Yale, drives the development of the Thread network protocol.
  • Wi-Fi Alliance – Wi-Fi Alliance® is a worldwide network of companies composed of several companies forming a global non-profit association with the goal of driving the best user experience with a new wireless networking technology – regardless of brand.
  • Zigbee Alliance – The ZigBee Alliance is an open, non-profit association of approximately 450 members driving development of innovative, reliable and easy-to-use ZigBee standards.
  • Z-Wave Alliance – Established in 2005, the Z-Wave Alliance is comprised of industry leaders throughout the globe that are dedicated to the development and extension of Z-Wave as the key enabling technology for ‘smart’ home and business applications.

Resources

Books

Abusing the Internet of Things: Blackouts, Freakouts, and Stakeouts (2015) by Nitesh Dhanjani [5.0]

future with billions of connected “things” includes monumental security concerns. This practical book explores how malicious attackers can abuse popular IoT-based devices, including wireless LED lightbulbs, electronic door locks, baby monitors, smart TVs, and connected cars.

Building Wireless Sensor Networks: with ZigBee, XBee, Arduino, and Processing (2011) by Robert Faludi [4.5]

Get ready to create distributed sensor systems and intelligent interactive devices using the ZigBee wireless networking protocol and Series 2 XBee radios. By the time you’re halfway through this fast-paced, hands-on guide, you’ll have built a series of useful projects, including a complete ZigBee wireless network that delivers remotely sensed data.

Designing the Internet of Things (2013) by Adrian McEwen and Hakim Cassimally [4.0]

Whether it’s called physical computing, ubiquitous computing, or the Internet of Things, it’s a hot topic in technology: how to channel your inner Steve Jobs and successfully combine hardware, embedded software, web services, electronics, and cool design to create cutting-edge devices that are fun, interactive, and practical. If you’d like to create the next must-have product, this unique book is the perfect place to start.

Getting Started with Bluetooth Low Energy: Tools and Techniques for Low-Power Networking (2014) by Kevin Townsend,Carles CufíAkiba and Robert Davidson [4.5]

This book provides a solid, high-level overview of how devices use Ble to communicate with each other. You’ll learn useful low-cost tools for developing and testing Ble-enabled mobile apps and embedded firmware and get examples using various development platforms including iOs and Android for app developers and embedded platforms for product designers and hardware engineers.

Smart Things: Ubiquitous Computing User Experience Design (2010) by Mike Kuniavsky [4.5]

Smart Things presents a problem-solving approach to addressing designers’ needs and concentrates on process, rather than technological detail, to keep from being quickly outdated. It pays close attention to the capabilities and limitations of the medium in question and discusses the tradeoffs and challenges of design in a commercial environment.

Articles

Papers

Source: http://www.voidcn.com/blog/robertsong2004/article/p-6187093.html

Big Data, IoT & Blockchain: Ready to Follow the Yellow Brick Road?

24 Mar

Disruption. You can’t have a discussion today about business or technology without the term entering the conversation. I think it’s become an unwritten rule. It’s almost as if no one will take you seriously unless you’re talking about business disruption. Or how disruptive technologies can be used to advance business and provide a competitive edge.

Take Big Data and the Internet of Things (IoT). Both rank highly on the list of disruptive technologies. And as with most technologies, there are areas of great synergy that ultimately provide a yellow brick road to real business value. (See my recent blog Big Data, the Internet of Things, and Russian Nesting Dolls.)

Gold ingod road in grass with sky

Blockchain enters the disruptive dialogue

But recently, a new topic has enlivened the disruption discussions: Blockchain technology. And with it, the requisite stream of questions. What exactly is it? How does it help (or does it help) provide business value? How will it affect my current initiatives? And are there synergies to be had—or do I have to worry about it blowing everything up?

What is blockchain—and how is it associated with Bitcoin?

If you do a Google search on blockchain, you’ll find several results that inevitably pair the terms “blockchain” and “Bitcoin.” That’s because blockchain technology enables digital currencies like Bitcoin to work. As you may be aware, Bitcoin has no physical form, is not controlled by a single entity, nor is it backed by any government or agency.

(I’m not going to attempt to discuss the pros and cons of Bitcoin here. Those conversations can be almost as emotional as political discussions—and voluminous enough to fill books.)

A permanent digital transaction database…

In simple terms, blockchain is a digital ledger of transactions that you might think of as a spreadsheet. Yet it comprises a constantly growing list of transactions called “blocks”—all of which are sequentially connected. Each block has a link to the previous one in the list. Once a block is in the chain it can’t be removed, so it becomes part of a permanent database containing all the transactions that have occurred since its inception.

…is also the ultimate distributed database

But perhaps the most interesting thing about blockchain is that there’s no central authority or single source of the database. Which means it exists on every system that’s associated with it. Yes, every system has its own complete copy of the blockchain. As new blocks are added, they’re also received by every system—for the ultimate distributed database. So if you lose your copy, no problem. By rejoining the blockchain network you get a fresh new copy of the entire blockchain.

But how do you ensure transactional security?

By now you’re probably wondering, “How can this possibly result in a secure method for conducting digital transactions?” The short answer is through some very complex cryptography, math puzzles, and crowdsourcing consensus. There’s a great video that explains it in some detail on YouTube. It’s a little over 20 minutes long, but is the best explanation I’ve seen of a very complex solution.

The net result is called a “trustless system.” Which is not to say the system can’t be trusted. It simply means that two parties don’t need a trusted third party (such as a bank or credit card company) to maintain a ledger and valid transactions. Because every transaction can always be verified against the distributed ledger, a copy of which resides with all parties.

Note: One thing that’s important to understand is that while you can’t have Bitcoin without blockchain, you can use blockchain without involving Bitcoin—and that’s when things can become very interesting.

Blockchain and Big Data

When you talk about blockchain in the context of Bitcoin, the connection to Big Data seems a little tenuous. What if, instead of Bitcoin, the blockchain was a ledger for other financial transactions? Or business contracts? Or stock trades?

The financial services industry is starting to take a serious look at block chain technology. Citi, Nasdaq, and Visa recently made significant , a Bitcoin blockchain service provider. And Oliver Bussmann, CIO of UBS says that blockchain technology could “pare transaction processing time from days to minutes.”

The business imperative in financial services for blockchain is powerful. Imagine blockchains of that magnitude. Huge data lakes of blocks that contain the full history of every financial transaction, all available for analysis. Blockchain provides for the integrity of the ledger, but not for the analysis. That’s where Big Data and accompanying analysis tools will come into play.

Blockchain and the Internet of Things

There’s no doubt that IoT is a tremendous growth industry. Gartner predicts that the number of “things” will exceed 25 billion (with a B) devices within the next four years. These things can be anything from a small sensor to a large appliance—and everything in between. Two key challenges are securing those devices, and the privacy of the data they exchange.

Traditional centralized authority and message brokering could help address these issues, but will not scale with the number of devices predicted and the 100’s of billions of transactions the devices will generate.

Several major industry leaders put forth blockchain technology is as a possible solution to these challenges. The vision is a decentralized IoT, where the blockchain can act as the framework for facilitating transaction processing and coordination among interacting devices. Each device would manage its own roles and behavior and rules for interaction.

Follow the Yellow Brick Road

The blockchain builds itself a block at a time, always growing and moving forward, but also maintaining the trail of where it’s been. While the blockchain’s original purpose was in support of Bitcoin digital currency, like most disruptive technologies its value is growing in unexpected ways and directions.

As a technologist, I find the technology fascinating. That being said, technology is just a tool. It’s our responsibility to ensure the tools can be leveraged to provide true business value. Whethers its reduction of transaction processing time, analysis of transaction trends, or providing a mechanism to securely scale the Internet of Things messaging, the synergies with Big Data and IoT are one way we can follow that yellow block road to true business value.

This post is sponsored by SAS and Big Data Forum.

Source: http://www.collaborative.com/blog/big-data-iot-blockchain/

Datameer provides tips on how telecom operators can take advantage of big data to boost customer experience

22 Feb

Data is king. Companies like Google and Facebook operate on this basis and virtually every business decision stems from what data says about their customers and how they interact with their products and services.

Leveraging data to win against competitors and skyrocket revenues should not just be reserved for the Google’s of the world. Telecommunications companies generate enormous amounts of data each year – both structured and unstructured – on customer behaviors, preferences, payment histories, consumption levels, user patterns, customer experiences and more. And with analytics this data is a gold mine for those who know how to monetize it.

Telco’s data gold rush

Telecom service providers previously only had access to aggregated, metered data and even when data types exploded, they lacked the technology to harness it and find meaningful insights into valuable customer usage patterns. Today, data is generated from each customer touch point – calls, text messages, roaming, video downloads, mobile commerce, custom relationship management systems, service calls and so on. Analyzing, this data has the potential to differentiate services, boost customer experiences and, ultimately, increase revenue.

A recent McKinsey & Company study showed data-driven companies have a 50% chance of having sales well above competitors compared to customer analytics laggards. And according to McKinsey & Company benchmarking research, “high-margin telecommunication companies tend to outperform their peers when it comes to data mining and otherwise gaining insights from collected customer information.”

3 ways to mine big data for better customer experiences

Already we’re seeing telecom providers combine and analyze to better serve their customer base. In fact, big data analytics company, Guavus, released the findings of a global survey pointing to proactive customer care as the biggest single driver of big data analytics uptake among telcos.

Here are three examples of what can be achieved:

Improved customer retention
For every customer who complains, even more remain silent. As such, customer feedback is gold and with data analytics companies can make use of it and exploit it. Telcos can combine call center information, charging data records and CRM data to understand the biggest customer pain points. By analyzing customer complaints related to networks issues, such as dropped calls and slow connections, and correlating it with CRM data to see which customers have left, companies can better understand which network problems have the most impact on their customers. Armed with this information customer service teams can prioritize addressing hot issues and reduce churn.

Proactive customer care and reduced truck rolls
Analyzing big data can reduce unnecessary in-person appointments, service calls or truck rolls – which can cost several hundred dollars each – by resolving customer issues on the first call. To do this companies must be able to accurately predict which kinds of customer issues tend to result in the unnecessary truck rolls and develop a system for handling them more effectively through their call centers. With data analytics and visualizations, companies can generate custom reporting, interactive “what-if” scenarios and visualizations complete with clustering and a geographic heat map for network traffic. This allows providers to see where issues may arise and allocate resources accordingly.

Consistent service experiences with accurate demand forecasts
As mobile broadband usage, high-definition television consumption, over-the-top and other services consume more network bandwidth, it’s more important than ever to accurately plan for network capacity. To determine exactly where to lay the new infrastructure it is almost mandatory to take a data-driven approach by identifying concurrency in customer data regarding player sessions, peak usage times and dates, and then clustering this data to identify usage patterns. These patterns would help to forecast future growth and network demands. By analyzing terabytes of session data across a vast carrier network and generating a predictive trend analysis of customer video viewing behavior patterns, it is possible to have a new level of insight into customer behavior trends, which improves the ability to forecast for future demand and plan network investments.

Data analytics gives companies a whole new level of insight into customer behavior trends. More importantly, it opens up endless opportunities to improve customer experiences and keep customers happy.

 

Source: http://www.rcrwireless.com/20160222/opinion/reader-forum-3-ways-telcos-use-big-data-to-amplify-customer-experience-tag10

How to get started with infrastructure and distributed systems

4 Jan
 Most of us developers have had experience with web or native applications that run on a single computer, but things are a lot different when you need to build a distributed system to synchronize dozens, sometimes hundreds of computers to work together.

I recently received an email from someone asking me how to get started with infrastructure design, and I thought that I would share what I wrote him in a blog post if that can help more people who want to get started in that as well.

To receive a notification email every time a new article is posted on Code Capsule, you can subscribe to the newsletter by filling up the form at the top right corner of the blog.

A basic example: a distributed web crawler

For multiple computers to work together, you need some of synchronization mechanisms. The most basic ones are databases and queues. Part of your computers are producers or masters, and another part are consumers or workers. The producers write data in a database, or enqueue jobs in a queue, and the consumers read the database or queue. The database or queue system runs on a single computer, with some locking, which guarantees that the workers don’t pick the same work or data to process.

Let’s take an example. Imagine you want to implement a web crawler that downloads web pages along with their images. One possible design for such a system will require the following components:

  • Queue: the queue contains the URLs to be crawled. Processes can add URLs to the queue, and workers can pick up URLs to download from the queue.
  • Crawlers: the crawlers pick URLs from the queue, either web pages or images, and download them. If a URL is a webpage, the crawlers also look for links in the page, and push all those links to the queue for other crawlers to pick them up. The crawlers are at the same time the producers and the consumers.
  • File storage: The file storage stores the web pages and images in an efficient manner.
  • Metadata: a database, either MySQL-like, Redis-like, or any other key-value store, will keep track of which URL has been downloaded already, and if so where it is stored locally.

The queue and the crawlers are their own sub-systems, they communicate with external web servers on the internet, with the metadata database, and with the file storage system. The file storage and metadata database are also their own sub-systems.

Figure 1 below shows how we can put all the sub-systems together to have a basic distributed web crawler. Here is how it works:

1. A crawler gets a URL from the queue.
2. The crawler checks in the database if the URL was already downloaded. If so, just drop it.
3. The crawler enqueues the URLs of all links and images in the page.
4. If the URL was not downloaded recently, get the latest version from the web server.
5. The crawler saves the file to the File Storage system: it talks to a reserse proxy that’s taking incoming requests and dispatching them to storage nodes.
6. The File Storage distributes load and replicates data across multiple servers.
7. The File Storage update the metadata database so we know which local file is storing which URL.

Architecture-of-KingDB-web

Figure 1: Architecture of a basic distributed web crawler

The advantage of a design like the one above is that you can scale up independently each sub-system. For example, if you need to crawl stuff faster, just add more crawlers. Maybe at some point you’ll have too many crawlers and you’ll need to split the queue into multiple queues. Or maybe you realize that you have to store more images than anticipated, so just add a few more storage nodes to your file storage system. If the metadata is becoming too much of a centralized point of contention, turn it into a distributed storage, use something like Cassandra or Riak for that. You get the idea.

And what I have presented above is just one way to build a simple crawler. There is no right or wrong way, only what works and what doesn’t work, considering the business requirements.

Talk to people who are doing it

The one unique way to truly learn how to build a distributed system is to maintain or build one, or work with someone who has built something big before. But obviously, if the company you’re currently working at does not have the scale or need for such a thing, then my advice is pretty useless…

Go to meetup.com and find groups in your geographic area that talk about using NoSQL data storage systems, Big Data systems, etc. In those groups, identify the people who are working on large-scale systems and ask them questions about the problems they have and how they solve them. This is by far the most valuable thing you can do.

Basic concepts

There are a few basic concepts and tools that you need to know about, some sort of alphabet of distributed systems that you can later on pick from and combine to build systems:

    • Concepts of distributed systems: read a bit about the basic concepts in the field of Distributed Systems, such as consensus algorithms, consistent hashing, consistency, availability and partition tolerance.
    • RDBMs: relational database management systems, such as MySQL or PostgreSQL. RDMBs are one of the most significant invention of humankind from the last few decades. They’re like Excel spreadsheets on steroid. If you’re reading this article I’m assuming you’re a programmer and you’ve already worked with relational databases. If not, go read about MySQL or PostgreSQL right away! A good resource for that is the web site http://use-the-index-luke.com/
    • Queues: queues are the simplest way to distribute work among a cluster of computers. There are some specific projects tackling the problem, such as RabbitMQ or ActiveMQ, and sometimes people just use a table in a good old database to implement a queue. Whatever works!
    • Load balancers: if queues are the basic mechanism for a cluster of computer to pull work from a central location, load balancers are the basic tool to push work to a cluster of computer. Take a look at Nginx and HAProxy.
    • Caches: sometimes accessing data from disk or a database is too slow, and you want to cache things in the RAM. Look at projects such as Memcached and Redis.
    • Hadoop/HDFS: Hadoop is a very spread distributed computing and distributed storage system. Knowing the basics of it is important. It is based on the MapReduce system developed at Google, and is documented in the MapReduce paper.
    • Distributed key-value stores: storing data on a single computer is easy. But what happens when a single computer is no longer enough to store all the data? You have to split your storage into two computers or more, and therefore you need mechanisms to distribute the load, replicate data, etc. Some interesting projects doing that you can look at are Cassandraand Riak.

Read papers and watch videos

There is a ton of content online about large architectures and distributed systems. Read as much as you can. Sometimes the content can be very academic and full of math: if you don’t understand something, no big deal, put it aside, read about something else, and come back to it 2-3 weeks later and read again. Repeat until you understand, and as long as you keep coming at it without forcing it, you will understand eventually. Some references:

Introductory resources

Real-world systems and practical resources

Theoretical content

Build something on your own

There are plenty of academic courses available online, but nothing replaces actually building something. It is always more interesting to apply the theory to solving real problems, because even though it’s good to know the theory on how to make perfect systems, except for life-critical applications it’s almost never necessary to build perfect systems.

Also, you’ll learn more if you stay away from generic systems and instead focus on domain-specific systems. The more you know about the domain of the problem to solve, the more you are able to bend requirements to produce systems that are maybe not perfect, but that are simpler, and which deliver correct results within an acceptable confidence interval. For example for storage systems, most business requirements don’t need to have perfect synchronization of data across replica servers, and in most cases, business requirements are loose enough that you can get away with 1-2%, and sometimes even more, of erroneous data. Academic classes online will only teach you about how to build systems that are perfect, but that are impractical to work with.

It’s easy to bring up a dozen of servers on DigitalOcean or Amazon Web Services. At the time I’m writing this article, the smallest instance on DigitalOcean is $0.17 per day. Yes, 17 cents per day for a server. So you can bring up a cluster of 15 servers for a weekend to play with, and that will cost you only $5.

Build whatever random thing you want to learn from, use queuing systems, NoSQL systems, caching systems, etc. Make it process lots of data, and learn from your mistakes. For example, things that come to my mind:

      • Build a system that crawls photos from a bunch of websites like the one I described above, and then have another system to create thumbnails for those images. Think about the implications of adding new thumbnail sizes and having to reprocess all images for that, having to re-crawl or having to keep the data up-to-date, having to serve the thumbnails to customers, etc.
      • Build a system that gathers metrics from various servers on the network. Metrics such as CPU activity, RAM usage, disk utilization, or any other random business-related metrics. Try using TCP and UDP, try using load balancers, etc.
      • Build a system that shards and replicate data across multiple computers. For example, you’re complete dataset is A, B, and C and it’s split across three servers: A1, B1, and C1. Then, to deal with server failure you want to replicate the data, and have exact copies of those servers in A2, B2, C2 and A3, B3, C3. Think about the failure scenarios, how you would replicate data, how you would keep the copies synced, etc.?

Look at systems and web applications around you, and try to come up with simplified versions of them:

      • How would you store the map tiles for Google Maps?
      • How would you store the emails for Gmail?
      • How would you process images for Instagram?
      • How would you store the shopping cart for Amazon?
      • How would you connect drivers and users for Uber?

Once you’ve build such systems, you have to think about what solutions you need to deploy new versions of your systems to production, how to gather metrics about the inner-workings and health of your systems, what type of monitoring and alerting you need, how you can run capacity tests so you can plan enough servers to survive request peaks and DDoS, etc. But those are totally different stories!

I hope that this article helped explain how you can get started with infrastructure design and distributed systems. If you have any other resources you want to share, or if you have questions, just drop a comment below!

Source: http://codecapsule.com/2016/01/03/how-to-get-started-with-infrastructure-and-distributed-systems/

The Internet of Things: It’s all about the data

1 Apr

No question, The Internet of Things (IoT) is the Next Big Thing. Gartner estimates that there will be 26 billion IoT-connected devices by 2020, producing incredible amounts of data on a second-by-second basis. This will dwarf the estimated 7.3 billion traditional computing devices – PCs, tablets, smartphones – expected to be online by 2020.

This trove of data presents tremendous opportunities for those prepared to use it. The question is, how can governments perform meaningful analysis and produce actionable information from this data in a way that will benefit citizens? Much of the effort in IoT today has focused on managing the end devices that produce data. But the Internet of Things is not about the sensors; it’s about the data the sensors produce.

Link analysis already is already helping us understand the relations between a person of interest and other people, places, and things. Police Departments already use Geographic Information Systems to identify high-crime areas and put “cops on the dots.” But what if we could correlate historical weather data with crime statistics and sentiment analysis to predict when and where certain kinds of activity can be expected? Smart meters can track household energy usage; what if this data could be used to identify vacant homes that are at risk for vandalism and arson? Traffic light data already is used to understand traffic patterns; what if this data could be combined with public event calendars and social media to anticipate traffic problems on a given day, time, and location?

The big challenges of using Big Data effectively are visibility and scale. First, making the data visible so that it can be used requires knowing what data is being generated, who owns it and where it resides, and what format it is in. Beginning with this, data scientists can normalize data and do the correlation and analysis to provide relationships for users. But gaining visibility is not necessarily a simple task – data resides not only in separate systems and silos, but is controlled by different political and administrative entities. Data on energy usage belongs to utilities, which can be either public or private, and traffic information belongs to the traffic department. Both of these could be useful to police, but police departments will have to cross administrative boundaries to access it.

Second, the sheer scale of the data involved can be daunting. Sensors can produce millions samples per second, demanding huge storage capacity. Storage demands can be compounded by the need to maintain historical data. Real-time or near-real-time analysis can be valuable, but value grows as historical data is used to identify and project trends.

To take advantage of the opportunities offered by the IoT to improve citizen services, agencies will have to have the storage and computing capacity to manage Big Data from multiple sources and produce actionable analysis. There are three important steps in enabling your city, department or agency to do this:

  • Understand what data is available and what you want to do with it. This will include data from your own sensors and systems, but can also include that from other departments and organizations. It also can include open source data that can be culled from social networks that can provide information on public sentiment and activities.
  • Develop a scalable platform for storage and analysis. Not all of the data you are using will be under your stewardship, and it is unlikely to be in one place. This requires not only storage capacity, but also a system to access and correlate data from disparate sources and in different formats. Cloud services can be a good choice for setting up this platform, providing the scalability, flexibility and economy to take advantage of data in innovative ways.
  • Determine what you are providing to citizens in exchange for access to the data. The ultimate goal should be to provide value to citizens, and this is all the more important when you are using citizen managed data, such as that from smart metering and social media. There is a cultural and generational shift occurring in which “digital natives” are increasingly comfortable with sharing information, but willingness to share ultimately will depend on the value proposition being offered.

When everything is connected, it means that everything-no matter how insignificant-will become a source of data. Seemingly unrelated information ranging from temperatures and traffic lights to energy usage and generation of garbage could reveal previously unseen relationships that can drive improved citizen services and better public safety. As governments work toward better understanding, utilizing, and exploring these data resources, they move toward a more connected and protected society.

Source: http://www.microsoft.com/en-us/government/blogs/the-internet-of-things-it-s-all-about-the-data/default.aspx#fbid=On3wbp6hLFc

%d bloggers like this: