Wednesday, April 6, 2016

Add Elegant Maps to Your Android App with MapBox

Mapbox is open source SDK for pixel-perfect vector maps that promises the render speed and smoothness of a video game. If you are interested in integrating map functionality in your apps then Mapbox is a choice worth considering.

The Mapbox Android SDK overview and examples are a good starting point. In this tutorial I will create something more complex, an app that draws the best route from origin to destination on a map.

Let’s get started!

Continue reading %Add Elegant Maps to Your Android App with MapBox%


by Valdio Veliu via SitePoint

Getting Started With Ionic: JavaScript Components

jQuery.mark – jQuery Keyword Highlighting

jQuery.mark is a jQuery plugin to highlight text with diacritics, synonyms, custom elements, custom class names, separate word search (multiple terms), filter selectors, word boundary and iframe support. Compatible with DataTable.


by via jQuery-Plugins.net RSS Feed

This Week's HTML5 and Browser Technology News (Issue 234)


Read this e-mail on the Web
HTML 5 Weekly
Issue 234 — April 6, 2016
Leonie Watson
HTML5 was released in 2014, but now the Web Platform Working Group (WP WG) is working towards an HTML5.1 release in the next six months.


Microsoft
A tool to visualize and analyze the API overlap between standards specifications and support across Edge, Chrome, Firefox, and Safari.


Apple
A new browser for devs to get an early look at upcoming technologies in Safari, including layouts, visual effects, and dev tool improvements.


Mailgun  Sponsored
If you're looking to switch email providers or are experiencing email deliverability issues, you can easily migrate to Mailgun. You will have access to great features like seeing the analytics of your emails or viewing the full raw MIME of your messages. See how to migrate and enjoy 10,000 free emails per month.

Mailgun

Chris House
A comprehensive guide to Grid, as things stand in the latest spec. Grid is a 2D, grid-based layout system that may change the way we build grid-based Web UIs.


Robin Wauters
Opera’s former CEO is behind the effort along with a rather extensive team. The interface is built using JavaScript and React.


Aaron Gustafson
An explanation of how an idea becomes a specification at the W3C.


Scott Lininger
Uses WebGL and voxels rendering to create a pixel-perfect replica of the original, all in JavaScript. (Check it out before Nintendo take it down?)


Robin Linus
A demo of all the data your browser can figure out or provide about you — without asking you for any permission.


Jobs

In brief

Curated by Peter Cooper and published by Cooper Press.
Want to post a job? E-mail us or use our self-serve system.

Unsubscribe : Change email address : Read this issue on the Web

Published by Cooper Press Ltd. Office 30, Lincoln Way, Louth, LN11 0LS, UK


by via HTML5 Weekly

Containerized PHP Development Environments with Vagga

It happens to all of us once in a while.

We clone a project, and then we try to run it. However, something doesn’t work.

Broken car image

It may be our version of NGINX or Apache. It might be that npm isn’t doing something right. Maybe the project needs an extension, and we don’t have it installed, and now we have to build the extension from source because the dependency does not exist in the repositories for our distribution. No matter the reason, the more complex the setup, the higher the probability of failure.

When I first got to know Vagrant, it was like heaven: there was finally a chance to break free of the shortcomings of Windows, while not having to deal with the accessibility issues present in Linux.

I was happy. For a while. And then the limitation of having virtual machines as development environments hit me. Hard.

Imagine this scene: it’s 4:30 PM. The developer working on the Asterisk system has left the company. Something in the payment logic (written in PHP using the deprecated PHPagi project) doesn’t work, and you have to fix it, fast. You and a colleague have been urging everyone toward a service-oriented architecture, and so, to be able to bring up a development environment, you have to have the following:

  • An instance of the Asterisk machine which handles calls. It must have Asterisk and PHP 5.5.X running.
  • An instance of another Asterisk machine which actually handles the payment. Since the bank you are working with has a policy of closing all access to its APIs coming from outside the building, this is a copy of the machine above, but with different code running on it.
  • The PHP back-end API that does the heavy lifting, written in PhalconPHP.

So you tape together some puppet scripts to provision your boxes, you vagrant up three machines, and prepare to enter the zone!

If this was a movie, the scene would zoom into your host machine at this point, dramatically showing the large amounts of data traveling at light speed between different parts of your system, filling up your memory and CPU, and then coming to a grinding halt. However, since this is not a movie, suffice it to say that your development machine might be able to handle one or two boxes with 8 GB of memory on Windows, but when the third machine comes up, your development environment is going to be slow to the point that you will not be able to launch an IDE.

