Reading and Writing Data

video locked
Enroll to watch

15 mins

In this video, we discuss:

  1. Defining a DB connector

  2. Updating the database

  3. Creating a data access object (DAO) to extract common data access patterns

We suggest using Thrift to define a contract of the service and classes that are going to be exposed, and then auto-generating the code, rather than writing it all from scratch.

By creating a DAO, you can separate out common data access patterns and have different controllers access those tables to perform different queries on the same data.