Vous êtes sur la page 1sur 70

Video Recommendation Based on Cloud 2017

1. INTRODUCTION

In recent years, online social networks (OSNs) have been massively growing, where users
can share and consume all kinds of multimedia contents. As a result, given the numerous
different genres of videos in social media, how to discover the videos of personal interest
and recommend them to individual users are of great significance. Recommendation is
foreseen to be one of the most important services that can provide such personalized
multimedia contents to users. There are several successful video recommendation
algorithms and systems that have been developed and exploited. For example, Google has
adopted content-based filtering (CB) recommender system in its AdWords services. The
Google search engine returns search results with keyword related advertisements.
However, those advertisements are always neglected by end users. This is mainly because
of the biased decisions of users’ favorite content. Unfortunately, Google AdWords had
been removed from the right side of the page. Amazon and Taobao have achieved great
success in recent years.

Several companies have demonstrated initial successes in multimedia recommendation


system design. That reported that YouTube won its first Emmy for video
recommendations. Actually, most OSNs recommend video content to their users based on
the user’s rich context information (e.g., social status, ages, professions, health conditions
and hobbies) contained in their released multimedia data. Regarding this way, several
recommendation systems have been proposed.

1.1. Objectives

With the accurate classification rules, the context details are not necessary to compute,
and the huge network overhead is reduced. Moreover, user contexts, user relationships,
and user profiles are collected from video-sharing websites to generate multimedia
recommendation rules based on the Hadoop platform.

When a new user request arrives, the rules will be extended and optimized to make real-
time recommendation. The results show that the proposed approach can recommend
desired services with high precision, high recall, and low response delay.

1
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

2. PROBLEM STATEMENT AND PROPOSED


SOLUTION

2.1. Problem Statement


 The project is to present a differential private distributed learning framework for
video recommendation for online social networks.

 Difficult to identify the Spammers in online.

 Noise and inconsistencies inherent to the data, and illustrates the difficulty of the
task.

 That the proposed approach can recommend desired services with high precision,
high recall, and low response delay

2.2. Existing Approach


Internet users post a large number of video clips on Video sharing websites and social
network applications every day. The video content may be duplicate, similar, related, or
quite different. Facing billions of multimedia Webpages, online users are usually having a
hard time finding their favorites. Some video-sharing websites recommend video lists for
end users according to video classification, video description tags, or watching history.

Howe ver, these recommendations are not accurate and are always not consistent with
the end users’ interests. To improve this, some websites also provide users with search
engine to search their desired videos quickly. However, searching is based on the
keywords. Online Trading is being hosted on Stand Alone Server.

2.2.1 Disadvantages of existing approach


 Difficult to reuse video-tag module.
 Payment for combination of Physical Hosting and Hardware is demanded by the
Web Hosting.
 Lack of scalability in Dedicated Servers.
 Difficult to identify the Spammers in online.
 Noise and inconsistencies inherent to the data, and illustrates the difficulty of the
task.
2
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

2.3. Proposed Approach:

Cloud-based mobile multimedia recommendation system which can reduce network


overhead and speed up the recommendation process The users are classified into several
groups according to their context types and values. With the accurate classification rules,
the context details are not necessary to compute, and the huge network overhead is
reduced. Moreover, user contexts, user relationships, and user profiles are collected from
video-sharing websites to generate multimedia recommendation.

That the proposed approach can recommend desired services with high precision, high
recall, and low response delay. User clusters are collected instead of detailed user
profiles. To avoid the explosion of network overhead, user-behavior-based clustering is
performed first, and the collectors calculate user clusters according to the clustering rules
and then report the user cluster to the recommender only.

2.3.1 Advantages of proposed approach


 A search system ranked lists of top videos.

 Reusability and extensibility of this framework component.

 Detecting users who disseminate video pollution, instead of classifying the


content itself.

 Machine learning approach that explores the characteristics of pre classified users.

 Transaction-Least-Work-Left (TLWL) routes a new call to the server that has


least work, where work (i.e., load) is based on relative estimates of transaction
costs.

3
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

3. Literature Survey

1) Title: Author topic model-based collaborative filtering for personalized POI


recommendations

Authors: S. Jiang, X. Qian and J. Shen

Abstract

From social media has emerged continuous needs for automatic travel
recommendations. Collaborative filtering (CF) is the most well-known approach.
However, existing approaches generally suffer from various weaknesses. For
example , sparsity can significantly degrade the performance of traditional CF. If a
user only visits very few locations, accurate similar user identification becomes very
challenging due to lack of sufficient information for effective inference. Moreover,
existing recommendation approaches often ignore rich user information like textual
descriptions of photos which can reflect users' travel preferences. The topic model
(TM) method is an effective way to solve the “sparsity problem,” but is still far from
satisfactory. In this paper, an author topic model-based collaborative filtering
(ATCF) method is proposed to facilitate comprehensive points of interest (POIs)
recommendations for social users. In our approach, user preference topics, such as
cultural, cityscape, or landmark, are extracted from the geo-tag constrained textual
description of photos via the author topic model instead of only from the geo-tags
(GPS locations). Advantages and superior performance of our approach are
demonstrated by extensive experiments on a large collection of data.

2) Title: Affective labelling in a content-based recommender system for images

Authors: M. Tkalcic, A. Odic and A. Kosir

Abstract:

Affective labelling of multimedia content has proved to be useful in recommender


systems. In this paper we present a methodology for the implicit acquisition of
affective labels for images. It is based on an emotion detection technique that takes
as input the video sequences of the users' facial expressions. It extracts Gabor low
level features from the video frames and employs a k nearest neighbour’s machine

4
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

learning technique to generate affective labels in the valence-arousal-dominance


space. We performed a comparative study of the performance of a content-based
recommender (CBR) system for images that uses three types of metadata to model
the users and the items: (i) generic metadata, (ii) explicitly acquired affective labels
and (iii) implicitly acquired affective labels with the proposed methodology. The
results show that the CBR performs best when explicit labels are used. However,
implicitly acquired labels yield a significantly better performance of the CBR than
generic metadata while being an unobtrusive feedback tool.

3) Title: Beyond personalization and anonymity: Towards a group-based


recommender system

Author: S. Shang, Y. Hui and P. Hui

Abstract

