ES6 Promises: Patterns and Anti-Patterns

But while Promises make code more concise and readable, they can be a bit daunting to those who are only familiar with callbacks. Here I’ll lay out a few basic patterns I’ve learned while working with Promises, as well as some gotchas.

https://medium.com/datafire-io/es6-promises-patterns-and-anti-patterns-bbb21a5d0918

Advertisements

How to add a custom domain to API Gateway with Serverless

With Serverless, it’s easier than ever to deploy production-ready API endpoints. However, using AWS API Gateway results in odd hostnames for your endpoints. Further, these hostnames will change if you remove and redeploy your service, which can cause problems for existing clients.

In this guide, I’ll show you how to map a custom domain name to your endpoints.

This post is the first in a three-part series. The next post will help you set up a Serverless web backend with Flask, a popular Python microframework. The last post will help you configure multiple Serverless services on the same domain name for maximum microservice awesomeness.

https://serverless.com/blog/serverless-api-gateway-domain/

5 Handy ‘Serverless’ APIs for Web Development

Why spend time building things that you can buy or rent?

For those who have never heard of the term “BaaS” before, it stands for “Backend as a Service” and refers to third-party API services that can be integrated into your applications to build out specific functionality quickly.

For example, imagine how much work it’d take your team to build a single sign-on service for your product along with an admin interface for provisioning and managing user permissions. Sound like a pain? Well good news, there are plenty of services that you can drop-in to achieve this without writing a single line of server code.

In fact, these days there are a number of successful companies who have been able to produce compelling products with barely any of their own server-side code.

In this article, we’ll introduce five API service providers that address common features and take a look at how they work.

https://thenewstack.io/5-handy-api-services-web-development/

Android 8.0 Oreo, thoroughly reviewed

Android 8.0 Oreo is the 26th version of the world’s most popular operating system. This year, Google’s mobile-and-everything-else OS hit two billion monthly active users—and that’s just counting phones and tablets. What can all those users expect from the new version? In an interview with Ars earlier this year, Android’s VP of engineering Dave Burke said that the 8.0 release would be about “foundation and fundamentals.” His team was guided by a single question: “What are we doing to Android to make sure Android is in a great place in the next 5 to 10 years?”

Nabisco produced a limited run of Android-themed Oreos for the launch event.
Nabisco produced a limited run of Android-themed Oreos for the launch event.
Oreo

Take a closer look at Oreo and you really can see the focus on fundamentals. Google is revamping the notification system with a new layout, new controls, and a new color scheme. It’s taking responsibility for Android security with a Google-branded security solution. App background processing has been reined in, hopefully providing better battery life and more consistent performance. There’s even been some work done on Android’s perpetual update problem, with Project Treble allowing for easier update development and streaming updates allowing for easier installation by users. And, as with every release, more parts of Android get more modularized, with emojis and GPU driver updates now available without an OS update.Like its partnership with Nestlé for Android 4.4 “KitKat,” Google is taking its alphabetical snack-themed codenames to the extreme with 8.0. This time Nabisco is sharing its “Oreo” brand with Google. (We’ve yet to hear about any kind of monetary arrangement for this sort of thing). Google’s Eclipse-themed launch party was complete with custom Oreo cookies featuring an Android robot design and green filling.

Two billion users is a huge number, but with Android 8.0, Google shows that it still isn’t satisfied. A new initiative called “Android Go” targets the developing world, where cheap devices and limited access to data and power require taking a different look at how some parts of Android function.

Oreo will also serve as the base for three new Android form factors. It will be built into cars as “Android Automotive,” where Google works with car OEMs to integrate Android. Android 8.0 will also be the base OS for “Android Things,” an “Internet of things” (IoT) version of the OS designed to easily manage on embedded devices. Finally, Google’s virtual reality “Daydream” group will also launch a new form factor with Oreo: standalone VR headsets.

So, coming soon to your phone, your tablet, your watch, your TV, your car, your “things,” and your VR headset—it’s Android 8.0 Oreo. Let’s dive in.

Table of Contents

https://arstechnica.com/gadgets/2017/09/android-8-0-oreo-thoroughly-reviewed/

Run your own OAuth2 server

In this guide, you will set up a hardened, fully functional OAuth 2.0 (OAuth2) server. It will take you about ~15 minutes. This guide is for you, if you are looking to do something like in the gif on the right, or more specifically:

  • You want to use OAuth2 for API security.
  • You want to open up your API to third party developers like Dropbox, or GitHub.
  • You want to become and identity provider like GoogleFacebook, or Twitter.
  • You need to federate (delegate) authentication or authorization.

We will use ORY Hydra (open source), a security-first OAuth2 and OpenID Connect server written in Golang.

https://www.ory.am/run-oauth2-server-open-source-api-security.html?