Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Scale REST Services on Microsoft Azure

DZone's Guide to

Scale REST Services on Microsoft Azure

· Cloud Zone
Free Resource

Deploy and scale data-rich applications in minutes and with ease. Mesosphere DC/OS includes everything you need to elastically run containerized apps and data services in production.

Microsoft Azure cloud is a great place to install and run your REST API services.  Mobile and web development on Azure includes features like elastic scaling, API management, monitoring and alerts, as well as identity management using Azure Active Directory.  Espresso Logic gives developers ease of installation and a declarative rich implementation of RESTful endpoints to integrate your existing SQL database(s)  and other backend systems.

Declarative means you just declare what you want for an Enterprise-class API:

  1. API: Default created instantly, then point and click Custom Resources with nesting and aliasing.  Runtime support for filtering, pagination, optimistic locking, generated keys, etc.
  2. Integrate: add new data sources (databases, ERP systems), use in Custom Resources
  3. Enforce: logic and security with spreadsheet-like Reactive Programming expressions, plus JavaScript based on an automatically created Object Model

Espresso Logic offers multiple delivery options for cloud or on-premise including a VM Appliance, a docker installation, and a WAR file on Azure.

components

Azure Portal

The new look and feel of the Azure portal is a great improvement and the ‘blade’ design showing and editing properties makes the process much easier to understand and to navigate. (try: http://www.portal.azure.com)

Portal

Create a new Web App + MySQL WebAppMySQLIcon

To get started – go to the Market Place (above) or click BROWSE and search for Web app + MySQL Once the web app has been provisioned – you will need to create an empty database in MySQL which will be used to store the api metadata.  Once you have an empty MySQL database, username, and password setting you can go  to your new Web App tile and using the Settings gear or the All Settings and you can configure various system properties.

HomeWebBlade

On the Application Settings blade You will want to select Java 1.7.0.51 and Tomcat 7.0.53. On the Connection String set the Connection name to AdminDB and the connection properties which will point to your empty MySQL instance. (Make sure you have created an empty database with the name you enter in the properties along with a valid user and password using the template below). For details on MySQL setup see this link.

  1. Database=dbtest;Data Source=db.espressologic.com;User Id=dbtest;Password=Password!

Settings

GitHub Fork

The Espresso Logic Cafe GitHub account has many sample applications, simply fork the AzureInstall project.  Then link your fork to the Deployment settings of your new Web App.  This will copy the new EspressoService.war to your webapps directory (D:\home\site\wwwroot\webapps).  You  can also manually FTP the WAR file to this directory and restart your service.

Launch when ready

To test your your Espresso Logic Service, from the Web App Blade click (URL) or you can click the Browse icon. (On the first connection to the Web App, the WAR file will be installed and the admin repository will be created in your empty MySQL database instance.) For more information visit Espresso Logic or see the documentation page for Azure Installation.

http://myazurewebsite.azurewebsites.net/EspressoService/LogicDesginer/index.html

You should see a logon dialog that looks like this (the LogicDesigner Studio is a web based tool to create and manage your REST, Logic, and Security services).

LogonDialog

Next Steps

Once you have logged into the Logic Design Studio – on the menu bar under Project: click the dropdown and add a new project. Select your database and Espresso will create REST API endpoints for every table, view, and stored procedure.  You can also create custom user-defined nested documents using the ‘Custom Resource’ menu bar on the left. Transaction logic and security can be added and the system is open and extensible to add new services and features using Java or server side JavaScript.

Summary

Espresso on Azure gives developers a declarative approach to manage and build robust enterprise REST services.  More than a SQL passthrough, Espressos includes optimistic locking, filtering, pagination, row and column level security, declarative user logic to enforce business transaction logic and server side JavaScript for events and formula. This is a truly the fastest way to deliver open, extensible, and scalable mobile and web applications on Azure.

Discover new technologies simplifying running containers and data services in production with this free eBook by O'Reilly. Courtesy of Mesosphere.

Topics:

Published at DZone with permission of Val Huber, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

THE DZONE NEWSLETTER

Dev Resources & Solutions Straight to Your Inbox

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.

X

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}