Recommender systems have received considerable attention in recent years. Yet with
the development of information technology and social media, the risk in revealing
private data to service providers has been a growing concern to more and more users.
Trade-offs between quality and privacy in recommender systems naturally arise. In
this paper, we present a privacy preserving recommendation framework based on
groups. The main idea is to use groups as a natural middleware to preserve users’
privacy. A distributed preference exchange algorithm is proposed to ensure the
anonymity of data, wherein the effective size of the anonymity set asymptotically
approaches the group size with time. We construct a hybrid collaborative filtering
model based on Markov random walks to provide recommendations and predictions
to group members. Experimental results on the Movie Lens dataset show that our
proposed methods outperform the baseline methods, L+ and Item Rank, two state-of-
the-art personalized recommendation algorithms, for both recommendation precision
and hit rate despite the absence of personal preference information.

4) Title: Differentially private recommender systems- building privacy into the net

Author: F. McSherry and I. Mironov.

Abstract
5
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

We consider the problem of producing recommendations from collective user behaviour


while simultaneously providing guarantees of privacy for these users. Specifically, we
consider the Netflix Prize data set, and its leading algorithms, adapted to the framework
of differential privacy.
Unlike prior privacy work concerned with cryptographically securing the computation of
recommendations, differential privacy constrains a computation in a way that precludes
any inference about the underlying records from its output. Such algorithms necessarily
introduce uncertainty—i.e., noise—to computations, trading accuracy for privacy.
We find that several of the leading approaches in the Netflix Prize competition can be
adapted to provide differential privacy, without significantly degrading their accuracy. To
adapt these algorithms, we explicitly factor them into two parts, an aggregation/learning
phase that can be performed with differential privacy guarantees, and an individual
recommendation phase that uses the learned correlations and an individual’s data to
provide personalized recommendations.
The adaptations are non-trivial, and involve both careful analysis of the per-record
sensitivity of the algorithms to calibrate noise, as well as new post-processing steps to
mitigate the impact of this noise.
We measure the empirical trade-off between accuracy and privacy in these adaptations,
and find that we can provide non-trivial formal privacy guarantees while still
outperforming the Cinematic baseline Netflix provides.

5) Title: Personalized social recommendations accurate or Private

Authors: A. Machanavajjhala, A. Korolova and A. D. Sarma,


Abstract
With the recent surge of social networks such as Facebook, new forms of
recommendations have become possible – recommendations that rely on one’s social
connections in order to make personalized recommendations of ads, content, products,
and people. Since recommendations may use sensitive information, it is speculated that

these recommendations are associated with privacy risks. The main contribution of this

6
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

work is in formalizing trade-offs between accuracy and privacy of personalized social


recommendations. We study whether “social recommendations”, or recommendations
that are solely based on a user’s social network, can be made without disclosing sensitve

links in the social graph. More precisely, we quantify the loss in utility when existing

recommendation algorithms are modified to satisfy a strong notion of privacy, called

differential privacy.

7
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

4. ARCHITECTURE AND DESIGN

4.1 OVERALL DESCRIPTION

Based on the MapReduce platform, we have analyzed three kinds


of user behaviors, including user contexts, interest groups, and
user profiles.Along with different characteristics of the three kinds
of information, we adopt SCA, graph partition, and k-means
separately. Distinguishing with other recommender systems, we
have stored recommendation rules instead of recommending lists.
Additionally, a graph based rule reordering method is used in real-
time recommending. Evaluation shows that the proposed system
provides higher quality of recommendation with lower training
latency and recommending latency.

8
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

System Architecture:

4.2 Specific Requirements

4.2.1. Software Requirements

 Operating System : Win 2000/XP


 Technologies used : Java (Jdk 1.6), JSP, Servlet.
 JDK : Version 1.4
 Database used : MySQL 5.0

4.2.2. Hardware Requirements


 Processor : 733
 Keyboard : 104 Keys
 Floppy Drive : 1.44 MB MHz Pentium III
 RAM : 128 MB

9
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

 Hard Disk : 10GB


 Monitor : 14” VGA COLOR
 Mouse : Logitech Serial Mouse
 Disk Space : 1 GB

4.3 System Design

4.3.1 Logical Design

Design for WebApps encompasses technical and non-technical activities. The


look and feel of content is developed as part of graphic design; the aesthetic layout
of the user interface is created as part of interface design; and the technical
structure of the WebApp is modeled as part of architectural and navigational
design.This argues that a Web engineer must design an interface so that it answers
three primary questions for the end-user:

1. Where am I? – The interface should

(1) provide an indication of the WebApp has been accessed

(2) inform the user of her location in the content.

2. What can I do now? – The interface should always help the user understand hiscurrent
options- what functions are available, what links are live, what content is relevant.

3. Where have I been; where am I going? – The interface must facilitate navigation.Hence
it must provide a “map” of where the user has been and what paths may be taken to move
elsewhere in the WebApp.

4.3.2 Design goals – the following are the design goals that are applicable to virtually
every WebApp regardless of application domain, size, or complexity.

1. Simplicity

2. Consistency

3. Identity

10
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Introduction to system analysis


A system is an orderly group of interdependent components linked together according to
a plan to achieve a specific objective. Its main characteristics are organization,
interaction, interdependence, integration and a central objective.

4.3.3 System Analysis

System analysis and design are the application of the system approach to problem solving
generally using computers. To reconstruct a system the analyst must consider its elements
output and inputs, processors, controls feedback and environment.

Analysis is a detailed study of the various operations performed by a system and


their relationships within and outside of the system. One aspect of analysis is defining the
boundaries of the system and determining whether or not a candidate system should
consider other related systems. During analysis data are collected on the available files
decision points and transactions handled by the present system. This involves gathering
information and using structured tools for analysis.

4.4 Feasibility study

Feasibility is the determination of whether or not a project is worth doing. The process
followed in making this determination is called feasibility Study. In the conduct of the
feasibility study, the analyst will usually consider seven distinct, but inter-related types of
feasibility.

4.4.1 Technical Feasibility

This is considered with specifying equipment and software that will successful satisfy the
user requirement the technical needs of the system may vary considerably but might
include

i. The facility to produce outputs in a given time.

ii. Response time under certain conditions.

iii. Ability to process a certain column of transaction at a particular


speed.

11
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

4.4.2 Economic Feasibility

Economic analysis is the most frequently used technique for evaluating the effectiveness
of a proposed system. More commonly known as cost / benefit analysis. The procedure is
to determine the benefits and savings are expected form a proposed system and a compare
them with costs. It benefits outweigh costs; a decision is taken to design and implement
the system will have to be made if it is to have a chance of being approved. There is an
ongoing effort that improves in accuracy at each phase of the system life cycle.

4.4.3 Operational Feasibility

It is mainly related to human organization and political aspects. These points are
considered are

i. What changes will be brought with the system?

ii. What organizational structures are distributed?

iii. What new skills will be required?

iv. Do the existing system staff members have these skills?

v. If not, can they be trained in the course of time?

