Personal tools
You are here: Home Framework Documentation Administrators Guide Appendix A - Development

11      Appendix A - Development

11.1    Administering Eclipse

11.1.1    Installing Eclipse

  • The latest version of the Eclipse Integrated Development Environment (IDE) can be downloaded from http://www.eclipse.org .
  • The eclipse IDE is packaged in a zip archive:  e.g. eclipse-SDK-3.2.2-win32.zip.
  • Simply download the archive and extract it to the desired base directory.
  • Note:  subsequently, the directory Eclipse is installed in is referred to as the Eclipse home directory.

11.1.2    Configuring Eclipse

Ensure the Java properties are configured appropriately:

  • Select the Window menu item from the Main menu and select the Preferences menu item.
  • System presents the Preferences dialog.

Ensure a Java Runtime Edition (JRE) is configured for the Java installation.

  • Select the Java tree node and select the Installed JRE child tree node.
  • If the JRE of the Java home directory is not defined, press the Add button.
  • Enter the JRE name:  e.g. 1.6.0.
  • Choose the JRE home directory:  e.g., C:\jdk1.6.0.
  • Press the OK button.

Ensure the Compiler Compliance Level is set appropriately.

  • Select the Java tree node and select the Compiler child tree node.
  • Ensure the Java compiler compliance level is set to 5.0.

Ensure the Compiler Compliance Level is set appropriately.

·         Select the Java tree node and select the Compiler child tree node and select the Errors/Warning child tree node.

·         Under Potential programming programs expandable section:

o   Ensure Serializable class without serialVersionUIDava is set to Ignore.

·         Under Generic type expandable section:

o   Ensure Unchecked generic type operation is set to Ignore.

o   Ensure Usage of a raw type is set to Ignore.

·         Under Annotations expandable section:

o   Ensure Missing ‘@Override’ annotation is set to Warning.

o   Ensure Enable ‘@SuppressWarnings’ annotation is checked.

11.1.3    Running Eclipse

·         Eclipse can be started by running eclipse.exe from the Eclipse home directory.

·         The first time Eclipse is run, it will ask for the workspace.  Choose the workspace defined in the Framework base directory (e.g., D:\Framework\workspace).

Note:  it is recommended that a shortcut to eclipse.exe be placed on the developer’s desktop or on the taskbar.

 

11.2    Administering CVS

The following sections apply to CVSNT.  CVSNT is an open-source, free implementation of CVS for NT/2000/2003/XP available from http://www.cvsnt.com .

 

Installation details can be found in the InstallationTips.pdf.

11.2.1    Administering a CVS Server

11.2.1.1  Installing a CVS Server

Execute the cvsnt-2.5.01.1976.msi and follow the instructions.  CVSNT installs two services:  CVS Dispatch Service (the main server portion of CVSNT) and CVS Locking Service (that handles pessimistic locking scenarios if they are enabled).  By default, both of these services are set to automatically start.

11.2.1.2  Creating a Repository

  • Open the CVSNT Control Panel.  CVSNT installs a CVSNT Control Panel application which can be accessed from the start menu under the CVSNT folder.
    • Select the Repositories tab folder and push the Add button.
    • Enter a Location (the base directory of the repository), enter a Name (the logical name used by clients connecting to this repository), enter a Description (for information purpose), ensure the Publish option is checked, and press the Ok button.
    • System creates the repository directory and adds the appropriate CVS control files.

11.2.1.3  Securing a Repository

The best way to secure the repository is to leverage the XP/2003 security model of groups and users.

  • Open the MMC for Local Users and Groups (accessible under the Control Panel/Administrative Tools/Computer Management).
    • Create a Group called CVSUsers.
    • For each user that requires access to the CVS repository, ensure that the user is a member of the CVSUsers group.  If necessary, create users and assign them to this group.
  • Using standard windows security, grant the CVSUsers group Full Control.  This can be achieved by bringing up the properties for the repository directory, selecting the Security tab, adding the CVSUsers group, and ensuring the Full Control permission is checked, then selecting Apply.  A finer granularity of security can be achieved by defining additional groups, and granting permission to the appropriate module with the repository directory.  Additionally, Full Control must be granted to the temporary directory used by CVS (by default, this is <windows home>\TEMP).

11.2.2    Administering a CVS Client

The following assumes the Eclipse integrated development environment (IDE) is being used by the developers.  Eclipse can be downloaded from http://www.eclipse.org .  CVS has been tested with Eclipse SDK v3.1.  Eclipse includes a CVS Client plugin that automatically supports CVS.  Eclipse includes useful help information on CVS support under the Overview Help \ Team Support icon.

