From Serverless to Code-less
Tags: serverlessseptember, azure, logicapps
Published: 2020-09-22 23:26:52

This article is part of [#ServerlessSeptember](https://aka.ms/ServerlessSeptember2020). You'll find other helpful articles, detailed tutorials, and videos in this all-things-Serverless content collection. New articles from community members and cloud advocates are published every week from Monday to Thursday through September.

---

> "The only thing I like more than writing code, is not writing code."  **- Travis Webb**

---

The most secure code is code that was never written. The most clever developer is the one that writes the least code.


## The Before Time

![Astronauts](https://media1.giphy.com/media/RK9havaWZzZy9US10A/giphy.gif) &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;



<br><br>

Historically, developers self-identified by the lines of code written and the number of commits to a code repository. There were fierce debates on code syntax alone: semicolons or not, tabs or spaces, and where do the braces belong. 

---

## Now

![New Astronauts](https://media1.giphy.com/media/3xz2BzSNxkwPqF8Wdy/giphy.gif) &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

<br><br>

In this new “cloud” environment, what if writing “good code” doesn’t matter anymore? What if all the code to solve the majority of problems already exists? What if this existing code is deployed, tested, and used at larger scale than most developers ever code for? 

<br><br>

> What if going “serverless” also meant not writing code? 

---

## What. Is. Serverless?

* Event-driven architectures
* Managed services
* Pay only for what you use
* Focusing on applications, not infrastructure
* Decoupled application design from the start
* Shorter time to market
* Fewer wasted resources (like code)

<br><br>
> Note: Serverless is not simply just FaaS!

---

## The Future

![Oil Rig Astronauts](https://media1.giphy.com/media/QRXwbVxk1oViM/giphy.gif) &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

<br><br>

The future doesn't demand more code, it demands faster iteration and innovation. Writing new code is time-consuming, expensive, and full of liability. Every line created is a potential bug or vulnerability and code that must be then tested. 

---

## Builders, not Coders

In order to remain competitive, developers must become engineers, not just coders. Engineers don’t create the individual blocks, but they know to arrange building blocks together in a way to produce better quality and more reliable products. For "serverless" applications, those blocks are functions, events, and other fully-managed and event-driven services.  

![Cosmonaut fixing](https://media1.tenor.com/images/16161e7f3b0f9f7c59241d21c08b4df3/tenor.gif?itemid=13146193) &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 

<br><br>

 
Let’s now look at how moving to a serverless architecture can help to promote good engineering and reduce code. Not only can developers abstract away their infrastructure concerns, but now they also have the services necessary to build the most powerful and reliable applications to compete in a modern world.

---

**Things that you used to write a lot of code for that you should now never write a lot of code for:**

* http servers
* messaging systems
* cron jobs
* bots
* notification systems
* data parsing
* image/video parsing
* basic AI analysis

---

## Serverless on Azure

The basic building blocks for Serverless architectures on Azure:

![Azure Services](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/7586769/Screen_Shot_2020-07-26_at_1.19.07_PM.png) 

Expanded to the larger ecosystem:

![More Azure Services](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/7586766/Screen_Shot_2020-07-26_at_1.17.47_PM.png) 

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 

<br><br>

## Serverless Workflow with Logic Apps

![Harry Stamper Golf](https://media.giphy.com/media/uGvqUyMblcusM/giphy.gif)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

<br><br>

* Low code/No code visual designer
* Connects disparate functions and APIs
* Organizes workflows 
* 300+ out-of-the-box connectors for many internal and external services

---

## Hello from the year 2020  :wave: :wave:

![The End is Near](https://media1.tenor.com/images/30112930abf5ee2e383d24f5d28af6a6/tenor.gif?itemid=7204885) &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 

<br><br>

![Dwight Schrute](https://dev-to-uploads.s3.amazonaws.com/i/1172juc48b32o3vual1n.jpg) &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 

<br><br>

*Have you thought about Meteor Impacts?*

![Meteor Impacts](https://media1.giphy.com/media/d31uRIAtOKDp8EuI/giphy.gif) &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 

<br><br>

To demonstrate Microsoft Azure's low-code Serverless services, I used data from NASA's [NeoWs (Near earth object Web service) API](https://data.nasa.gov/Space-Science/Asteroids-NeoWs-API/73uw-d9i8) to create a Meteor Strike Twitter Bot and to provide data to a Microsoft Power App.

<br><br>

![App Diagram](https://dev-to-uploads.s3.amazonaws.com/i/fw384vl57dfzvljz0i35.png) 
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

<br><br>

Azure Logic App which calls the NeoWs API and parses the data:
 
![Data Parsing Logic App](https://dev-to-uploads.s3.amazonaws.com/i/w7hi6oqnx5xsqrtn47fu.png)
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

<br><br>

This Logic App calls the previous Logic App through Azure's API Management service and tweets Meteors that will be close to Earth on the current day:

![Tweet Logic App](https://dev-to-uploads.s3.amazonaws.com/i/y9nqlpa0d5m193zdul3p.png)
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

<br><br>

If there are Meteors close to the earth on the current day, tweets are generated daily by the Logic App:
{% twitter 1307721353429221377 %} &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

<br><br>

The Microsoft Power App connects to the API Management api url through a manual custom connector or [one exported from APIM](https://powerapps.microsoft.com/en-us/blog/azure-api-management-connector-on-the-power-platform/):

![Impacts Power App](https://dev-to-uploads.s3.amazonaws.com/i/oowj6bjjlq7hujuag51m.png)

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

<br><br>

![Bruce Willis Missed It](https://dev-to-uploads.s3.amazonaws.com/i/uoaxzy0pxqgxs02hcei6.jpg)  

---

You can also see a talk and live demo I did about this topic and application at Serverless Days Virtual [here](https://www.youtube.com/watch?v=K1KOHsrVzLo)!

Do you want to hear more on this topic? I'll be joining Dona Sarkar to talk about low-code serverless applications at [Create: Serverless](https://createserverless2020.splashthat.com/) next week.

You can also discuss low-code development and the "Citizen Developer" movement in a Serverless environment with me *live* next week. Please RSVP for my Community On Air - Open Mic session at [Create: Serverless](https://createserverless2020.splashthat.com/) with Jeff Hollan.

---

**More Resources:**

* [Azure Logic Apps](https://azure.microsoft.com/en-us/services/logic-apps/)
* [Azure Api Management](https://azure.microsoft.com/en-us/services/api-management/)
* [Microsoft Power Platform](https://powerapps.microsoft.com/en-us/build-powerapps/)
* [Serverless Days Virtual (July 2020)](https://www.youtube.com/watch?v=K1KOHsrVzLo)
* [APIM PowerApps Connector](https://powerapps.microsoft.com/en-us/blog/azure-api-management-connector-on-the-power-platform/)