ATG

From ControlTier

Jump to: navigation, search

Also see the ATG Demo (based on the Pioneer Cycling sample application)

Contents

Introduction

If you are interested in deploying and managing ATG applications, the ControlTier project includes the ATG automation library. The library includes a pre-built set of automation modules and best practices that provide you with automated management of ATG application build and deployment processes, ATG platforms, and their related technologies. Like any ControlTier software, the ATG Solution is completely free open source software under the apache license.

The ATG Solution provides a layer of coordination across any or all of the application build and deployment processes described below. Each of these processes, as well as their individual step-by-step actions, can be utilized individually or combined into more complex command work flows.

File:Atg librarystack.png

Status

The ATG library is actively maintained by the IT operations consultants at DTO Solutions. It is in production use within a number of ATG-based e-commerce environments. All of the code is part of the regular ControlTier distribution, but the documentation is still a bit sparse. If you have any questions getting started or if you'd like to get involved in the documentation or module development process, don't hesitate to jump on the mailing list or IRC.

Processes automated by the ATG library

While the ATG automation library (like ControlTier in general) can automate many operational processes, there are two that are the core focus of the solution:

  1. Code Build and Deployment
  2. Data Build and Deployment

Code build and deployment

This process provides end-to-end coordination of build and deployment processes for an ATG application's code modules. This process checks out code, calls build tools, packages the release, and deploys it (including coordinating any application server restarts). This process also makes it easy to manage rollbacks.

File:Atg code update.png

Workflow Step Tasks Coordinated
1. Build Workflow Each Builder is responsible for building a particular code module and follows the same basic pattern of code checkout, code build, and package publish.

Code checkout: extracts source code from a particular branch or label in your source repository.

Code building: Invokes the build tool to produce deployable application components. If your existing ANT build file has a well known target, it can be plugged in directly with little to no modification. ControlTier supports the building of ATG modules in standard or stand-alone format

Package publishing: The builds resulting packaged artifacts are published and registered in the ControlTier repository

2. Package Dependency Management Automates the updating of the ControlTier Object Model to reflect the correct package dependencies to be used by the Module Deploy process
3. Deploy Workflow Service life cycle: For each application container process that comprises your E-Commerce application, a basic pattern is followed: Stop, Package Installation, Configuration and Start

Stop - interfaces with the underlying app container to shut it down. Stop uses a comprehensive heuristic approach to guarantee shutdown (examines key ports, processes, and log file contents and reacts accordingly)

Package installation - Looks at the ControlTier Object Model and for each package dependency it finds it goes through the package installation life cycle (the details of which are determined by the package type)

Configuration - Processes any configuration templates, generating them for the current application release

Start - starts up the services in the required order and, to guarantee successful startup, uses heuristic techniques similar to that of the stop process

Outside of your ATG application server, the solution also coordinates to the deployment of packages to other kinds of deployments in your infrastructure (e.g. apache and other 3rd party applications)

For users running the Dynamo Application Server (DAS)

To support ATG customers running the Dynamo Application Server (DAS), ControlTier’s ATG Solution Library provides a number of key features specifically for the unique nature of the DAS environment.

  • The library exploits ATG's out of the box ant tasks for using the runDarina command for assembling .dar files
  • Application packages are structured to support staged deployment. This means you can opt to stage one version while running another to enable fast deployment or rollback.
  • The library can manage the automatic installation of platform components (such as Java) as well as any standard ATG self-extracting installer or updater to bootstrap application services on a basic OS system image (i.e. starting with an application login account and the ControlTier client installed).
  • Co-deployed Dynamo Application Servers can be managed as a single manageable collection. This is analogous to how JBOSS allows you to manage a set of local web applications

For users running the JBoss Application Server

To support ATG customers running on JBOSS, ControlTier’s ATG Solution Library provides a number of key features specifically for the unique nature of the JBOSS environment.

  • For JBOSS/J2EE deployment, the solution library exploits ATG's out of the box ant tasks for assembling .jar and .ear files during the build process.
  • Library is pre-configured to follow standard JBOSS application deployment conventions
  • Optional support for deployment and configuration of the underlying JBOSS platform. This covers automating such tasks as the following: installing the JBoss distribution, automatic port and environment configuration to support multiple JBoss instances on the same server, and managing datasource configuration settings.
  • The library can manage the automatic installation of platform components (such as Java and JBoss) as well as any standard ATG self-extracting installer or updater to bootstrap application services on a basic OS system image (i.e. starting with an application login account and the ControlTier client installed).

