[SOLVED] Big Data Homework 4

30.00 $

Programming resource
Digital learning resource
Category:
✓ Practical programming resource
✓ Suitable for guided study and reference
✓ Tutor guidance available when needed

Description

Rate this product

 

Load in an appropriate hbase model the following attributes of each email: name of the employee

(obtained from the name of the folder), email address of the sender, date of the email, send to as string,

and email body as string.

Recently I read in the newspaper FakeInnovations that entrepreneur Bogus John Enron wants to fund a

company with the same employees (those jailed will work from the jail). Bogus John needs an hbase

database that will track all the emails. The management of the company wants to be able to quickly

query emails for a user, all emails during a time period, and all emails for a given user during a period of

time.

You have to perform the following tasks:

  1. Create an hbase database model.
  2. Import all emails in hbase.
  3. Return the bodies of all emails for a user of your choice (as a single text file).
  4. Return the bodies of all emails written during a particular month of your choice (as a single text

file).

  1. Return the bodies of all emails of a given user during a particular month both of your choice (as

a single text file).

Here are 2 options that you can choose from.

  1. Write an hbase script for all of the tasks. This is the route of least effort but also least rewarding.
  2. The hbase on wolf offers restful access. You can either use python or java to perform the task.

Python: use module starbase: https://github.com/barseghyanartur/starbase or HappyBase

https://happybase.readthedocs.io/en/latest/

The restful interface on wolf for hbase runs on port 20550 and thus you have to initialize the

connection as c = Connection(port=20550)

To fetch a single record, use ‘get’ but to fetch a range of records, use ‘scan.’

Resource details

Understand the Task Before You Use the Resource

Review the requirements, identify the programming concepts involved, study the implementation and test your understanding with your own examples and modifications.