Open Source For You — December 2017

(Steven Felgate) #1
90 | DECEMBER 2017 | OPEN SOURCE FOR YOU | http://www.OpenSourceForU.com

Developers Let's Try



  1. Services



  • Service broker: Cloud Foundry has external components
    like a database, SaaS applications and platform features
    (e.g., the platform can offer services for analytics or
    machine learning), which are classified as services. These
    services can be bound to an application and be consumed
    by it. The service broker is responsible for provisioning an
    instance of the service and binding it to the application.



  1. Messaging



  • The platform’s component VMs communicate with each
    other and share messages over HTTP and HTTPS. This
    component is responsible for sharing messages, and also
    storing long-lived data (like the IP address of a container in
    a Consul server) and short-lived data (like application status
    and heartbeat messages) on Diego’s bulletin board system.



  1. Metrics and logging



  • Metrics collector: This collects statistics from the
    components, which are used for book-keeping and health
    management by the framework as well as by the operators
    managing the infrastructure.

  • Loggregator: Applications built on top of the Cloud
    Foundry stack need to write their logs on the system output
    streams. These streams are received by the Loggregator,
    which can be used to redirect them to file systems,
    databases or to external log management services.
    Cloud Foundry is a highly scalable, easy-to-manage, open
    source platform that can be used to develop applications of all
    types and sizes. To get further information about the ecosystem,
    you can visit https://www.cloudfoundry.org.


to download, and how to configure the apps to communicate
with bound services. Services are often externally managed
components that may or may not be hosted on the Cloud
Foundry stack (examples include databases, caches, etc). They
are available in the marketplace, and can be consumed by the
application by binding to them.

Cloud Foundry architecture
Cloud Foundry components can be broadly classified
under the following categories.


  1. Routing



  • Router: This is the entry point into the Cloud Foundry (CF)
    instance. CF provides REST services for administration
    purposes too. So, the call is initially received by the router
    and redirected to the cloud controller, if it’s an administration
    call, or to an application running on the stack.



  1. Authentication



  • User account and authentication (UAA) server: The role of
    the UAA server is to log in users and issue OAuth tokens
    for those logged in, which can be used by the applications.
    It can also provide SSO services, and has endpoints for
    registering OAuth clients and user management functions.



  1. Application life cycle



  • Cloud connector: The cloud connector is responsible for
    the deployment of applications. When you push an app to
    CF, it reaches the cloud connector, which coordinates with
    other components and deploys the application on individual
    cells in your space.

  • Application availability components (nsync, BBS
    and Cell Reps): These components are responsible
    for the health management of the applications. They
    constantly monitor an application’s state and reconcile
    them with their expected states, starting and stopping
    processes as required.



  1. App storage and execution



  • BLOB storage: This is binary storage, which stores your
    application binaries and the buildpacks that are used to run
    the applications.

  • Application execution framework (Diego): Application
    instances, application tasks and staging tasks all run as
    Garden containers on the Diego cell VMs. The Diego cell rep
    component manages the life cycle of those containers and the
    processes running in them. It reports their status to the Diego
    BBS, and emits their logs and metrics to Loggregator.


Figure 1: Cloud landscapes


Figure 2: Cloud Foundry architecture

By: Shiva Saxena
The author is a FOSS enthusiast. He currently works as a
consultant, and is involved in developing enterprise application
and Software-as-a-Service (SaaS) products. He has hands-on
development experience with Android, Apache Camel, C#, .NET,
Hadoop, HTML5, Java, OData, PHP, React, etc, and loves to
explore new and bleeding-edge technologies. He can be reached
at [email protected].

Metrics Collector Loggregator

Service Broker

Application Execution
Framework

Cloud Controller Application availability services

UAA Server

Router Routing

Authentication

App Lifecycle

App Storage
and Execution

Metrics and
Logging

Messaging

Services

BLOS Store

Components for internal communication between VMs
Free download pdf