Back to Sports Hub portal product map
- 1 Introduction
- 2 Database Design and Data Modeling
- 3 Database Implementation
- 4 Data Integration
- 5 Datawarehouse
The purpose of this document is to define the requirements for the database, which will underpin a sports web portal, alongside enumerating the technical tasks.
The database will be responsible for storing and managing data related to sports, including articles, videos, surveys, advertisements, etc.
Follow this link to review requirements for this section.
In scope of those requirements, implement the next tasks:
1. Environment setup and configuration:
- Install and configure RDBMS.
- Install and configure DB management tool.
- Install and configure data integration tool.
- Git configuration.
2. Create an Entity-Relationship Diagram (ERD) for operational DB based on the identified entities and relationships:
- Identify the entities that need to be represented in the database.
- Analyze the relationships between the entities.
- Identify the attributes associated with each entity.
- Choose data types for entities.
- Determine primary key for each entity.
- Normalize the data model to minimize redundancy and improve efficiency.
3. Create an Entity-Relationship Diagram (ERD) for raw data DB based on the identified entities and relationships:
- Identify the entities that need to be represented in the database.
- Analyze the relationships between the entities.
- Identify the attributes associated with each entity.
- Choose data types for entities.
- Determine primary key for each entity.
- Normalize the data model to minimize redundancy and improve efficiency.
4. Create data dictionary for operational DB according to ERD:
- Describe entities related to articles.
- Describe entities related to videos.
- Describe entities related to comments.
- Describe entities related to publication categories.
- Describe entities related to users’ data.
- Describe entities related to authors of publications.
- Describe entities related to publication partners.
- Describe entities related to surveys.
- Describe entities related to social network data.
- Describe entities related to banners.
- Describe entities related to advertisement.
- Describe entities related to users’ subscription.
- Describe entities related to additional entities that were identified during DB modeling.
5. Create data dictionary for raw data DB according to ERD:
- Describe entities related to articles.
- Describe entities related to article categories.
- Describe entities related to users’ data.
- Describe entities related to partners.
- Describe entities related to additional entities that were identified during DB modeling.
6. Create operational DB according to ERD and data dictionary:
- Create Operational DB.
- Create entities related to articles.
- Create entities related to videos.
- Create entities related to comments.
- Create entities related to publication categories.
- Create entities related to users’ data.
- Create entities related to authors of publications.
- Create entities related to publication partners.
- Create entities related to surveys.
- Create entities related to social network data.
- Create entities related to banners.
- Create entities related to advertisement.
- Create entities related to users’ subscription.
- Create entities related to additional entities that were identified during DB modeling.
7. Create raw data DB according to ERD and data dictionary:
- Create Raw DB.
- Create entities related to articles.
- Create entities related to article categories.
- Create entities related to users’ data.
- Create entities related to partners.
- Create entities related to additional entities that were identified during DB modeling.
Follow this link to review requirements for this section.
In scope of those requirements, implement the next tasks:
1. Generate test data set for operational DB:
- Generate data related to articles.
- Generate data related to videos.
- Generate data related to comments.
- Generate data related to publication categories.
- Generate data related to users.
- Generate data related to authors of publications.
- Generate data related to publication partners.
- Generate data related to surveys.
- Generate data related to social networks.
- Generate data related to banners.
- Generate data related to advertisement.
- Generate data related to users’ subscription.
- Generate data related to additional entities that were identified during DB modeling.
2. Implement functional requirements for manipulating and managing data in operational DB:
- Implement functionality to log any data changes into a specific DB table.
- Implement functionality to log any errors and failures into a specific DB table.
- Implement functionality to add/edit/delete data related to articles.
- Implement functionality to enable/disable ability to comment on an article.
- Implement functionality to add/edit/delete data related to videos.
- Implement functionality to enable/disable ability to comment on a video.
- Implement functionality to enable/disable ability to share a video.
- Implement functionality to add/edit/delete data related to publication categories (sports, leagues, teams).
- Implement functionality to add/edit/delete data related to users.
- Implement functionality to store users’ activity.
- Implement functionality to notify administrators of any suspicious or unusual user activity.
- Implement functionality to export users’ activity data for requested period in CSV or Excel file.
- Implement functionality to allow users viewing their own activity history, including past logins, content creation and modification.
- Implement functionality to purge users’ activity data once in 90 days.
- Implement functionality to add/edit/delete data related to authors.
- Implement functionality to add/edit/delete data related to surveys.
- Implement functionality to store surveys answers in the appropriate DB tables.
- Implement functionality to store social networks tokens.
- Implement functionality to purge social network activity history once in 90 days.
- Implement functionality to add/edit/delete data related to banners.
- Implement functionality to add/edit/delete data related to advertisement.
- Implement functionality to store data about users’ views of advertisements.
- Implement functionality to purge history of advertisement views once in 90 days.
- Implement functionality to add/edit/delete data related to comments.
- Implement functionality to add/edit/delete data related to reactions.
- Implement functionality to add/edit/delete data related to subscriptions.
- Implement functionality to add/edit/delete data related to partners.
3. Prepare usage metrics for web-portal analytics using operational DB:
- Retrieve the number of views of each article and video per day/week/month.
- Retrieve the number of comments for each article and video.
- Retrieve the number of shares for each article and video on social networks.
- Retrieve the ratio of positive to negative comments for each article.
- Retrieve the articles that have been published in the last 24 hours.
- Retrieve number of views of articles and videos per categories.
- Retrieve the number of replies for each comment of each article and video.
- Retrieve the percentage of users who shared publications on social media.
- Retrieve the percentage of users who have created an account but have never logged in.
- Retrieve information about how many new users sign up on website each week.
- Retrieve the number of comments left by each user.
- Retrieve duration of each session of each user on the website.
- Retrieve information about users who have logged in for more than 1 hour.
- Retrieve information about users’ preferable languages.
- Retrieve users who have not logged in to website in the last 30 days.
- Retrieve number of publications shared on social networks by each user.
- Retrieve total number of each publication shared on social networks.
- Retrieve number of articles and videos shares per each social network.
- Retrieve number of responses per survey.
- Retrieve number of surveys completed by each user.
- Retrieve number of advertisements’ views per day/week/month.
4. Implement non-functional requirements for operational DB:
- Analyze query execution plans and optimize queries for better response time.
- Implement indexing strategies to enhance query performance.
- Fine-tune database configuration settings for optimal performance.
- Implement data archiving or purging mechanisms to manage data growth and optimize performance.
- Set up comprehensive monitoring for the database, including deadlocks, performance metrics, resource utilization, and workload patterns.
- Implement backup strategy.
- Implement role-based access control and user management.
- Identify sensitive data.
- Protect sensitive data with encryption a row-level security.
Follow this link to review requirements for this section.
In scope of those requirements, implement the next tasks:
1. Implement processing of partner’s data:
- Create ETL workflow to process data from partner’s source.
- Create ETL workflow to migrate data from Raw DB to the Operational DB.
- Create error handling and alerting strategy for ETL solutions.
- Implement data quality checks and validation processes.
- Set up automatic execution of ETL processes according to schedules.
Follow this link to review requirements for this section.
In scope of those requirements, implement the next tasks:
1. Implement data warehouse solution:
- Determine the appropriate architecture for the data warehouse, such as a star schema, snowflake schema, or hybrid approach.
- Define the dimensions, facts, and hierarchies that will structure the data warehouse.
- Create ERD for DWH according to the chosen architecture.
- Create DWH objects according to ERD.
- Design Slowly Changing Dimension (SCD) strategies.
- Design and implement the incremental load process to load only the changes since the last update.
- Develop the full load process to load the entire dataset from the source systems into the data warehouse when needed.
- Design and develop the ETL processes to extract data from source systems.
- Implement indexes strategy.
- Implement partitioning strategy.