Professional Documents
Culture Documents
Cloud computing is a model for enabling ubiquitous(where-ever), convenient, on-demand (when-ever) network access to a shared pool of configurable computing
resources that may be shared and can be rapidly provisioned and released with minimal management effort or service provider interaction .
High Performance Computing (HPC) providing this capability for short amounts of time (no-longer optimal)
(How quickly and how correct are the solutions)
Homogenous nodes where performance increases due to presence of more computational power, it can be thought as an increase of computational resources
present in a workstation to a mammoth scale.
High Throughput Computing (HTC) what is needed using distributed and parallel computing.
(How to handle parallelization of given problem )
Distributed computing where given problem is split and scheduled among various resources
Computing paradigms
Distributed computing: A system that consists of multiple autonomous computers, each having its own private memory, communicating through a network, which
is accomplished using message passing.(Multiple independent computers connected to one another through some network)
Include features such as fault tolerance , concurrency of components.
Architectural Models:
Cluster computing: A cluster is a set of loosely or tightly connected computers that work together so that, in many aspects, they can be viewed as a single system.
They all run the same image of the OS.
Each node in a cluster is tasked to perform the same task, scheduled by the software.
It is a hierarchical construction of a network which can be scaled by increasing the number of nodes.
The cluster is connected to the Internet via a VPN (virtual private network) gateway, the gateway IP address locates the cluster.
The system image of a computer is decided by the way the OS manages the shared cluster resources.
All resources of a server node are managed by their own OS, thus most clusters have multiple system images as a result of having many autonomous nodes under
different OS control.
P2P computing: Every node acts as both a client and server, peers autonomously join or leave the network.
No central coordination or central database is needed, no peer machine has a global view of the entire network.
It is self-organizing system with distribute control, this implies that no master-slave relationship exists among the peers.
Processing and communication loads for access to objects are distributed across many computers and access links.
Client-Server Model: System is structured as a set of processes, called servers, that offer services to the users, called clients.
It is usually based on simple request/reply protocol, implemented with send/receive primitives or using RPC.
The client asks the server for a service, server does the work and returns the result or the error code if the required work can't be done.
Interaction Models:
Synchronous Distributed Systems: Lower and upper bounds on execution time of processes can be set
Transmitted messages are received within a known bounded time
Drift rates between local clocks have a known bound
Parallel computing: All processors are either tightly coupled with centralized shared memory or loosely coupled with distributed memory.
Communication between processors is achieved using shared memory or message passing. (Single computer with many processors)
Architecture involves several processors simultaneously executing multiple, smaller calculations broken down from overall larger, complex problem.
These smaller pieces are independent in nature.
Results are combined upon completion as part of overall algorithm.
Computation requests are distributed in small chunks by the application server that are then executed simultaneously on each server.
It also offers:
Application checkpointing: To help provide fault tolerance, to help restart from point in instance of failure
Automatic parallelization: Conversion of sequential code to parallel code
Parallel Programming Languages: Help in developing programs that use shared memory.
Resources sharing agreements are needed to formed among set of participating parties (Direct access of resources to other users).
Computational grid is a hardware and software infrastructure that provides dependable, consistent, inexpensive access to high-end computational capabilities.
Data grid is storage component of the grid. Data is often distributed , this grid provides access to local and remote data required to complete compute intensive
calculations.
Grid Environment:
Grid information Service: System collects details of resources available and passes it resource broker.
User: Send computation or data intensive application to Global Grid in order to speed up the execution of application
Resource Broker: Distribute jobs in application to grid resources based on users requirements and availability.
Grid Resources: Clusters, PCs, Supercomputers, Databases in global grid to execute users jobs.
Note: Grid network can be thought as an interconnection of clusters and usually has thousands of hosts
• Infrastructure (as service): The physical resources are abstracted into virtual servers and storage.
The compute, storage and networking resources are available on-demand, on pay-as-you go basis.
The virtual resources are allocated on demand to cloud users, and these can be configured into virtual systems on which and d esired software can be installed.
Offers the greatest flexibility from the available options but also is the most difficult to manage and configure.
Suited for users who want complete control over the application/software stack that they run
• Platform (as service): Provides a platform built on top of the abstracted hardware that can be used to develop applications by developers.
It has commands available that will allow them to allocate middleware servers (a database of certain kind, OS of certain kind ) , configure and load data into the
middleware.
We can develop an application that runs on top of the middleware.
• Software (as service): Provides the complete application as a service, enabling consumers to use the cloud without worrying about all the
complexities of hardware, OS or even application installation.
It provides the least flexibility amongst the options.
Technology challenges
• Scalability: ability to accommodate larger or smaller loads while supporting some of the expectations of QoS (Quality of service) like r esponse time.
This will need to support:
Scale with the spread of wide range of environment
Sharing of the same with many users.
• Elasticity: actual/practical increase or decreasing the resources to cope with loads dynamically.
Scale up (vertical scaling) : creating resources using virtualization
Scale out (Horizontal scaling): actually adding hardware resources
Scale down
Resource allocation and workload placement algorithms are required
• Performance Unpredictability : Resources are shared. We have to guarantee performance isolation of shared resources.
• Reliability and Availability : Hardware failures and software bugs can be expected to occur relatively frequently.
Problem is complicated by the fact failures can trigger further failures, leading to avalanche of outages.
Factors affecting reliability and availability
High number of components
Complexity
• Security: Considerations towards violation of confidentiality, data privacy, and data leakage and loss.
Isolation of users, legal and process issues (physical security)
Cloud service provider are providing auditable and safe identity management, access control procedures for authentication and authorization,
use firewalls, encryption, privacy protocols, recovery policies, SLA's, etc.
• Compliance: Process of meeting the requirements of the service users or it could be the laws of the country.
The technology will need to enable business operations to comply with the expectations of customers.
Challenge for user would be to know if a cloud provider is complying with privacy rules, or the laws and for the cloud servic e provider to be enabled
by technology for compliance.
• Multi-Tenancy: Mode of operation where a single instance of the component serves multiple tenants or groups of users.
Resource Allocation: Tenants outside the providers firewall share cloud services and virtual resources that come from the providers
set of infrastructure, platforms and software.
Usage Agreements: While resources are distributed on an as-needed basis, a pay-per-use model isn't necessary component.
Some customers use public clouds at no costs.
Management: At a minimum, the provider maintains the hardware underneath the cloud, supports the network, and manages the
virtualization of the software.
Private Cloud: It utilizes the in-house infrastructure to host the different cloud services.
It is computing model that offers a proprietary environment dedicated to a single business.
The strategy might consist of hardware hosted locally at a facility owned by a business, or may be hosted by a cloud service provider.
Virtual private clouds are typically paid for on a rolling basis, but provisioned hardware and storage configurations maintain the benefits
of a secure, exclusive network.
Internal private cloud: It is hosted on organizations own premises, and is managed by them internally.
The organization manages and operates the internal cloud themselves.
This means they will purchase the servers, keep them up and running and administer the software that runs on the servers.
Hosted private cloud: It is off-premise instead of on-premise, meaning the cloud servers are not physically located at the grounds
of the organization using them. Instead, a third party manages and hosts the cloud remotely.
Hybrid Clouds: Cloud computing environment that uses a mix of on-premise, private cloud and third-party, public cloud services.
It involves a connection from the an on-premise data center to a public cloud.
It allows enterprises to deploy workloads in private IT environments or public clouds and move between them as computing needs and costs change
Helps in providing greater flexibility and more data deployment options.
Workload includes the network, hosting and web service features of an application.
Cloud Architecture
Refers to the various components engineered to leverage the power of cloud resources to solve business problems.
Cloud architecture defines the components as well as the relationships between them.
Frontend:
Backend:
It consists of the application server (application logic and most of the business logic) and data(storage server and part of the business logic)
It used by the service provider. It manages all resources that are required to provide cloud computing services.
It includes: Data storage, Security, VM's , deploying models, servers, traffic control mechanisms, Fault tolerance, Billing, Backups, Scaling.
Set of components involved in backend are:
1. Application: Part offered for the client application which will use the cloud.
2. Service: Piece of software, will determine and enable the appropriate service to be accessed.
3. Runtime cloud: Provides the execution and runtime environment to the VM dependent on the service model
4. Storage: Provides a huge amount of storage capacity in the cloud to store and manage data.
5. Infrastructure
6. Management: Components such as application, service and infrastructure needs to be managed and coordination between them need s to be established.
7. Security
Compute: Providers manage the hypervisors and end users can then programmatically provision virtual "instances" with desired amounts of compute and memory.
Most providers offer both CPU's and GPU's for different types of workloads.
Cloud compute also typically comes paired with supporting services like auto scaling and load balancing that provide the scale and performance
Characteristics that make cloud desirable in the first place.
Network: Is a form of Software Defined Networking in which traditional networking hardware, such as routers and switches, are made available programmatically.
Storage: Three primary types of cloud storage are block, file and object.
Block and file are common in traditional data centers but can often struggle with scale, performance and distributed characteristics of cloud.
Object storage is highly distributed, it leverages commodity hardware, data can be accessed easily over HTTP, and scale is not essentially limitless but performance
scales linearly as the cluster grows.
Programming Model
It is an execution model linked into an API or particular pattern of code, they are 2 execution models in play:
1. Base programming language
2. Programming model
Language execution models does not change on the cloud, but there is an independent execution model of the programming model
The eco-system for a program execution in terms of compute, memory, storage, networks and IP addresses which were available locally on system is now not
guaranteed and would need to be factored in. It will also need to ensure that requisite environment is setup for each of the different service models of the cloud.
Basically not only think about how to structure your code but also thinking about the run time environment and all the dependencies it will need for it to run on
cloud which could include the compilers, the OS, the network connections to the system, how the program and its data will be stored, etc
2. Stateless Constraint:
Communication between the client and the server must remain stateless between requests.
Each request the client makes should contain all the information needed for the server to answer successfully.
All of the state information should be transferred back to the client as part of the response and cannot take advantage of an y stored context on the server.
Session state is kept entirely on the client.
3. Cache Constraint:
In order to improve network efficiency, cache constraint are added and require that the data withing a servers response to a request, be implicitly or explicitly
labeled/marked as cacheable. If a response is cacheable, then client cache is given the right to reuse that response data for later.
Stateless Interactions:
Systems that follow the REST paradigm are stateless, meaning that the server does not need to know anything about the state of the client and vice versa.
Both the server and client can understand the messages, even without seeing previous messages.
Each client request is treated independently.
Clients isolated against changes on the server.
Promotes redundancy (unlocks performances): doesn’t really need to know which server client was talking to, No synchronization overhead.
Representation:
It is the snapshot in time of the state of a given resource.
Sequence of bytes made up of data, plus representation metadata to describe those bytes.
It capture current or intended state of the resource and helps transferring that representation between interacting components.
Message type is hypermedia, which refers to any content that contains links to other forms of media such as images, movies and text.
It allows the client to navigate to the appropriate resources by traversing the hypermedia links.
Self-Descriptive Messages:
Messages includes enough information to descriptive how to process the message.
It enables intermediaries to do more with message without parsing the message contents.
Resources are decoupled from their representation so that their content can be accesses in a variety of standard formats.
It empowers clients to ask for data in a form they understand.
Web services
A software system designed to support interoperable machine-to-machine interaction over a network.
It is referred to as self-contained, self-describing, modular application designed to be used and accessible by other software applications across the web.
Once a web is deployed, other applications and other web services can discover and invoke the deployed service.
Other systems interact with the web service in a manner prescribed by its description.
SOAP
It is a protocol which was designed before REST came into picture. Main idea behind creating SOAP was to ensure that programs built on different platforms and
programming languages could securely exchange data.
It provides a structure for transmission of XML documents over various internet protocols, such as SMTP, HTTP and FTP.
Messages consists of elements called envelope, which is used ort encapsulate all of the data in the SOAP message which contains a Header element the contains
Platform as a Service
It is a complete development and deployment environment in the cloud with resources that enable you to deliver cloud-based apps.
Purchase of resources need from a cloud service provider on pay-as-you go bases and access them over a secure internet connection.
Abstractions provides a platform built on top of the abstracted hardware that can be used by developers to build cloud apps.
This platform is delivered via the web, so developers have the freedom to concentrate building the app rather than focusing on the OS, infrastructure.
It provides servers, storage, networking but also middleware development tools, business intelligence (BI) services, DBMS.
It is designed to support the complete web application lifecycle : building, testing, deploying, managing and updating.
Advantages of PaaS:
1. Faster time to market: There's no need to purchase hardware, install it and maintain it, we can simply use clouds infrastruct ure and start development process.
2. Faster, easier, less risky adoption of a wider range of resources: PaaS platforms typically include access to a greater varie ty of choices up and down the
application development stack.
3. Develop for multiple platforms including mobile devices: Some service providers give you development options for multiple pla tforms
4. Easy, cost-effective scalability: Application developed and can be scaled on demand by purchasing the right amount of additional capacit y needed.
5. Efficiently manage the software lifecycle: It provides all of the capabilities that you need to support the complete web appl ication lifecycle: building, testing,
deploying, managing and updating within the same integrated environment.
6. Lower costs: Charges users based on usage of resources and there's no initial investment for infrastructure and its setup.
7. API development and management: Develop, run, manage and secure API's and microservices.
8. It can support IoT
Limitations of PaaS:
1. Operational Limitation: Customized cloud operations with management automation workflows may not apply to PaaS solutions, as the platform tends to limit
operational capabilities for end users.
2. Vendor lock-in: Business and technical requirements that drive decisions for specific PaaS solution may not apply in the future.
If vendor has not provisioned migration policies, switching to another provider will be not be possible without effecting the business.
3. Runtime issues: Solutions may not be optimized for the language and frameworks for the developers choice. Specific framework versions may not be available
or perform optimally with the service.
4. Data security: Organizations can run their own apps and services using PaaS, but data residing in third -party vendors poses security risks and concerns.
5. Integrations: Complexity of connecting the data stored within an onsite data center or off -premise cloud is increased, which may affect which apps and services
can be adopted using PaaS.
Interaction styles
1. Synchronous (request-response): TCP features
2. Asynchronous : Client doesn’t block, and the response, if any, isn't necessarily sent immediately, can support high rates of data flow.
Advantages:
a. Reduced coupling: Message sender doesn’t need to know about the consumer
b. Multiple subscribers: Multiple consumers can subscribe to receive events.
c. Failure isolation: If consumer fails, the send can still send messages, the messages will be picked up when the consumer recovers
d. Load leveling: A queue can act as buffer to level that workload, so that receivers can process messages at their own rates
Disadvantages:
a. Coupling with messaging infrastructure: Using particular messaging infrastructure may cause tight coupling with infrastructure. Difficult to switch later
b. Latency: Latency of operation increases if queue fills up
c. Complexity
d. Throughput: Each message in message queue requires at least one queue operation and one dequeue operation.
Virtualization
It is a framework or methodology of dividing the resources of a computer into multiple execution environments, by applying one or more concepts or technology such as
hardware/software partitioning, time-sharing, partial or complete machine simulation, emulation, quality of service, and many others.
It is a practice of presenting and partitioning computing resources in a logical way rather than partitioning according to physical reality.
Virtual machine (VM) is an isolated duplicate of the physical machine; It's an execution environment (logically) identical to a physical machine, with the ability to execute a full OS
In traditional environment OS handles the bare hardware and also provides environment for development and execution of applications.
In virtual machines there exists an additional layer between the hardware and the applications called the hypervisors/virtual machine monitor which allows the user to create
multiple independent environments upon the same hardware where each environment is oblivious to the fact that it is sharing its resources with others.
Each time programs access the hardware, the hypervisor captures the process, in the sense it acts a traditional OS
Types of VM
Type 1 (Bare metal): VMM runs on bare metal directly controls the hardware; more prevalent in the industry, Example: VMWare ESX server, Xen
Type 2 (Hosted) : VMM runs as part of/on top of the host OS; used more in commodity devices, Example: Oracle Virtual box, VMWare workstation
Hybrid : Host VM runs directly on top of hardware, there also exists a hypervisor upon which guest VMs can be run
Paravirtualization: Modification of the guest OS to run the hypervisor, the hypervisor provides APIs for the guest OS.
Useful if source code of the guest OS is modifiable, example: Linux, Xen, MVS
Guest OS in not completely isolated but is partially isolated by the VM from the VMM and the hardware. The guest OS is aware that it is running in a virtualized environment.
It leverages hypervisor API (hyper call): Special I/O APIs vs emulating hardware I/O , i.e. it has modified drivers to communicate with the hypervisor
Performance degradation is a major issue of a virtualized system. No one wants to use a VM if it's much slower than using a physical machine.
It attempts to reduce the virtualization overhead, thus improves performance by modifying only the guest OS kernel.
Applications or user processes are not trusted with executing privileged instructions, and will need to be run with privileges assigned by the OS.
Since OS manages the hardware, the instructions must be safely executed, to do so it uses a ring structure: Ring 0,1,2,3
Ring 0- offers the highest level of privileges as needed for the instruction, Ring 3- where applications run on minimal privileges.
In transparent virtualization:
Hypervisor traps privileged instructions and emulated (Access to physical pages, Physical I/O devices, Control registers)
Handling privileges: All processors have rings of privilege, run the hypervisor in Ring 0 (highest privilege), run guest in lower ring
The monitor most know the state of the VM, it must also decide if emulation, translation or direct execution is allowed.
These add as overheads, and slow down the execution of the VM