0 votes
in Technology by (326k points)

What are the key components of persistence API in EJB?

1 Answer

0 votes
by (326k points)

Following are the key components of persistence API in EJB:

  • Entity - A persistent object representing the data-store record. It is good to be serializable.

  • EntityManager - Persistence interface to do data operations like add/delete/update/find on persistent object(entity). It also helps to execute queries using Query interface.

  • Persistence unit (persistence.xml) - Persistence unit describes the properties of persistence mechanism.

  • Data Source (*ds.xml) - Data Source describes the data-store related properties like connection url. user-name,password etc.

Related questions

0 votes
1 answer
asked Nov 7, 2020 in Technology by JackTerrance (326k points)
0 votes
1 answer
0 votes
1 answer
asked Nov 7, 2020 in Technology by JackTerrance (326k points)
0 votes
1 answer
0 votes
1 answer
...