Skip to content

Latest commit

 

History

History
27 lines (17 loc) · 1.86 KB

VolatileOverview.md

File metadata and controls

27 lines (17 loc) · 1.86 KB

Volatile Implementation Overview

Note: To checkout this version, be sure that you are browsing the code stored in the releases/1.0 branch.

Interfaces are defined in the main package, as classical Java interfaces. Components are implemented in the components sub-package, in classes with Bean postfixed names. When a component refers to another one according to a provides/requires association, the component implementation refers to the associated Interface instead of the concrete implementation to ensure decoupling.

The Cart component is implemented twice, first as a Stateful bean, and then as a Stateless one (in the cart sub-package).

As there is no persistent backend, we mocked the persistence layer using a Singleton bean named Database. It stores all the necessary data in static maps. We'll se in the next section how to remove this mock and use a real persistence layer thanks to EJB Entities.