Configurations Management

Configuration Management relates to two other areas in the software development process. They are Deployment and Release Management. In XOTclIDE Configuration Management is based on “Configurations Maps” that are used to specify a particular application (that is commonly deployed as one unit) as a collection of components. Versioned configuration maps allow performing release management. With XOTclIDE it is very easy to detect all changes (and their causers) between two application versions. You need no additional bureaucracy in your project.

Main Features

  • organize the groups of components which should be loaded and used together

  • build application (distribution) as a set of XOTclIDE components and a start script

  • build the base file for CompLoader.tcl to load your application directly from a database (thin-clients).

  • specify the exact version numbers and order of components which should be loaded.

Two tools for configuration management are available in XOTcl. The Configuration Map Browser can be used without the version control system and the extended Configuration Browser (Menu System->Version Control->Configuration Browser) can only be used with the version control system. The Configuration Browser saves all information in the version control system. You can import and export data between the two systems.

Configuration Map - Without Version Control System


It is strongly recommended to use the Configuration Browser if you work with the version control system.

A Configuration Map is a file (Tcl-script) that exactly specifies the components to be loaded and the start scripts. One script (preStartScript) will be invoked before loading components and one (startScript) will start your application after components are loaded. (see file Sample.cfmap)

The component list has the structure

{IDECore 10}
{IDEBase 12}
{IDEGUI newest}
{IDEView package}

The loader will search the components IDECore versionId=10 and IDEBase versionId=12 in the database. The newest version of the component IDEGUI will be loaded. The Component IDEView will be loaded with package require IDEView. For component IDEViewDB the loader will search first in the database and if not found it will try to load the package with package require IDEViewDB.

Using Configurations Maps

Launch the Configuration Browser by selecting menu System->Configuration Browser. Load the configuration map (Sample.cfmap) by selecting menu Edit->Load Configuration Map. Press the toggle button. You can see the aspects of configuration maps

  • preStartScript - tcl code that will be started before loading components

  • startScript - tcl code to start your application. Evaluated after loading all component.

You can use list boxes and buttons to specify the configuration components

Figure 4.6. Configuration Map Browser

Configuration Map Browser

You can edit them. Press Control-S to apply changes. Select Edit->Load Components to load components into the system (interpreter). Select Edit->Run Start Scripts to evaluate preStartScript startScript. You can make a new configuration map by using Edit->Init From System

Deploying Application

Distribution is the set of files that you can bind for example as a tar or zip file and distribute to other parts. A Configuration map is a base to specify the distribution. First load the component with Edit->Load Components than select menu Edit->Make Distribution. Select the directory (or create a new one). The system generates the set of files:

Sample  Sample.cfmap  SampleComponent.xotcl  pkgIndex.tcl

Sample is the executable file to start the application. Take a look at it.

# File generated by xotclIDE
# edit if you want

set sname [info script]
if {$sname==""} {
     # Run interactive for develop purposes
     set progdir [pwd]
} else {
     file lstat $sname stats
     # follow sym links
     if {$stats(type)=="link"} {
          set sname [file readlink $sname]
          if {[file pathtype $sname]=="relative"} {
                set sname [file join [file dirname [info script]] $sname]
     set progdir [file dirname $sname]

lappend auto_path [file dirname $progdir]
package require PlatformLogDumper
generateTclPlatformProtocol out.log

Configuration Browser - with Version Control System

Figure 4.7. Configuration Browser

Configuration Browser

This tool saves the configuration-maps in the version control systems so configuration-maps can also have editions and versions. Therefore you can have many editions of one configuration-map. You can browse changes among different configuration-map editions.


Unlike other browsers, all Configuration Browser functions are available only in pop-down menus.

For example you have built a program named sqleditor. In Version 0.1 your program is built from components as below

configuration-map - sqleditor (version 0.1)

  • guisystem - version 0.1

  • sqlparser - version 0.2

  • persistence - version 0.3

And the additional configuration-map (sub configuration map) sqlinterfaces - version 1.2

In version 0.2 sqleditor has the following configuration

  • guisystem - version 0.2

  • sqlparser - version 0.2

  • persistence - version 0.4

And the additional configuration-map (sub configuration map) sqlinterfaces - version 1.2

The main idea of Configuration Browser and Configuration-Maps is to have a medium for component based programming. This means you have many components that are parts of many products. All these components are in one version system.

It is not yet possible to use the Component Browser to generate a distribution. You must export a versioned configuration map to configuration map file with pop-up menu Conf. Version->export to map. Then you can use this file with Configuration Map Browser