4.5. Functional Requirements

 This application as to be developed in java technology


 This system must have two types of factories.
1. Admin.
2. Support User

4.6. Non Functional Requirements


12
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Non-functional requirements a description and, where possible, target values of


associated non-functional requirements. Non-functional requirements detail constraints,
targets or control mechanisms for the new system. They describe how, how well or to
what standard a function should be provided. For example, levels of required service such
as response times, security and access requirements, technical constraints, required
interfacing with users' and other systems, and project constraints such as implementation
on the organization’s hardware/software platform. Service level requirements are
measures of the quality of service required, and is crucial to capacity planning and
physical design.

Identify realistic, measurable target values for each service level. These include
service hours, service availability, responsiveness, throughput and reliability. Security
includes defining priority and frequency of backup of data, recovery, fall back and
contingency planning and access restrictions. Access restrictions should deal with what
data needs protected; what data should be restricted to a particular user role; and level of
restriction required, e.g. physical, password, view only. Non-functional requirements may
cover the system as a whole or relate to specific functional requirements.

Accessibility: The accessibility factor to the system depends on the availability of a


broad band connection. The access to our system is possible in places where the internet
is available. Since usually the login and password hacking happens in most of the
domains which are implemented on a global server. For our Opass system to be
accessible anywhere and anytime we have deployed our system on a global server space
and this global server has to always be up and running. The global server is provided with
anti-virus, fire wall security and safe internet usage mode in order to avoid the server
being hacked or intruded.

Availability : The system has to be available anywhere and anytime whenever the user
requires the use of the system. Here we consider the issue of the service level agreement
with various domains in order to embed our system with theirs. So as for as now we have
created our own domain called as Exclusivebuy.com where we demonstrate our Opass
password authentication attack prevention mechanism.

13
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Deployment: The deployment is carried out in various stages such as Android


deployment, Database deployment, and deployment of the source code.

Documentation: the documentation is carried out for every stage in order to summarize
and record the result of every stage since the time the system development was started.

Efficiency: The efficiency of the system is now related in terms of the number of users
able to login. We have not provided the factor of simultaneous login because our system
is built under the cost constraint and this can be further extended and developed.

Failure management: At times of system failure the users may be puzzled about what is
the problem that is taking place in the system. So we have created various exceptions in
order to provide notifications to the users to help them assist and guide them in rectifying
the errors.

Security: We are developing our system with the view of making the password
authentication in various websites and domain. So sufficient security is provided to our
system in order to make it safe for the users Usability by target user community: The
usability factor can be extended to all the domains where the password authentication
phase is used and thus the security of the password and the confidence of the password
being safe from the hackers and phishing software’s is enhanced.

These are constraints on the services or functions offered by the system. They
include timing constraints, constraints on the development process etc. Few of them are:
Communication Interfaces: The application requires an internet connection to perform
browsing and downloading files from the internet.

Safety requirements: Application ensures that it does not download malicious and
infected links from web sites.

Security requirements: Provides automatic file checking capability to ensure the


security of mobile platform and the application.

Software quality attributes: The source code of the application is going to be open as
this is going to be open source software. It will be free for further modifications and
improvements.

14
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

4.7 Data Flow diagrams

A data flow diagram (DFD) is a graphical representation of the “flow” of data through an
information system. A data flow diagram can also be used for the visualization of data
processing (structured design). It is common practice for a designer to draw a context-
level DFD first which shows the interaction between the system and outside entities.
DFD's show the flow of data from external entities into the system, how the data moves
from one process to another, as well as its logical storage.

There are only four symbols


i. Squares representing external entities, which are sources and
destinations of data.
ii. Rounded rectangles representing processes, which take data as
input, do some
Operation and output the data.
iii. Arrows representing the data flows, which can either, be electronic
data or physical Items.
Cylinder represents the database.

15
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

16
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

17
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

18
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

19
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

4.8. Activity Diagram

4.9 State Diagram


20
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

4.10 Use Case Diagram

5. Implementation

5.1 Project Module Description:


21
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Member user is an end user who can register by themselves. Once they are registered
each user will have a user id and password, by which they can enter into their session and
start watching the video.

Whenever the member is watching the video, details will be stored in server DB which
will be used in Recommendation process.

Moreover, to reduce the load on server we will be implementing load balancing technique
using Main cloud and sub cloud concept.

Admin Session

 Login

 Age Group (View, Edit)

 Location (View, Edit)

 Profession (View, Edit)

 Create Cluster

 Change Password

User Session

 User Registration

 Login

 User Profile Management

 Video File Upload

 Play Video File

a. Select the Category

b. Select the Video to play

22
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

c. Server Selection using Load Balance

d. Fetch the video from cloud storage

e. Stream the video to user system thru selected Server

f. Gather Transaction Details

 Video File Recommendation System

a. Context Collector (Location, Age, Profession)

b. Context Clustering

c. Recommendation Rules

d. Filter & Display the Video List

e. Select & Play Video

Change Password

5.2. Modules:

Module 1:

Creating context cluster based on various input parameter

import java.io.IOException;

import java.io.PrintWriter;

import java.sql.Connection;

import javax.servlet.RequestDispatcher;

import javax.servlet.ServletContext;

import javax.servlet.http.HttpServlet;
23
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

import javax.servlet.http.HttpServletRequest;

import javax.servlet.http.HttpServletResponse;

import com.dao.Admin_DAO;

public class Login extends HttpServlet

