Persistence Logic And Persistence Stores
Every medium,large scale application development is collection of multiple logic's like presentation logic,persistence logic, logic and etc.
Persistence logic
The logic that prepare user interface for end user and also formats the results of the application to display for end user is called as presentation logic.
The logic of the application that generates results by using input values through calculations and analysis is called as business logic.
The logic that interacts with data base s/w and manipulates database data through the insert, update, delete and select operations is called persistence logic eg: JDBC code, Hibernet Code etc.
persistence logic is always helper logic of business logic.
Persistence logic performs the persistence operations on persistence stores like database s/w. These operations can also be called as CRUD operations.
Here
C------------>create (Insert)
R------------>Read (select)
U------------>Update (select)
D------------>Delete (remove).
persistence stores
The place where the data stored and managed permanently is called persistence store files, database s/w. Java application uses I/O stream based persistence logic to perform persistence operations on files.
Files are suitable as persistence store only in small scale applications like mobile application and desktop applications. In medium and large scale applications it is recommended to use database s/w.
Files can't provide the security, query language supports and other facility as persistence stores but they occupy less memory compare to database s/w to store and manage the data.
Limitations of Jdbc persistence logic.
Java application can use Jdbc logic to perform persistence operations on RDMS Database s/w.
1.Jdbc uses sql queries in persistence logic development since these sql queries are database s/w dependent queries so the Jdbc persistence logic acts as database dependent logic.
2.since Jdbc persistence logic is database s/w dependent the change of database s/w in the middle of the project development in the maintenance phase of the project development generates the problem.
3.The Jdbc ResultSet object is not serializable object so we can't send that object directly over the network.
3.The Jdbc Result Set object is not realizable object so we can't send that object directly over the network
can you explain this statement in detail with live example