Automated ATG Administration via RMI Dispatching Component

Several routine tasks must be undertaken while deploying code and data during application releases. Typically, these tasks are done using the browser-based ATG Administrator web pages, that allow technicians to invoke methods on Nucleus exposed components.

ControlTier’s ATG Solution includes the RMI Dispatching component, a key mechanism that creates an extremely flexible scripting interface. Using this scripting interface, the ControlTier ATG Solution avoids the typical painstaking manual steps and streamlines end-to-end tasks.

File:Atg rmi dispatch.png

The ATG solution leverages the RMI Command dispatcher to interact with a number of Nucleus-exposed ATG components. Below are some examples:

  • PriceCache: invalidating product price caches
  • ProductCatalogSwitchingDataSource: managing switching data sources used during Catalog deployments
  • ModuleManager: looking up loaded module names
  • LoadControl: start/stop accepting Sessions

NFS/NAS Support

For environments that have NFS/NAS as part of their operational infrastructure we can coordinate the central deployment of module packages for use by a pool of servers.

Other Integrations

Source Repositories*

  • Subversion (1.6)
  • CVS (1.11.x)
  • Perforce (2009.1)
  • Git (1.6)

(* any repository with a command line utility can be automated)


Build Tools*

  • Ant (1.7 or previous)
  • Maven (1 and 2.x)
  • Script (any sh, bash, ksh, Windows Batch, or any BSF)

(* others can be added)


Application Servers*

  • ATG Platform (2006.3, 2007.1, 9.0, 9.1)
  • JBoss (4.03sp1, 4.04, 4.05, 4.2, 5.0 in testing)
  • DAS (2006.3, 2007.x)
  • Tomcat (4.x - 5.x)

(* contact us about the status of other versions)

Data Deployment

These processes are designed to address the specific needs around promoting an ATG application’s data from one environment to the next.

There are three types of data to consider: application data, catalog data, and content. Each follows a variant of the same basic workflow: export data from reference data source, version as a package in ControlTier repository, coordinate the import of the data to the target (including coordinating the execution of data management scripts before during and after that process). Because of ControlTier’s flexible architecture it is equally adept at working with and migrating small and large datasets.

File:Atg data update.png

Workflow Step Tasks Coordinated
1. Data Export Workflow Extracts the data to file format to enable migrating data dump from development environments to target QA and Production. Extraction can be done many ways (ATG proprietary XML repository dump format, Oracle export, MSSQL export, etc..)

Once exported to file format, the data is packaged, loaded into the ControlTier Repository and registered in the ControlTier Object Model

2. Package Dependency Management Automates the updating of the ControlTier Object Model to reflect the correct data package dependencies to be used by the Data Import process
3. Data Import Workflow Downloads appropriate export file (in packaged format) from repository and imports it into the target database.

For interacting with databases, the ControlTier Object Model captures settings like instance name, schema name, user name, and passwords (all sensitive settings are stored encrypted).

Pre and Post-import SQL script execution.

Automated ATG Administration via RMI Dispatching Component

Similar to the Code Build and Deployment process, during a Data Deployment several common tasks are performed that would normally require the use of the browser-based ATG Administrator web pages. ControlTier’s ATG Solution contains a RMI Dispatching component that can programmatically invoke methods on Nucleus exposed components and provides an extremely flexible scripting interface.


Support for Switching Datasources

ControlTier’s ATG Solution Library supports a switching datasource ("Data Source A/B switching") configuration. When utilizing this switching datasource scheme, the Updater associates a pair of catalog schema within a database instance and manages the switching between them at both the database and the app server level. ATG's RMI interface is used to manage datasource configuration and cache clearing at the application server level.


Deploying Content

If you have content files that must accompany the data change you can use the Content Deployment Library in conjunction with the ATG Solution Library to easily handle that. This will automate the promotion of content from one environment to another by extracting content from a source code repository, packaging it, and deploying it to target environments using one standardized end-to-end process.

This offers a number of notable features for organizations where content migration and promotion is a frequent and critical process, including: coordinating data and code releases, structured packaging, rollback, deployment task delegation, reporting, and a standardized web-based operational interface.


Supported databases*

  • Oracle (11g or previous)
  • MicrosoftSQL (SQL Server 2005 or previous)
  • MySQL (5.x or previous)

(* ask about other databases or other versions)

Development