11.2.2.1  Creating a Repository Location

  • Open the CVS Repositories view by selecting Window > Show View > Other... on the Main menu bar and then selecting CVS > CVS Repositories from the Show View dialog. Alternatively, the CVS Repositories view is also shown in the CVS Repository Exploring perspective.
  • On the toolbar, click on Add CVS Repository (or from the context menu of the CVS Repositories view, select New > Repository Location). The Add CVS Repository wizard opens.
  • Enter the information required to identify and connect to the repository location:
    • In the Host field, type the address of the host. (For example: mymachine.com).
    • In the Repository path field, type the path to the repository on the host (for example /home/repo, d:/repo.)
    • In the User field, enter the username under which you want to connect to the repository.
    • In the Password field, type the password for the above user name.
    • From the Connection Type list, select the authentication protocol of the CVS server.  There are three connection methods that come with the Eclipse CVS client:
      • pserver - a CVS specific connection method.
      • extssh - an SSH 2.0 client included with Eclipse
      • ext - the CVS ext connection method which uses an external tool such as SSH to connect to the repository. The tool used by ext is configured in the Team > CVS > EXT Connection Method preference page.
    • If the host uses a custom port, enable Use Port and enter the port number.
  • Select Save Password if you want to save the password in the Eclipse keyring file.
  • Click Finish. The repository location is created.

11.2.2.2  Importing a Project into the Repository

In Eclipse, this process is referred to as sharing.

  • Select the project to be shared.
  • Select Team > Share Project... from the project's pop-up menu. The Share Project wizard opens.
  • From the list of available repository providers, choose CVS and click Next.
  • Select the target repository from the list of known repositories click Next.
  • Either choose to use the name of the local project as the remote project name or enter another name and click Next.
  • System presents the resources of the new project as outgoing additions.
  • Chose to commit or ignore resources from this page.
  • Click Finish to share the project with the repository.
  • System prompts to commit any resources in the new project that have not yet been committed or ignored. Choosing to do so will run the commit operation in the background

11.2.2.3  Updating a Project with Changes from the Repository

  • Select Team > Update.  This can also be invoked for a specific project from its context menu.
  • The contents of the local resources will be updated with incoming changes.
  • For non-conflicting and auto-mergeable conflicts, there is no additional action required (for auto-mergeable conflicts, the changed local resource is moved to a file prefixed with ".#" just in case the auto-merge wasn't what the user wanted).
  • For non-auto-mergeable conflicts, the conflicts are either merged into the local resource using special CVS specific markup text (for ASCII files) or the changed local resource is moved to a file prefixed with ".#" (for binary files).
  • Also, it is often desirable to know what incoming changes there are before updating any local resources. These issues are addressed by the Synchronize view (see Eclipse documentation for details).

11.2.2.4  Committing Changes in an Project into the Repository

Always update before committing in order to ensure that you have the latest state of the repository before committing more changes.

  • Select Team > Commit.  This can also be invoked for a specific project from its context menu.  It can also be invoked for one-or-more specific resources.
  • If there are new files whose file types cannot be determined automatically, the first page of the Commit dialog will present the unknown types and allow you to set them appropriately to either ASCII or binary. Click Next to continue.
  • On the Comment page, provide a comment for your changes (for example, Fixed the spelling mistakes).
  • The Comment page also allows the user to preview the files that are about to be committed.
  • If any of the files are known to be conflicting changes, the commit will not be allowed.
  • If there are no known conflicting changes the commit will be allowed but there could still be conflicting changes on the server (i.e. conflicting changes on the server become known to the client during a synchronize operation).
  • If there are conflicting changes on any files that are committed, the operation will fail. If this occurs, you must either perform an update or use the Synchronize view to resolve the conflicts.

11.3    Installing Ant

  • The latest version of ant can be downloaded from http://ant.apache.org.
  • Download the ant distribution zip file and uncompress it.
  • Unzip the distribution file to an ant home directory of your choice (this document assume c:/ant).

11.4    Configuring Ant

Gaining access to the Environment Variables:

  • User opens the System icon in the Control Panel.
  • System presents the System Properties dialog.
  • User selects the Advanced tab.

Adding the Ant Binaries to the path:

  • User presses the Environment Variables button.
  • System presents the Environment Variable dialog.
  • Select the Path variable under the  System Variable group and press Edit
  • User adds c:\ant\bin; to the start of the Path Variable value.

Adding an ANT_HOME environment variable:

  • User presses the New button.
  • System presents the New System Variable dialog.
  • User enters ANT_HOME as the Variable name.
  • User enters c:\ant as the Variable value.