1. ORM Frameworks

ORM Frameworks

ORM Points

  • While creating real-time projects, implementing data access layer of an enterprise application is a challenging task.
  • Data persistence means storing, retrieving of data and also making modification to the data permanently.
  • In java projects data can be stored in
    1. Variables
    2. File
    3. Database
  • Variables can store the data temporarily.
  • To make the data as persistence, it must be stored in File or database.
  • Data persistence contains 3 components
    1. Data
    2. Medium
    3. Storage
  • When storage is a file(flat file) then we use IO Streams to store and read the raw data from the files and we use serialization and deserialization to store and read objects from file.


  • When storage is a database then, we use JDBC API to store or read the data from database.
  • If data is in a Java object then we can use either Jdbc or ORM tool to store and read the object from database.
  • Using JDBC API in a Java application, to perform CRUD operations on the data of Java Objects has some issues.
    1. JDBC API can only transfer raw data, but not objects. So, the application has to convert the object into RAW data.
    2. If any changes are made to the DB schema then the queries defined at various places of the application are need to be modified and it will take more time.
    3. The exceptions of JDBC API are checked exceptions so, where ever JDBC code is defined in application, we need to keep the code under try & catch block.
  • As a solution, third parties started providing ORM tools or ORM frameworks.
  • ORM tools/frameworks transfers objects between an application and database, by using the low level JDBC API internally</>

No comments:

Post a Comment

Quote of the day

Popular Posts

Featured Post

Collection Framework Overview

Collection:- A collection (sometimes called a container) is simply an object that groups multiple elements into single unit. Collect...

Youtube Page

Facebook Page

Recent Posts

About

I am Shivaji Chandra and I'm a Computer Science Engineer. I love to write poems, jokes and quotes. click here →