Around the Storage Block
cancel
Showing results for 
Search instead for 
Did you mean: 

Re: Introducing Language Bindings for HPE SimpliVity REST APIs

Manage HPE SimpliVity objects using new HPE SimpliVity Software Development Kits for popular programming languages Python, Ansible, Golang, and Terraform. The development kits simplify software development and allow for rapid build integrations.HPE-SimpliVity_SDK_blog-TW-LI.png

 

Businesses are now managing and consuming IT services across hybrid infrastructures that combine traditional IT, private cloud, and managed and public clouds. Traditional manual lifecycle operations and nonintegrated tools fail to provide the speed and simplicity businesses need to support their current IT tasks.

Some experts estimate that, in the next few years, creating a flexible, adaptive infrastructure will be among the top infrastructure and operations goals for a majority of enterprises, up from fewer than 20% of enterprises in 2019. To stay competitive, organizations can no longer afford to dedicate resources to the maintenance of legacy environments with age-old management processes that depend on time-consuming manual tasks and separate management tools.

To make it more agile, the infrastructure must be controlled programmatically through a unified API. Historically, application developers have been challenged to treat physical infrastructure the same as other application services, by defining their requirements and then calling those services using specified programming calls, or APIs. While automating the processes to provision or manage physical infrastructure has been possible, the automation logic is complex and difficult to maintain. Simple tasks like provisioning a new virtual machine (VM) with all its network and storage connections can take hundreds of lines of code.

HPE SimpliVity hyperconverged infrastructure (HCI) helps overcome these challenges, making management simple through highly automated operations controlled through software. The HCI platform empowers IT to create and deliver value instantly, continuously, with the speed and flexibility of cloud—within a customer’s own secure data center. HPE SimpliVity objects are defined in software and controlled programmatically through a unified API, thereby transforming the infrastructure into code that is optimized to the needs of the application.

The HPE SimpliVity REST API

The HPE SimpliVity REST API enables tool developers and integrators to manage HPE SimpliVity assets efficiently, intuitively, and securely. Anyone can use the REST API to gather information about, analyze, configure, and troubleshoot HPE SimpliVity hosts and federations. Moreover, tool developers can use the REST API to automate these tasks.

There are already a number of applications that have been built making use of these REST APIs to monitor, manage and analyze HPE SimpliVity specific resources. These give ISVs a gateway into the hyperconverged infrastructure through APIs thus making the app development faster which otherwise might consume much more time.

While infrastructure as a code provides the speed and agility that organizations require, it can be complex and include hidden challenges. Let’s take an example where an ISV or other user tries to leverage this API programmatically to retrieve a list of VMs on an HPE SimpliVity host named ‘Host1’.

HPE SimpliVity REST API call.HPE SimpliVity REST API call.

The high-level operations in the diagram above must also include additional requirements that are not depicted to complete a REST API request. The process requires an authentication mechanism, request handler, client creation to handle the communication, and finally a response handler to receive the JSON response.

Even with a unified API, more lines of code are required, as users have to make sure the code that they are building can handle these tasks. That extra coding slows down the software development process.

Language bindings available in HPE SimpliVity Software Development Kits

To facilitate faster integrations, HPE SimpliVity provides software development kits (SDKs) which provide language bindings for popular programming languages like Python and Golang. HPE SimpliVity SDKs provide a framework which handle all the common tasks of a REST API request/response so that the user only needs to specify the type of request. The code at the backend takes care of the rest. This enables the developers to rapidly build integrations and focus on the solution by reusing the code, rather than spending time building the framework themselves.

To demonstrate how efficient these SDKs are, I will share a side-by-side comparison of code snippets. The first snippet includes code for creating a VM backup without the usage of the Python SDK.

Note: HPE SimpliVity is sometimes referred to as “OmniStack” in screenshots and code, because that was the name of the software before HPE acquired SimpliVity.

VM backup without the Python SDK.VM backup without the Python SDK.

 

The second snippet shows code for the same VM backup using the new Python SDK for HPE SimpliVity.

VM backup with the new Python SDK.VM backup with the new Python SDK.

 

As seen above, the code using the HPE SimpliVity Python SDK is greatly simplified, allowing the end user to save valuable time and effort, and enabling the HPE SimpliVity developer community to focus on other innovations and build solutions at a much quicker pace.

Today, we have three SDKs available to interface with HPE SimpliVity REST APIs, and one more under development:

HPE SimpliVity Python SDK. This library provides Python interface for HPE SimpliVity REST APIs. The package is available as part of PyPI and can be installed directly using the Python package installer. The endpoint-support.md file in the Python repository provides a list of HPE SimpliVity objects supported.

HPE SimpliVity Ansible SDK. This repository contains modules to manage HPE SimpliVity objects using Ansible playbooks. The playbooks refer internally to the HPE SimpliVity Python package, which needs to be installed as a pre-requisite.

HPE SimpliVity Golang SDK. This SDK is similar to the Python SDK, except it provides a Golang interface for HPE SimpliVity REST APIs.

Under Development: HPE SimpliVity Terraform provider. This repository will contain a Terraform provider for HPE SimpliVity REST APIs. The SDK will use the HPE SimpliVity Golang repository internally, and the HPE SimpliVity Golang package needs to be installed as a pre-requisite.  Watch for the first version of this SDK to be released in the Terraform repository soon.

Each of the repositories has a well-documented Readme with information on the pre-requisites and required packages to be installed, and each comes with sample codes for different HPE SimpliVity objects to help users get started. Also, stay tuned to the official HPE Technology YouTube channel, where we plan to execute a sample use case and walk users through the functionalities of the different SDKs that are available.

The repositories are open source and do not need any paid licenses to use them. The repositories can also be used to raise issues, request enhancements, contribute features or get in touch with the developer community.

HPE SimpliVity SDKs

 

Madhav-E.jpg

 

Meet HPE blogger Madhav Bharadwaj, Technical Marketing Engineer for the HPE SimpliVity HCI platform. Madhav is focused on enabling and building integrations and developing solutions to enhance the customer experience.

 

 

Storage Experts
Hewlett Packard Enterprise

twitter.com/HPE_Storage
linkedin.com/showcase/hpestorage/
hpe.com/storage

 

0 Kudos
About the Author

StorageExperts

Our team of Hewlett Packard Enterprise storage experts helps you to dive deep into relevant infrastructure topics.

Comments
Ron Dharma

Great info Madhav, I recommend some other binding that are availables for SimpliVity PowerShell:

https://www.powershellgallery.com/packages/HPESvtCmdlets/

https://www.powershellgallery.com/packages/HPESimpliVity/

https://github.com/rondharma/SimpliVity-PowerShell-module

Please check out the HPE dev video: https://vimeo.com/436858869