Of course, you are very clever and resourceful, and know how this stuff works. You’d lower your memory and CPU in your vagrantfile, but that leads to Asterisk complaining about a small memory size, and when you manually call your phone system with a softphone (equivalent to a browser in the online world) to test it, the audio breaks up and distorts. You need a lot more memory than you already have, and you don’t have access to it, and now it’s 10:30 PM.

So what happens to you?

Nothing good. You fail to fix the problem that night, have to deal with an angry boss who doesn’t have the technical background to understand what you are talking about, come back to work tomorrow, tell two of your colleagues to run one of the needed machines from the list above on their own machine, and you string these virtual machines together to get the code to run. Oh, and let’s not forget the problems you have with building all the dependencies because they weren’t documented anywhere. That’d just be too ugly.

But all problems give rise to new opportunities: enter Vagga, a way to set up your project and its dependencies (usually) with a single command, with far less resource usage.

What is Vagga?

Vagga is a container engine, like Docker, which has been created to make it easier to build development environments. Since it is a fully-userspace container engine, it loads much faster than Vagrant, takes much less memory, and allows you to do awesome things like run your application in different environments in just a few seconds, without waiting for a completely virtualized machine to boot up.

Vagga is in beta stage right now and it is likely you might face some problems, but the concept shows great promise, and that’s why we have decided to take it for a spin.

Continue reading %Containerized PHP Development Environments with Vagga%


by Parham Doustdar via SitePoint

Baptiste Briel

opl-small

Slick dark-schemed AJAX loading One Pager for creative developer, Baptiste Briel.

by Rob Hope via One Page Love

Managing Data Storage with Blockchain and BigchainDB

There’s no denying that whilst Bitcoin’s future may be hazy right now, the underlying technology it relies upon — the Blockchain — has revolutionized many industries and projects, with more to come.

Ascribe is a fascinating startup that uses Bitcoin’s Blockchain to record a limited quantity of unique references to digital artworks. Thus making them traceable, accountable and (hopefully) more valuable, due to this finite amount of ‘copies’.

Ascribe hit technological problems with this approach, and those problems were primarily due to Bitcoin’s Blockchain itself. Writing everything to it is slow, costly (currently 80c each time) and has a maximum number of daily entries and total capacity for writes. It’s also counter to typical scalable database technologies, adding nodes doesn’t improve performance and has no real query language. This makes scaling a business that relies upon the Bitcoin Blockchain a challenge.

But the Blockchain concept is a strong one and the past years have seen an increasing rise in usage and legitimacy, with even major banks announcing development of technologies inspired by the concept.

Ascribe decided to combine the best of both worlds, taking a proven NoSQL database (RethinkDB) and adding a Blockchain layer on top to add control, asset tracking and an additional level of security.

This combination of technologies is especially interesting to NoSQL database users, as traditionally, few of them support ‘transactions’ that help guarantee a database change has taken place. By writing to an underlying NoSQL database via a Blockchain layer, BigchainDB adds transactional support.

Thanks to the Blockchain layer, BigChainDB also claims to be fully decentralized. Whilst many distributed NoSQL databases claim this, there is often a pseudo master/slave setup.

Installing BigChainDB and Dependencies

There are couple of ways to install BigChainDB. First I tried the Docker images, but ran into some connection issues, finding the Python packages most reliable.

  1. Install RethinkDB, for other Mac users, there is also a Homebrew package available.
  2. Install Python 3.4+.
  3. Install BigChainDB with Pip - sudo pip install bigchaindb
  4. Start RethinkDB with rethinkdb
  5. Start BigChainDB with bigchaindb start which will also configure things for you.
  6. Open the BigChainDB (actually the RethinkDB UI) admin UI at http://SERVER_IP:58080/

Simple Example - Message Allocation and Tracking

One of BigchainDB’s prime use cases (and why Ascribe created it), is for tracking assets, so let’s make a simple example in Python.

[code language="bash"]
pip install bigchaindb
bigchaindb configure
bigchaindb show-config
[/code]

Create a new file, app.py and add the following:

[code language="python"]
from bigchaindb import Bigchain
b = Bigchain()
print(b)
[/code]

This imports the bigchaindb library, creates a new object and connects to it with the settings file just created.

Then run the Python application:

[code language="bash"]
python app.py
[/code]

Continue reading %Managing Data Storage with Blockchain and BigchainDB%


by Chris Ward via SitePoint