{public class ContextCluster {

public static void main(String[] args)

contextClust("navya","30","Bangalore","IT&q
uot;,"test10.flv");

fileRecommend();

public static void contextClust(String uid,String age,String loc,String prof,String fnm)

ArrayList<String> arrayList = Admin_DAO.getContextClu();

System.out.println("Array List :"+arrayList);

24
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

for(int i=0;i<arrayList.size();i++)

int count=1;

String s = arrayList.get(i).toString();

String[] str = s.split("~");

String code = str[0];

String uage = str[1];

String uloc = str[2];

String uprof = str[3];

String[] uag = uage.split("-");

String start = uag[0];

25
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

String end = uag[1];

int st = Integer.parseInt(start);

int ed = Integer.parseInt(end);

while(ed>=st)

int check = Integer.parseInt(age);

st =st+count;

if(st==check && uloc.equals(loc) && uprof.equals(prof) )

Admin_DAO.insertTrans(uid, Integer.parseInt(code), fnm);

System.out.println(" ST "+st+" "+code +" Location


:"+loc+" Profession

26
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

"+prof);

break;

System.out.println("Start Age ;"+start+" End Age :"+end


+"Count :"+count);

public static void fileRecommend()

HashMap<String,ArrayList> mp = Admin_DAO.getRecomm();

ArrayList<Integer> code = mp.get("Code");

27
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

ArrayList<String> fnm = mp.get("FileName");

Map<String, Integer> map = new HashMap<String, Integer>();

for (String temp : fnm)

System.out.println("File Name :"+temp);

Integer count = map.get(temp);

map.put(temp, (count == null) ? 1 : count + 1);

printMap(map);

public static void printMap(Map<String, Integer> map)

28
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

ArrayList arrayList = new ArrayList();

for (Map.Entry<String, Integer> entry : map.entrySet())

int val = Integer.parseInt(entry.getValue().toString());

if(val>=Global.K)

System.out.println("-- -- -- -- -- -- -- -- -- -- -- -- -- -");

int clus_code = Admin_DAO.getCode(entry.getKey());

System.out.println("Key : " + entry.getKey() + " Value : & quot;+


entry.getValue()+" Cluster Code :"+clus_code);

arrayList.add(entry.getKey());

29
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

System.out.println("Recommented Files: "+arrayList);

Module 2:

Recommending the videos based on Cluster id

if(videoType.equals("Recommended"))

String c_code="";

String dateTime = Utility.getDateTime();

String[] st = dateTime.split(" ");

String[] date = st[0].split("-");

int d = Integer.parseInt(date[1])-1;

String from = date[0]+"-"+d+"- "+date[2];

30
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

System.out.println("From Date :"+from+" To Date :"+st[0]);

String sqlfrt="SELECT t2.c_code,t1.id FROM m_user t1 LEFT JOIN

m_context_cluster t2 ON t1.age = t2.age and t1.city = t2.location and t1.professtion =


t2.profession

WHERE t1.uid ='"+username+"'";

System.out.println("*********** Getting The Videos By Vedio Type

***********");

System.out.println(sqlfrt);

resultSet = statement.executeQuery(sqlfrt);

while(resultSet.next())

c_code=resultSet.getString(1);

31
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

System.out.println("===user cluster code matched :====="+c_code);

sql = "select file_name from m_trans where date between

'"+from+"' and '"+st[0]+"' and


u_cluster_code='"+c_code+"'";

System.out.println("*********** Getting The Videos By Vedio Type

***********");

System.out.println(sql);

resultSet = statement.executeQuery(sql);

while(resultSet.next())

files.add(resultSet.getString(1));

32
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Map<String, Integer> map = new HashMap<String, Integer>();

for (String temp : files)

System.out.println("File Name :"+temp);

Integer count = map.get(temp);

map.put(temp, (count == null) ? 1 : count + 1);

files.clear();

for (Map.Entry<String, Integer> entry : map.entrySet())

33
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

int val = Integer.parseInt(entry.getValue().toString());

if(val>=Global.K)

System.out.println("-- -- -- -- -- -- -- -- -- -- -- -- -- -");

int clus_code =

Admin_DAO.getCode(entry.getKey());

System.out.println("Key : " + entry.getKey()

34
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Module 3.

Load balancing of Server

//Server Load Balancing Process[STARTS]

System.out.println("Processing Server : " +

processingServerId);

//Checking The Video In LocalVB

flag =User_DAO.checkVideoInLocalVB(con,processingServerId,fileName);

processingServerIP=User_DAO.getProcessServerIPaddress(con,processingServ
erId);

processingServerPort = User_DAO.getProcessServerPort(con,

processingServerId);

processingServerName = User_DAO.getProcessServerName(con,

35
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

processingServerId);

//processingServerUrl="http://192.168.1.16:8080/AMES_LocalVB1/video
.jsp?file="+fileame;processingServerUrl="http://"+process
ingServerIP+":"+processingServerPort+"/"+processingS
erverNam

e+"/video.jsp?file="+fileName;

System.out.println("Processing Server URL

:\n"+processingServerUrl);

if(flag)//1. Video Is Available in Local VB : Yes

boolean b = UserDAO.inserTrans(uid, ""+cluster_code,

fileName, st[0], st[1]);

System.out.println("Video Is Available in Local

VB[Server Id : "+processingServerId+"].");

response.sendRedirect(processingServerUrl);

else//1. Video Is Available in Local VB : No

System.out.println("Opps,The Video Is Not Available

in Local VB[Server Id : "+processingServerId+"].!!!!!");

System.out.println("Checking For Video In Sub

VB[SubVB Id : "+subVbId+"].");

flag = User_DAO.checkVideoInSubVB(con,subVbId,

fileName);

//flag = true;

if(flag)//2. Video Is Available in Sub VB : Yes

36
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

boolean b = UserDAO.inserTrans(uid,

""+cluster_code, fileName, st[0], st[1]);

System.out.println("Video Is Available in Sub

VB[SubVbId : "+subVbId+"].");

//Moving File From Sub VB To Local VB(STARTS)

if( session.getAttribute( "waitPage" ) == null)

PrintWriter out = response.getWriter();

session.setAttribute( "waitPage", Boolean.TRUE );

out.println( "<html><head>" );

out.println("<br><title>Please
Wait...</title>");

out.println( "<meta http-equiv=\"Refresh\"

content=\"0\">" );

out.println( "</head><body bgcolor=''>" );

out.println("<center>");

out.println("<font color='white'
size='5'>");

out.println( "Wait,Please.....<br>" );

out.println( "Moving File From Sub VB To Local

VB....." );

out.println( "<br><br>" );

out.print( "<img

src='Res/Images/loading.gif'></img><br><br>
");

out.println("<font color='red'
size='5'>");

out.println( "Please Do not press Back or Refresh

37
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

button.......<br> " );

out.println("</font>");

out.println("<fontcolor='white'
size='5'>");

out.println( "Video is Buffering..... " );

out.println("</font>");

out.println( "<br>");

out.println("</center>");

out.println("<div class='button'>");

out.close();

Execution steps

 Copy web application directory and paste it to C:\ProgramFiles\Apache


Software Foundation\Tomcat 5.0\webapps in your local machine.

 Export the DB_BackUp\dump.sql into my-SQL database.

 Please copy the Supporting_Files from Supporting Files folder and paste it in
(C:\WINDOWS) Directory.

Note:

 Before run this Project, Please copy the Images folder from this project and paste
it in (C :) Directory.

 To start your tomcat server go to startAll ProgramsApache Tomcat


5.0Configure Tomcat, and the click start button in Configure Tomcat window.

 To check whether tomcat in started or not. Just open your browser and type
http://localhost:8080; Tomcat home page will be open.

 For the best view use IE-6.0 browser.

************************************************************************

38
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Login Details

User ID and Password for Admin Login:

User Id :

Password :

User ID and Password for Member Login :

User Id :

Password :
* There is no user id and password for end users. Just type
http://localhost:8085/AdSense/adsense.jsp in your
Browser. Then end user page will open.

39
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

6. TESTING
Testing is a development procedure where programmers create tests as they develop
software. The tests are simple short tests that test functionally of a particular unit or
module of their code, such as a class or function.

Using open source libraries like cunit, oppunit and nun it (for C, C++ and C#) these tests
can be automatically run and any problems found quickly. As the tests are developed in
parallel with the source unit test demonstrates its correctness.

Validation and System Testing

Validation testing is a concern which overlaps with integration testing. Ensuring that the
application fulfils its specification is a major criterion for the construction ofan
integration test. Validation testing also overlaps to a large extent with SystemTesting,
where the application is tested with respect to its typical working environment.
Consequently for many processes no clear division between validation and system testing
can be made. Specific tests which can be performed in either orboth stages include the
following.

 Regression Testing: Where this version of the software is tested with the
automated test harness used with previous versions to ensure that the required
features of the previous version are skill working in the new version.
 Recovery Testing: Where the software is deliberately interrupted in a number of
ways off, to ensure that the appropriate techniques for restoring anylost data will
function.
 Security Testing: Where unauthorized attempts to operate the software, orparts of
it, attempted it might also include attempts to obtain access the data, orharm the
software installation or even the system software. As with all types of security
determined will be able to obtain unauthorized access and the best that can be
achieved is to make this process as difficult as possible.
 Stress Testing: Where abnormal demands are made upon the software by
increasing the rate at which it is asked to accept, or the rate t which it is asked to
produce information. More complex tests may attempt to crate very large data sets
or cause the soft wares to make excessive demands on the operating system.

40
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

 Performance testing: Where the performance requirements, if any, are checked.


These may include the size of the software when installed, type amount of main
memory and/or secondary storage it requires and the demands made of the
operating when running with normal limits or the response time.
 Usability Testing: The process of usability measurement was introduced in the
previous chapter. Even if usability prototypes have been tested whilst the
application was constructed, a validation test of the finished product will always
be required.
 Alpha and beta testing: This is where the software is released to the actual end
users. An initial release, the alpha release, might be made to selected users who be
expected to report bugs and other detailed observations back to the production
team. Once the application changes necessitated by the alpha phasecan be made to
larger more representative set users, before the final release is made to all
users.The final process should be a Software audit where the complete software
project is checked to ensure that it meets production management
requirements.This ensures that all required documentation has been produced, is
in the correct format and is of acceptable quality. The purpose of this review is:
firstly to assure the quality of the production process and by implication
construction phase commences.

6.1 Testing phase

The completion of the system is achieved only after it has been thoroughly tested. Though
this gives a feel that project is completed there cannot be any project without going
through this stage. Hence in this stage it is decided whether this project can undergo real
time environment execution without any breakdowns, therefore the package can be
rejected even at this stage.

A primary purpose of testing is to detect software failures so that defects may be


discovered and corrected. This is a non-trivial pursuit. Testing cannot establish that a
product functions properly under all conditions but can only establish that it does not
function properly under specific conditions. The scope of software testing often includes
examination of code as well as execution of that code in various environments and
conditions as well as examining the aspects of code: does it do what it is supposed to do
and do what it needs to do. In the current culture of software development, a testing

41
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

organization may be separate from the development team. There are various roles for
testing team members. Information derived from software testing may be used to correct
the process by which software is developed.

6.2 System testing

Testing is a set of activities that can be planned in advance and conducted systematically.
The proposed system is tested in parallel with the software that consists of its own phases
of its analysis, implementation, testing and maintenance. Following are the tests
conducted on the system.

System testing of software or hardware is testing conducted on a complete,


integrated system to evaluate the system's compliance with its specified requirements.
System testing falls within the scope of black box testing, and as such, should require no
knowledge of the inner design of the code or logic.

6.3 Unit testing

During this implementation of the system each module of the system was tested
separately to uncover errors within its boundaries. User interface is used as a guide in the
process

In computer programming, unit testing is a method by which individual units of


source code are tested to determine if they are fit for use. A unit is the smallest testable
part of an application. In procedural programming a unit may be an individual function or
procedure. In object-oriented programming a unit is usually a method. Unit tests are
created by programmers or occasionally by white box testers during the development
process.

Ideally, each test case is independent from the others: substitutes like method
stubs, mock objects, fakes and test harnesses can be used to assist testing a module in
isolation. Unit tests are typically written and run by software developers to ensure that
code meets its design and behaves as intended. Its implementation can vary from being
very manual (pencil and paper) to being formalized as part of build automation.

42
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

6.4 Module testing

A module is composed of various programs related to that module. Module testing is


done to check the module functionality and interaction between units within a module. It
checks the functionality of each program with relation to other programs within the same
module. It then tests the overall functionality of each module.

This module introduces the technique of functional (black box) unit testing to
verify the correctness of classes. It shows how to design unit test cases based on a class
specification within a contract programming approach. The laboratory exercises then
guide students through creating and running tester classes in Java from a test case design,
utilizing the Joint unit test framework. It also contains a worked example on how to unit
test GUI and event handling classes.

Testing is an essential part of any software development process, but it is often


poorly understood. In this module, we take a simple approach and look at two key
approaches to testing. Unit testing is done at the class level, and is designed with the aid
of method pre- and post-conditions. System testing is done at the program level, and is
designed based on documented use cases. We look at how your approach to object-
oriented design is influenced by the need to design and execute tests, and close with some
other issues in testing.

6.5 Integration testing

Integration testing is a systematic technique for constructing the program structure


while conducting tests to uncover errors associated with interfacing. The object is to take
unit tester module and build a program structure that has been dictated by the design.

The purpose of integration testing is to verify functional, performance, and


reliability requirements placed on major design items. These "design items", i.e.
assemblages (or groups of units), are exercised through their interfaces using Black box
testing, success and error cases being simulated via appropriate parameter and data inputs.
Simulated usage of shared data areas and inter-process communication is tested and
individual subsystems are exercised through their input interface.

43
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Test cases are constructed to test that all components within assemblages interact
correctly, for example across procedure calls or process activations, and this is done after
testing individual modules, i.e. unit testing. The overall idea is a "building block"
approach, in which verified assemblages are added to a verified base which is then used
to support the integration testing of further assemblages.

6.6 Acceptance testing

This software has been tested with realistic data given by the client and produced results.
Then the client satisfying all the requirements specified by them has also developed the
software within the time limitations specified. A demonstration has been given to the
client and the end user giving all the operational features.

Acceptance testing generally involves running a suite of tests on the completed


system. Each individual test, known as a case, exercises a particular operating condition
of the user's environment or feature of the system, and will result in a pass or fail, or
Boolean, outcome. There is generally no degree of success or failure. The test
environment is usually designed to be identical, or as close as possible, to the anticipated
user's environment, including extremes of such. These test cases must each be
accompanied by test case input data or a formal description of the operational activities
(or both) to be performed—intended to thoroughly exercise the specific case—and a
formal description of the expected results.

6.6.1Test plan

The test plan contains the following:

 Features to be tested.
 Approach to be tested.
 Test deliverables.

6.7 Features to be tested

44
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

All the functional features specified in the required document will be tested. Test
coverage in the test plan states what requirements will be verified during what stages of
the product life. Test Coverage is derived from design specifications and other
requirements, such as safety standards or regulatory codes, where each requirement or
specification of the design ideally will have one or more corresponding means of
verification.

Test coverage for different product life stages may overlap, but will not
necessarily be exactly the same for all stages. For example, some requirements may be
verified during Design Verification test, but not repeated during Acceptance test. Test
coverage also feeds back into the design process, since the product may have to be
designed to allow test access.

Test methods in the test plan state how test coverage will be implemented. Test
methods may be determined by standards, regulatory agencies, or contractual agreement,
or may have to be created new. Test methods also specify test equipment to be used in the
performance of the tests and establish pass/fail criteria. Test methods used to verify
hardware design requirements can range from very simple steps, such as visual
inspection, to elaborate test procedures that are documented separately.

6.8 Approach for testing

For unit testing structured testing based on branch coverage criteria will be used. The goal
is to achieve branch coverage of more than 95% system testing will be functional in
nature. A test plan documents the strategy that will be used to verify and ensure that a
product or system meets its design specifications and other requirements. A test plan is
usually prepared by or with significant input from Test Engineers.

Depending on the product and the responsibility of the organization to which the test
plan applies, a test plan may include one or more of the following:

45
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

i. Design Verification or Compliance test - to be performed during the


development or approval stages of the product, typically on a small sample of
units.
ii. Manufacturing or Production test - to be performed during preparation or
assembly of the product in an ongoing manner for purposes of performance
verification and quality control.
iii. Acceptance or Commissioning test - to be performed at the time of delivery or
installation of the product.
iv. Service and Repair test - to be performed as required over the service life of the
product.
v. Regression test - to be performed on an existing operational product, to verify
that existing functionality didn't get broken when other aspects of the environment
are changed (e.g., upgrading the platform on which an existing application runs)
vi. Test deliverables
a. The following documents will be required:
b. Unit tests report for each unit.
c. Test case specification for system testing.
d. Test reports for system testing.

46
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

7. EXPERIMENTS AND RESULTS


In this section, we demonstrate the theoretical regret bound for our algorithms with
empirical results based on very large real-world datasets, which includes massive
multimedia data and social media users-generated big data. We show that:
1. Regret bounds are sublinear converged over time.
2. Our differentially private methods work well and do not come at the expense of
recommendation accuracy.
3. Geometric differentially private method has a lower regret bound and higher
accuracy. Finally, we use users’ context vectors refined from real datasets to test
the recommendation accuracy of our algorithms.

To evaluate the performance of our recommendation system, training data and test data
about users and videos should be gathered. We collect numerous user context vectors
extracted from our own data sets. This datasets contain user’s social profiles and
multimedia content they shared. We also extract public information from own dataset, a ,
such as video attributes, popular videos. After pre-processing, around 100 video items,
64*64 user context vectors with dimension are stored. Moreover after recommendation
load balancing starts through various cloud storage.

8. CONCLUSION
We have proposed a cloud-assisted recommender system for videos. Based on the
MapReduce platform, we have analyzed three kinds of user behaviors, including user
contexts, interest groups, and user profiles. Along with different characteristics of the
three kinds of information, we adopt SCA, graph partition, and k-means separately.
Distinguishing with other recommender systems, we have stored recommendation rules
instead of recommending lists. Additionally, a graph based rule reordering method is used
in real-time recommending. Evaluation shows that the proposed system provides higher
quality of recommendation with lower training latency and recommending latency.

47
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

9. APPENDIX
9.1 SOURCE CODE
import java.sql.Connection;

import java.sql.ResultSet;

import java.sql.Statement;

import java.util.ArrayList;

import java.util.HashMap;

public class Admin_DAO

private static String sql="";

private static Statement statement;

private static ResultSet resultSet;

private static Admin_DAO adminDAO;

private Admin_DAO(){}

public static Admin_DAO instance()

if(adminDAO==null)

return new Admin_DAO();

else

return adminDAO;

public boolean loginCHK(String name, String pass,Connection con)

boolean flag=false;

48
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

try

statement = con.createStatement();

resultSet = statement.executeQuery("select * from m_admin where


uid='"+name+"' and pass='"+pass+"'");

while(resultSet.next())

flag=true;

System.out.println("Admin Login Status : "+flag);

public static ArrayList getAge()

ArrayList list = new ArrayList();

try

Connection con = DAO.getConnection();

statement = con.createStatement();

resultSet = statement.executeQuery("select * from m_age");

while(resultSet.next())

list.add(resultSet.getString(2));

49
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

public static ArrayList getProfess()

ArrayList list = new ArrayList();

try

Connection con = DAO.getConnection();

statement = con.createStatement();

resultSet = statement.executeQuery("select * from m_profession");

while(resultSet.next())

list.add(resultSet.getString(2));

return list;

public static ArrayList getLoc()

ArrayList list = new ArrayList();

try

{
50
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Connection con = DAO.getConnection();

statement = con.createStatement();

resultSet = statement.executeQuery("select * from m_location");

while(resultSet.next())

list.add(resultSet.getString(2));

public boolean serverIPCHK(String ip,Connection con)

boolean flag=false;

try

statement = con.createStatement();

resultSet = statement.executeQuery("select * from m_server where


m_ip='"+ip+"'");

while(resultSet.next())

flag=true;

9.2 List of Tables


51
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

m_user

Fields

Field Type Collation Null Key Default Extra

Id int(5) (NULL) NO PRI (NULL) auto_increment


Uid varchar(50) latin1_swedish_ci NO PRI
Pass varchar(50) latin1_swedish_ci YES (NULL)
username varchar(20) latin1_swedish_ci YES (NULL)
Gender varchar(50) latin1_swedish_ci YES (NULL)
profession varchar(50) latin1_swedish_ci YES (NULL)
City varchar(50) latin1_swedish_ci YES (NULL)
Email varchar(50) latin1_swedish_ci YES (NULL)
Phone varchar(12) latin1_swedish_ci YES (NULL)
Age varchar(30) latin1_swedish_ci YES (NULL)

m_age

Fields

Field Type Collation Null Key Default Extra

age_code int(20) (NULL) NO PRI (NULL) auto_increment


Age varchar(50) latin1_swedish_ci YES (NULL)

m_location

Fields

Field Type Collation Null Key Default Extra

loc_code int(20) (NULL) NO PRI (NULL) auto_increment


Location varchar(50) latin1_swedish_ci YES (NULL)

52
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

m_profession

Fields

Field Type Collation Null Key Default Extra

prof_code int(20) (NULL) NO PRI (NULL) auto_increment


profession varchar(50) latin1_swedish_ci YES (NULL)

m_context_cluster

Fields

Field Type Collation Null Key Default Extra

c_code int(10) (NULL) NO PRI (NULL) auto_increment


Profession varchar(50) latin1_swedish_ci YES (NULL)
Age varchar(50) latin1_swedish_ci YES (NULL)
Location varchar(50) latin1_swedish_ci YES (NULL)
Remarks varchar(50) latin1_swedish_ci YES (NULL)

m_Video(upload)

Fields

Field Type Collation Null Key Default Extra

upload_id int(10) (NULL) NO PRI (NULL) auto_increment


user_id int(10) (NULL) YES 0
upload_title varchar(100) latin1_swedish_ci NO
file_name varchar(100) latin1_swedish_ci NO
date_time varchar(100) latin1_swedish_ci NO
video_share_type varchar(50) latin1_swedish_ci NO Public
rec_user_id int(10) (NULL) NO

53
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

m_videobase

Fields

Field Type Collation Null Key Default Extra

vb_id int(10) (NULL) NO PRI (NULL) auto_increment


host_name varchar(100) latin1_swedish_ci NO
Username varchar(100) latin1_swedish_ci NO
Password varchar(100) latin1_swedish_ci NO
vb_name varchar(150) latin1_swedish_ci NO

m_sub_vb

Fields

Field Type Collation Null Key Default Extra

sv_id int(10) (NULL) NO PRI (NULL) auto_increment


vb_id int(10) (NULL) NO 0
file_name varchar(100) latin1_swedish_ci NO

m_local_vb

Fields

Field Type Collation Null Key Default Extra

54
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

lv_id int(10) (NULL) NO PRI (NULL) auto increment


server_id int(10) (NULL) NO 0
file_name varchar(100) latin1_swedish_ci NO

m_process_server

Fields

Field Type Collation Null Key Default Extra

server_id int(5) (NULL) NO PRI (NULL) auto increment


server name varchar(50) latin1_swedish_ci YES (NULL)
server_ip varchar(50) latin1_swedish_ci YES (NULL)
server port int(10) (NULL) YES (NULL)
no_of_req int(10) (NULL) YES (NULL)

m_Video_trans

Fields

Field Type Collation Null Key Default Extra

t_id int(10) (NULL) NO PRI (NULL) auto increment


Userid varchar(30) latin1_swedish_ci YES (NULL)
u_cluster_code int(10) (NULL) YES (NULL)
file_name varchar(30) latin1_swedish_ci YES (NULL)
Date Date (NULL) YES (NULL)
Time Time (NULL) YES (NULL)

9.3 Screenshots

55
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

User Register

56
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

User Login Form

57
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Create Clustering

58
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Upload video file to cloud.

59
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

View Public video from Cloud.

60
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

61
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

View Recommended Video

62
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

9.3 Java

Initially the language was called as “oak” but it was renamed as “Java” in 1995. The
primary motivation of this language was the need for a platform-independent (i.e.,
architecture neutral) language that could be used to create software to be embedded in
various consumer electronic devices.

 Java is a programmer’s language.


 Java is cohesive and consistent.
 Except for those constraints imposed by the Internet environment, Java gives the
programmer, full control.
 Finally, Java is to Internet programming where C was to system programming.

IMPORTANCE OF JAVA TO THE INTERNET


Java has had a profound effect on the Internet. This is because; Java expands the Universe
of objects that can move about freely in Cyberspace. In a network, two categories of
objects are transmitted between the Server and the Personal computer. They are: Passive
information and Dynamic active programs. The Dynamic, Self-executing programs cause
serious problems in the areas of Security and probability. But, Java addresses those
concerns and by doing so, has opened the door to an exciting new form of program called
the Applet.

JAVA CAN BE USED TO CREATE TWO TYPES OF PROGRAMS


Applications and Applets: An application is a program that runs on our Computer under
the operating system of that computer. It is more or less like one creating using C or C++.
Java’s ability to create Applets makes it important. An Applet is an application designed
to be transmitted over the Internet and executed by a Java –compatible web browser. An
applet is actually a tiny Java program, dynamically downloaded across the network, just
like an image. But the difference is, it is an intelligent program, not just a media file. It
can react to the user input and dynamically change.

9.3 Servlets

63
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Servlets provide a Java(TM)-based solution used to address the problems currently


associated with doing server-side programming, including inextensible scripting
solutions, platform-specific APIs, and incomplete interfaces.

Servlets are objects that conform to a specific interface that can be plugged into a Java-
based server. Servlets are to the server-side what applets are to the client-side -- object
byte codes that can be dynamically loaded off the net. They differ from applets in that
they are faceless objects (without graphics or a GUI component). They serve as platform-
independent, dynamically loadable, plug gable helper byte code objects on the server side
that can be used to dynamically extend server-side functionality.

Servlets are modules that extend request/response-oriented servers, such as Java-enabled


web servers. For example, a servlet might be responsible for taking data in an HTML
order-entry form and applying the business logic used to update a company’s order
database.

9.5 Java Server Pages

Java Server Pages technology lets you put snippets of servlet code directly into a text-
based document. A JSP page is a text-based document that contains two types of text:
static template data, which can be expressed in any text-based format such as HTML,
WML, and XML, and JSP elements, which determine how the page constructs dynamic
content.

Java Server Page™ (JSP): An extensible Web technology that uses template data, custom
elements, scripting languages, and server-side Java objects to return dynamic content to a
client. Typically the template data is HTML or XML elements, and in many cases the
client is a Web browser.

Java Server Pages (JSP) lets you separate the dynamic part of your pages from the static
HTML. You simply write the regular HTML in the normal manner, using whatever Web-
page-building tools you normally use. You then enclose the code for the dynamic parts in
special tags, most of which start with "<%" and end with "%>". For example, here is a
section of a JSP page that results in something like "Thanks for ordering Core Web
Programming.

9.6 Communication Technologies


64
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

Communication technologies provide mechanisms for communication between clients


and servers and between collaborating objects hosted by different servers. The J2EE
specification requires support for the following types of communication technologies:

Internet protocols

o Remote method invocation protocols


o Object Management Group protocols
o Messaging technologies
o Data formats
Internet protocols define the standards by which the different pieces of the J2EE platform
communicate with each other and with remote entities. The J2EE platform supports the
following Internet protocols:

o TCP/IP—Transport Control Protocol over Internet Protocol. These two protocols


provide for the reliable delivery of streams of data from one host to another.
Internet Protocol (IP), the basic protocol of the Internet, enables the unreliable
delivery of individual packets from one host to another. IP makes no guarantees as
to whether the packet will be delivered, how long it will take, or if multiple
packets will arrive in the order they were sent. The Transport Control Protocol
(TCP) adds the notions of connection and reliability.
o HTTP 1.0—Hypertext Transfer Protocol. The Internet protocol used to fetch
hypertext objects from remote hosts. HTTP messages consist of requests from
client to server and responses from server to client.

o SSL 3.0—Secure Socket Layer. A security protocol that provides privacy over the
Internet. The protocol allows client-server applications to communicate in a way
that cannot be eavesdropped or tampered with. Servers are always authenticated
and clients are optionally authenticated.

Remote Method Invocation Protocols

Remote Method Invocation (RMI) is a set of APIs that allow developers to build
distributed applications in the Java programming language. RMI uses Java language
interfaces to define remote objects and a combination of Java serialization technology and
the Java Remote Method Protocol (JRMP) to turn local method invocations into remote
65
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

method invocations. The J2EE platform supports the JRMP protocol, the transport
mechanism for communication between objects in the Java language in different address
spaces.

9.7 MySQL

MySQL is a relational database management system, which organizes data in the form of
tables. MySQL is one of many databases servers based on RDBMS model, which
manages a seer of data that attends three specific things-data structures, data integrity and
data manipulation. With MySQL cooperative server technology we can realize the
benefits of open, relational systems for all the applications. MySQL makes efficient use
of all systems resources, on all hardware architecture; to deliver unmatched performance,
price performance and scalability. Any DBMS to be called as RDBMS has to satisfy
Dr.E.F.Codd’s rules.

Distinct Features of MySQL:

The MySQL RDBMS is available on wide range of platforms ranging from PCs to super
computers and as a multi user loadable module for Novel NetWare, if you develop
application on system you can run the same application on other systems without any
modifications.

 MYSQL IS COMPATIBLE:

MySQL commands can be used for communicating with IBM DB2 mainframe
RDBMS that is different from MySQL , that is MySQL compatible with DB2
.MySQL RDBMS is a high performance fault tolerant DBMS , which is specially
designed for online transaction processing and for handling large database
applications..

 MULTITHREADED SERVER ARCHITECTURE:

MySQL commands can be used for communicating with IBM DB2 mainframe
RDBMS that is different from MySQL , that is MySQL compatible with DB2

66
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

.MySQL RDBMS is a high performance fault tolerant DBMS , which is specially


designed for online transaction processing and for handling large database
applications.

 FEATURES OF MYSQL

Most popular RDBMS in the market because of its ease of use

 Client/server architecture.
 Data independence.

 Ensuring data integrity and data security.

 Managing data concurrency.

 Parallel processing support for speed up data entry and online transaction
processing used for applications.

 DB procedures, functions and packages.

9. REFERENCES
 Z. Wang, W. Zhu and P. Cui, “Social media recommendation,” SocialMedia
Retrieval. Springer London, pp. 23-42, 2013.

 C. Ming, S. James and Z. Jie, “Connection discovery using big data ofuser-shared
images in social media,” Multimedia, IEEE Transactions on.vol. 17, no. 9, pp.
1417-1428, 2015.

 “YouTube wins its first Emmy for video recommendations you can’t resist,” The
Verge. [Online]. Available:http://www.theverge.com/2013/8/1/4578544/youtube-
wins-first-emmy-for-video-recommendations-youcant-resist.

 “Privacy by the Numbers: A New Approach to Safeguarding Data,” Scientific


American. [Online]. Available:http://www.scientificamerican.com/article/privacy-
by-the-numbers-a-new-approach-to-safeguarding-data.

67
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

 A. Jeckmans, M. Beye and Z. Erkin et al, “ Privacy in recommender systems,” in


Social media retrieval, Springer London, pp. 263-281, 2013. [6] M. Cheung and J.
She, “Bag-of-features tagging approach for a better recommendation with social
big data,” in Proceedings of the 4th International Conference on Advances in
Information Mining and Management.

 A. Samuel, M.I. Sarfraz, and H. Haseeb, “A framework for composition


and enforcement of privacy-aware and context-driven authorization mechanism
for multimedia big data,” Multimedia, IEEE Transactions on. vol.
17, no. 9, pp. 1484-1494, 2015.
 A. Machanavajjhala, A. Korolova and A. D. Sarma, “Personalized social
recommendations accurate or Private?,” in Proceedings of the VLDB Endowment,
vol. 4, no. 7, pp. 440-450, 2011.

 M. Tkalcic, A. Odic and A. Kosir, “Affective labeling in a content-based


recommender system for images,” Multimedia, IEEE Transactions on. vol. 15, no.
2, pp. 391-400, 2013.

 S. Jiang, X. Qian and J. Shen, “Author topic model-based collaborative filtering


for personalized POI recommendations,” Multimedia, IEEE Transactions on. vol.
17, no. 6, pp. 907-918, 2015.

 S. Shang, Y. Hui and P. Hui, “Beyond personalization and anonymity: Towards a


group-based recommender system,” in Proceedings of the 29th Annual ACM
Symposium on Applied Computing, pp. 266-273, 2014.

 Cynthia Dwork, Frank McSherry, Kobbi Nissim, and Adam Smith. “Calibrating
noise to sensitivity in private data analysis,” in Theory of Cryptography
Conference, Springer, pp. 265-284, 2006.

 Z. Jorgensen and T. Yu, “A privacy-preserving framework for personalized,


social recommendations,” In EDBT, pp. 571-582, 2014.

 F. McSherry and I. Mironov, “Differentially private recommender systems:


building privacy into the net,” in Proceedings of the 15th ACM SIGKDD
international conference on Knowledge.

68
Dept. of CSE, DSCE, Bangalore – 78
Video Recommendation Based on Cloud 2017

69
Dept. of CSE, DSCE, Bangalore – 78

Vous aimerez peut-être aussi