ATG Repository Basic Description

Repositories (a.k.a. Data Anywhere Architecture) is the mechanism that ATG uses to access data primarily stored in relational databases, but also LDAP or other backend systems. ATG applications are required to be very high performance, and data access is critical in that if not handled properly, it could create a bottleneck. ATG's repository functionality has been around for a long time - it's proven to be extremely scalable. Developers new to ATG need to understand how repositories work as this is a critical aspect of the ATG architecture.

Repositories essentially map relational tables to objects in ATG, as well as handle caching. ATG defines many repositories out of the box (i.e. user profile, catalog, orders, etc), and this is comprised of both the underlying database schema along with the associated repository definition files (XML). It is fully expected that implementations will extend / change the out of the box repository definitions, so there is a prescribed approach to doing this. The first thing to be sure of is to encapsulate your repository definition additions / changes within your own module (as described above). 
The other important best practice is to never modify the out of the box schema - in other words, don't add columns to existing ATG tables, just create your own new tables. These will help ensure you can easily upgrade your application at a later date.

Type of Repository:

1. SQL Repositories: GAS (GAS Stands for “Generic SQL Adapter”) repository connected to SQLdatabase and access contains, user profile, application security information.

2. SQL Profile Repository: include the ATG personalization module.
3. LDAP Repository: Uses the dynamo LDAP connector to access user data in an LDAP directory.

4. Composite Repository: provides a means for using more than one data store as source for single repository.

5. Versioned Repositories: it is extension of SQL repository used in ATG publishing. It has versions for every data.(new entry will be made with a new version number instead of editing)