Once the credential has been obtained, and an ap-
plication is provided for conversion by Node2FaaS, it
is subjected to a conversion process that will parse the
application code for definitions of functions to per-
form the conversion, as shown in Figure 4.
During the process, if an “include” command is
encountered, then the target file is also searched for
conversion candidate functions, and this process re-
peats recursively until no file for inclusion is found.
That way, when the application finds a role, it will
effect cloud access to create a new FaaS role. After re-
ceiving confirmation of role creation, the application
obtains the service access URI, and creates the request
within the original role definition. That way, the call
to the function remains unchanged and its operation
on the cloud platform is made completely transparent.
In the end, Node2FaaS will have generated all
the files that should make up the original applica-
tion, but with the original function code replaced by
HTTP calls to the cloud provider’s FaaS service. The
converted application maintains the same signature as
the original functions, allowing its use to remain un-
changed for the requesting processes of the functions.
This eliminates the need to make adjustments to the
application.
In order to meet the multi-provider provisioning
requirement, as advocated by the Multicloud concept,
and that the effort to keep the framework up-to-date
with the constant updates promoted by the providers
in their APIs, it was decided to adopt an orches-
trator who could assume this assignment. Several
tools were analyzed such as Cloudformation (AWS,
2019), AriaApache (Apache, 2019a), Alien4Cloud
(Alien4Cloud, 2019), Celar (Loulloudes, 2019),
DICER (Guerriero, 2019), OpenTOSCA (TOSCA,
2019), xOpera (Borov
ˇ
sak, 2019), CloudAssembly
(VmWare, 2019) and Cloudify (Cloudify, 2019),
however considering the requirements that would al-
low the Node2FaaS Framework to be incorporated de-
nies the use of Terraform (Brikman, 2017).
5 Terraform
Terraform (Brikman, 2017) is an open source tool cre-
ated by HashiCorp that allows the definition of infras-
tructure as code using a simple declarative program-
ming language (Brikman, 2017). It enables deploy-
ment and management of this infrastructure across
multiple public cloud providers (e.g. AWS, Azure,
Google Cloud, and DigitalOcean), as well as on
private virtualization platforms (e.g. OpenStack and
VMWare) using a few commands(Brikman, 2017).
Terraform currently supports over 30 different
providers. When it comes to servers, Terraform offers
several ways to configure them and connect them to
existing configuration management tools (Shirinkin,
2017). From a definition file Terraform interacts with
a cloud provider and performs the service provision-
ing according to the requested configuration. The ser-
vice can be either a virtual machine, a database, a stor-
age service, or whatever the provider supports.
Terraform tracks the momentary state of the in-
frastructure it creates and applies delta changes when
some feature needs to be updated, added, or deleted
(Shirinkin, 2017). It also provides a way to import
existing resources and target only specific resources.
It is also easily extensible with plugins (Shirinkin,
2017).
6 RELATED WORKS
The work (Spillner, 2017) brings an approach of con-
verting Python-written applications to Python deploy-
ments in the AWS Lambda service. The application
built by Spillner, called Lambada, processes a Python
application and converts it to the appropriate code to
be instantiated in the cloud. If the user has the AWS
client installed and properly configured on the ma-
chine, Lambada automatically deploys, but the entire
client setup process is up to the user. This limits the
use of this converter to users who are able to correctly
configure the provider client in their local environ-
ment.
Furthermore, that article (Spillner, 2017) is lim-
ited to using Lambada for converting single-function
applications. In production environment applications,
it is common to have multiple functions for the execu-
tion of an application. Node2FaaS, on the other hand,
enables better use in real applications, not being lim-
ited to experimental environments such as Lambada.
Spillner and Dorodko (Spillner and Dorodko,
2017) apply the same approach as Lambada, but for
Java applications. In this paper the authors question
the economic feasibility of running a Java application
entirely using FaaS, and whether there is a possibil-
ity to automate the application conversion process.
They implemented a tool called Podilizer, and per-
formed experiments using it. The results were clas-
sified as promising, however, only for academic pur-
poses, not presenting effective application capacity,
since the authors found difficulties in using the ap-
plications resulting from the conversion. On the other
hand, Node2FaaS is not simply intended for academic
experimentation, but for effective use by NodeJS de-
velopers.
The Serverless (Serverless, 2019) framework pro-
Remote Procedure Call Approach using the Node2FaaS Framework with Terraform for Function as a Service
315