This page last changed on Sep 11, 2008 by williams.

Abstract

This page describes integration of CruiseControl.NET with Telelogic's Synergy SCM product suite, specifically CM Synergy as well as ChangeSynergy. Detection of modifications is entirely task based rather than object based, which may present problems for pre-6.3 lifecycles. Successful integration may be published through shared manual task folders and/or baselining.

Warning

This integration has been thoroughly tested against CM Synergy 6.3 SP4 and ChangeSynergy 4.3 SP3 Windows/Informix with the DCM option enabled. While untested, CM Synergy installations on Unix/Informix or Unix/Oracle should function properly.

Background

CM Synergy Concepts is arguably one of the best conceptual explanations of CM Synergy. Consider it a prerequisite for implementing continuous integration with CM Synergy. Robert Smith, from the CruiseControl for Java site, deserves a great deal of credit for explaining the product better than Telelogic ever has.

Methodology of integration with CCNET

Certain assumptions have been made about the integration of CruiseControl.NET and CM Synergy. First, it is assumed that all projects use a task based reconfigure template, rather than an object based.

  • The reconfigure template for all projects is task based, not object status based.
  • Developers have there own projects with purpose "Insulated Development"
  • There's no real point to continuous integration for "Collaborative Development" purpose projects, since Synergy is not a label based system.
  • Build Managers test completed tasks in a project with purpose "Integration Testing" (or similar).
  • We could create a baseline in the integration project to push completed tasks to the developers; however, this is less than ideal. Baselines in Synergy are expensive and were intended for milestone events like completion of a feature, or a configuration used for a QA testing round.
  • The more efficient approach is to have a shared task folder that is included in each developer's reconfigure template/properties.
    • Successfully integrated tasks can be manually added to this folder.
    • This will push newly completed and integrated tasks to developers when they reconfigure (i.e., "update members").

CM Synergy Example Configurations

Example using Defaults
<sourcecontrol type="synergy">
    <connection>
        <host>myserver</host>
        <database>\\myserver\share\mydatabase</database>
    </connection>
    <project>
        <release>Product/1.0</release>
        <projectSpecification>Product-1</projectSpecification>
        <taskFolder>1234</taskFolder>
    </project>
    <changeSynergy>
        <url>http://myserver:8060</url>
    </changeSynergy>
</sourcecontrol>
Full Example
<sourcecontrol type="synergy">
    <connection>
        <host>myserver</host>
        <database>\\myserver\share\mydatabase</database>
        <!-- store values in an environmental variable-->
        <username>%CCM_USER%</username>
        <password>%CCM_PWD%</password>
        <role>build_mgr</role>
        <homeDirectory>D:\cmsynergy\%CCM_USER%</homeDirectory>
        <clientDatabaseDirectory>D:\cmsynergy\uidb</clientDatabaseDirectory>
        <polling>true</polling>
        <timeout>3600</timeout>
    </connection>
    <project>
        <release>Product/1.0</release>
        <projectSpecification>Product-1</projectSpecification>
        <taskFolder>1234</taskFolder>
        <baseline>false</baseline>
        <purpose>Integration Testing</purpose>
        <template>true</template>
    </project>
    <changeSynergy>
        <role>User</role>
        <url>http://myserver:8060</url>
        <username>%CS_USER%</username>
        <password>%CS_PWD%</password>
    </changeSynergy>
</sourcecontrol>

CM Synergy Configuration Elements

Configuration Reuse

By creating separate child nodes for the <connection>, <project>, and <changeSynergy> configuration elements, it is very easy to create reusable blocks of XML. For more information on XML DTD entities and reusable configuration blocks, see JIRA issue CCNET-239 and Nithy Palanivelu's Weblog

<connection> node (required)

Connection Item Description Type Environmental Variable Expansion Default
workingDirectory The directory to execute all CM Synergy commands from. string Yes "%PROGRAMFILES%\Telelogic\CM Synergy 6.3\bin"
executable The executable filename/path for the CM Synergy command line interface. string Yes "ccm.exe"
host The hostname of the Synergy server. string No "localhost"
database The physical path to the Informix database for the Synergy database. string No Required.
username The username for the Synergy session. string Yes "%USERNAME%"
password The Synergy password for the associated username. string Yes ""
role The role to use for the Synergy session. string No "build_mgr"
homeDirectory The full physical path of the home directory for the associated username on the client machine. This corresponds to the repository root. string Yes "%SystemDrive%\cmsynergy\\\%USERNAME%"
clientDatabaseDirectory Path for the remote client session to copy database information to. string Yes "%SystemDrive%\cmsynergy\uidb"
polling If enabled, queues commands while the server is offline. boolean No false
timeout Timeout in seconds for all Synergy commands. int No 3600
issueUrlBuilder Converts the comment (or parts from it) into an url pointing to the issue for this build.
See Issue Builder for more details
Group N/A false
The Polling Feature

The polling feature is useful if your Synergy installation routinely goes offline (i.e., "protected mode"). Long runing builds may inadventently conflict with the routine downtime schedules. For example, polling allows your build to queue CM Synergy commands until the nightly backup completes.

Environmental Variables

Environmental variable support enables you to keep your sensitive build manager credentials out of the CCNET configuration file. This is especially important if the configuration file is under source control, whereby it would be readable by all CM Synergy users.

<project> node (required)

Project Item Description Type Environmental Variable Expansion Default
release The component + version specification. NB. The specification is case-sensitive. string No Required.
projectSpecification The Synergy project specification for the integration project. string No Required.
taskFolder The folder specification for the shared folder which will be used to "manually" add successfully integrated tasks added to. int No 0
baseline Flag to creates a new baseline of the project configuration after a successful integration. boolean No false
purpose The Synergy purpose specification for baselines created by CruiseControl.NET. string No "Integration Testing"
template Flag to reset the reconfigure properties for this project and all subprojects to use the reconfigure template. boolean No false

<changeSynergy> node (optional)

Change Synergy Item Description Type Environmental Variable Expansion Default
url The base HTTP URL for your ChangeSynergy installation string No Required.
username The optional username for ChangeSynergy anonymous access. string Yes Optional.
password The optional password for ChangeSynergy anonymous access. string Yes Optional.
role The role to use for the Synergy session. string No "User"
Security Warning

Be careful about specifying a ChangeSynergy username and password. If you do not specify these optional values, the end-user will be prompted by ChangeSynergy to enter valid credentials. If an anonymous access account is used, specify a user that has only read-only permissions within ChangeSynergy. This will prevent someone from modifying objects, such as tasks, through ChangeSynergy. If you specify an impersonation account with write permissions, a malicious user could bypass auditing in ChangeSynergy.

  • Contributed by Steve Jansen
Document generated by Confluence on Mar 14, 2009 02:55