-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathintroduction.tex
98 lines (70 loc) · 10.7 KB
/
introduction.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
\Chapter{Introduction}
\section{Background}
A long time ago, businesses used to produce their own electric power. Due to an engineering breakthrough in electric generator and transmission methods, it became easier to produce and transmit electricity to businesses that once produced their own electricity. As more businesses started buying electric power, the production of electricity become less expensive, encouraging more companies to purchase rather than make their own electricity.
And today, just like the utilities, instead of buying servers to run websites and applications, businesses rent servers and various services from cloud computing providers. These cloud resources are provided to companies in a way that resembles people renting apartments in a single building; even though you are in the same building with other people, you still have your own space. As more people rent and buy computing service from large-scale providers, the cost of these services is decreasing.
Today there are many cloud computing providers that provide different types of services. Some provide application hosting, databases, code repositories, authentication services, social network integration, etc. Some famous providers are Amazon, Google, Microsoft, Facebook, GitHub and Heroku.
Google App Engine provides infrastructure to build web applications on the same scalable systems that power Google applications. Google App Engine supports Python, Java and the Go programming languages. Google App Engine also provides several options for storing data, including App Engine Datastore, Google Cloud SQL, and Google Cloud Storage. Windows Azure provides similar services as Google App Engine but supports a different set of programming languages, including ASP.NET, VB.NET, Java, Nodejs and Python.
Amazon also provides scalable cloud computing services, which includes the popular EC2 virtual machine instances, where users choose the type of operating system and configuration they need. The virtual machine service provided by Amazon is more flexible than language-specific executation environments such as Google App Engine and Heroku, but require more time and expertise to set up and manage.
In this project, Heroku is used as a cloud application platform for running Javascript in the Nodejs executation environment. Heroku also provide alternative execution environments that support Scala, Ruby, PHP and others. One of the benefits of using Heroku (and other similar application hosting services) is that the bandwidth and CPU capacity can be scaled up or down almost instantly to accomodate rapidly changing demand. Also, by relying on Heroku to manage the hardware and system and network administration, developers gain the reliability, performance and security that is provided by a larger company with staff dedicated to these purposes.
Among all the programming language execution environments supported by Heroku, this project uses Nodejs, which supports server-side programming in Javascript. On the client side, the application uses HTML5, Javascript, Jquery library and the Bootstap framework. The applciation also relies on the MongoDB database as provided by the MongoLab service provider.
Nodejs and MongoDB are often used together to build scalable web applications. The following describe the cloud computing service providers used in this project.
\section{Technology Overview}
\subsection{Facebook}
Facebook is a popular social networking website more than one billion users. It has proven to be a good platform to use for Web applications that take advantage of its social networking features, such as friend lists, wall posting, etc \cite{Facebook}. Facebook also allows other applications to access user data with their authorization using its API.
\subsection{Heroku}
Application hosting is a form of cloud computing that enables developers to publish applications that require Internet connectivity. Heroku is one of the first companies to offer a remote Nodejs executation environment. Nodejs applications are deployed to Heroku using git \cite{Heroku}. To depoy, or redeploy, an applicaiton, the developer pushes a branch of a git repository to a remote git repository provided by Heroku. At deployment, Heroku extracts the application files from the git repository and runs the main executable, which is a server process. Heroku is a partner of Facebook and so it is designed to work easily with it.
\subsection{MongoDB}
There are many different types of cloud-based datastore services to choose from. For this project we used MongoDB because it works well with Nodejs and Heroku. MongoDB is a scalable, high-performance, open source, NoSQL document-based database. MongoDB features include document-oriented storage, indexes, replication, high availability, auto-sharding, and querying \cite{mongodb}.
\subsection{MongoLab}
MongoLab is the cloud computing provider for MongoDB database that was used in this project \cite{mongolab}. MongoLab has a free tier service that facilitates experimentation by developers, and thus was convenient for this project.
\subsection{Git}
Git is a distributed version control system \cite{github}. This project uses GitHub to store and manage a remote git repository of application source code. Git was convenient for the project because Heroku uses git as a means to deploy Web applications to its servers. Heroku's git-based deployment system allows easy creation of testing, staging, and production versions of the application.
\subsection{Bootstrap}
Bootstrap is a freely available CSS and Javascript library created by Twitter. It provides a responsive design framework that works well for applications that run inside browsers in desktop computers, tablets and smart phones \cite{bootstrap}. The application's user interface was contructed using Bootstrap.
\subsection{Jquery}
The GradeBadge application uses Jquery for AJAX transactions and DOM manipulation \cite{JQuery}. Bootstrap also depends on Jquery.
\subsection{Nodejs}
Cloud-based services support apps written in several different programming languages, such as Java, Python, PHP, Javascript, Ruby and more. For this project we used Javascript running in a Node.js context. Nodejs is a platform built on Chrome's JavaScript runtime. It's purpose is to allow construction of fast, scalable network applications. Nodejs uses an event-driven, non-blocking I/O model that makes it lightweight and efficient when used for I/O intensive applications such as Web applications \cite{nodejs}.
\section{Project Purpose}
The purpose of this project is to explore the current technologies that enable rapid development and deployment of desktop and mobile Web applications that can scale to accomodate any number of users. For this reason, a prototype of a reward application using badges, called GradeBadge, was developed to illustrate and explore this emerging paradigm.
The purpose of the GradeBadge application is to help organizations interact with and motivate their members in a fun way. It keeps the members engaged by giving badges as rewards for their efforts or achievements. In order to facilitate adoption among users, GradeBadge is integrated with the social networking site Facebook.
\section{Project Scope}
Project does not include database sharding features of MongoDB, which would allow a greater degree of scalability.
The GradeBadge application provides the following functionalities:
\begin{itemize}
\item Create Group
\item Create Badge
\item Add Member
\item Issue Badges to Members
\item View Badges Earned
\item Share Badges with Social Networking Contacts
\end{itemize}
\section{Related Work}
There are other similar mobile Web application and cloud computing demonstration projects that were built as master's degree projects at CSUSB. One of these projects was completed by Manoj Kulkarni \cite{Manoj}. This project used Google App Engine for an application hosting provider and Google App Engine datastore and Java programming language. It also used Jquery Mobile as UI framework. The GradeBadge project uses different set of technologies, and is the first project at CSUSB that utilizes Nodejs and MongoDB. Most other similar projects at CSUSB have relied on either Java, .NET or PHP.
\section{Definitions, Acronyms, and Abbreviations}
The definitions, acronyms, and abbreviations used in the document are described in this section.
\begin{itemize}
\item GradeBadge: The name of this project.
\item API: Application Programming Interface, which is a set of routines that an application uses to request and carry out low-level services performed by a computer's operating system; also, a set of calling conventions in programming that defines how a service is invoked through the application \cite{API}.
\item Cloud computing: the use of computing resources (hardware and software) that are delivered as a service over a network (typically the Internet) \cite{cloudcomputing}.
\item Jquery: A Javascript library for building web based applications \cite{JQuery}.
\item DOM: Document Object Model, which is a platform- and language-neutral interface that will allow programs and scripts to dynamically access and update the content, structure and style of documents \cite{DOM}.
item I/O: Input/Output.
\item UI: User Interface.
\item CSUSB: California State University, San Bernardino.
\item HTML: HyperText Markup Language, which is the authoring language used to create documents on the Web \cite{w3}.
\item HTTPS: Hyper-text Transfer Protocol Secure, which is a secure network protocol used to encrypt data transferred between server and client \cite{https}.
\item MVC\label{def:mvc}: Model-View-Controller is an architectural pattern used in software engineering to isolate business logic from user interface considerations \cite{MVC}.
\item UML: The Unified Modeling Language, which is the industry-standard language for specifying, visualizing, constructing, and documenting the artifacts of software systems \cite{uml}.
\item Microsoft Azure: Cloud computing platform provided by Microsoft \cite{MicrosoftAzure}.
\item Google App Engine: Cloud computing platform provided by Google.
\item Amazon Web Services: Cloud computing platform provided by Amazon \cite{AWS}.
\item Heroku: Cloud application platform provided by Heroku \cite{Heroku}.
\item Android: Mobile operating system provided by Google \cite{Android}.
\item IOS: Mobile operating system provided by Apple \cite{IOS}.
\item NoSQL: Types of databases that use key-value pairs for storing data unlike traditional relational databases. \cite{NoSql}.
\item JSON: Javascript Object Notation, which is a data representation format using key-value pairs \cite{json}.
\item Ajax: Asynchronous JavaScript and XML, which is a method for Web applications to communicate between client browsers and servers \cite{Ajax}.
\item CDN: Content Distribution Network.
\item Slug: The binary deployed to Heroku.
\end{itemize}