Skip to content

This project is a mobile device reparation program that inqludes sql querys and function in aws as rds/ aws s3

Notifications You must be signed in to change notification settings

AdamRuth01/assignmentMobileRepair

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Table Of Contents



Development process

  • The development process:

  • Architecture:

    • The development architecture have I been using ER-Diagram for create the tables and work out the (PK) and (FK), and for my own knowledge future on the road, keep things simple and don't do it complex.
  • My SQL Workbench:

    • I have been using (My-SQL-Workbench) in order to create the connection to the database in (DB-gate) and implement the table and query for each table. The configuration and setup have been worked out through the (My-SQL-Workbench) eviorment to make sure the (CRUD) query's is working for each table.
  • Dependency injection:

    • Dependecy injection for (JDBC = mysql-connector), (junit = junit-jupiter-api) , (mockito = mockito-core).
  • JDBC:

    • My next step was to set up the java program and implement the tables from the (ER-diagrams) and (My-SQL-Workbench) environment. To create the right classes and make sure the (CRUD) queries where working through java with the database.
  • Test JUNIT/MOCKING:

    • I did implement tests for (CustomerMGR and MobileDevices) for every (CRUD) methode.
  • Creation of the (AWS DB)

    • The creation of the AWS DB in AWS cloud
  • Implemented AWS DataBase/Connection with JDBC

    • The implementation through (JDBC) simple, the change was to implement a duplication of the (URL,USERNAME,PASS) but with different input gained access to the AWS database, crud was completed with My SQL Workbench to make sure the connection was completed.

Database structure

assignment_mobile_reparation consists of three tables: customers, mobile_devices, and reparations. Here’s a brief description of each:

customers: This table stores information about customers. It has the following fields:

  • customer_id: A unique identifier for each customer. It’s the primary key.
  • customer_name: The name of the customer. This field is required.
  • customer_phone_number: The phone number of the customer.
  • customer_address: The address of the customer.

mobile_devices: This table stores information about mobile devices. It has the following fields:

  • mobile_device_id: A unique identifier for each mobile device. It’s the primary key.
  • imei_number: The International Mobile Equipment Identity (IMEI) number of the device. This field is required.
  • phone_brand: The brand of the mobile device. This field is required.
  • model_number: The model number of the mobile device. This field is required.

reparations: This table stores information about reparations. It has the following fields:

  • reparation_id: A unique identifier for each reparation. It’s the primary key.
  • customer_id: The ID of the customer who requested the reparation. This field is required and references the customer_id in the customers table.
  • mobile_device_id: The ID of the mobile device to be repaired. This field is required and references the mobile_device_id in the mobile_devices table.
  • employee_first_name, employee_last_name, employee_number: Information about the employee who is handling the reparation. These fields are required.
  • reparation_start_date, reparation_end_date: The start and end dates of the reparation. These fields are required.
  • reparation_status: The status of the reparation. This field is required.
  • reparation_description: A description of the reparation. This field is required.
  • images: Images related to the reparation.

The reparations table has two foreign keys, customer_id and mobile_device_id, which create relationships with the customers and mobile_devices tables, respectively. This means that each reparation is linked to a specific customer and a specific mobile device.


Functions

  • Code Functions:
    • The function in the code:
  1. JDBC connection
  2. CRUD for each methode
  3. Test environment implemented
  4. Possibility for AWS RDS Connection
    • Main description: The program is a Fictitious definition of a mobile reparation company with customers, mobile devices and reparation entity's that define each class and makes it possible to crud each table/class.

Code structure

  • Code structure:
    • The code structure is implemented after My-SQL-Workbench structure. The code has been implemented and configured afterwards depending on the change in the test environment, just fine adjustment for make (Mock) easier.

img.png


About

This project is a mobile device reparation program that inqludes sql querys and function in aws as rds/ aws s3

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages