Access Keys:
Skip to content (Access Key - 0)

How to Change the Target Grid


caGrid provides the ability to be easily reconfigured to access multiple different grid environments. That is, when its clients and applications access "the grid" they are configured with the appropriate settings (e.g. service addresses, security settings, etc) for the appropriate grid. The most common use for this capability is to easily target a development or training grid when learning to use caGrid, or while developing applications and services, and then re-targeting the official production grid for production development or deployment.

Process


In order to use any feature of caGrid, the project must first be built. You can see detailed instructions on building caGrid here, but generally you just need to type the following command from the caGrid directory:

ant all

Once caGrid is built, it is already configured to target a default grid. If you are using a development checkout of caGrid, this will be the development grid, if you are using a release, this will be the current production grid. You can find details about what grid you are currently targeting at anytime by typing the following command from the caGrid directory:

ant configureHelp

Running this command should output something similar to the following.

configureHelp:
     [echo] =====================================================================================
     [echo] |    CONFIGURED TO USE GRID: nci_prod-1.2 AT: ${target.grid.configure.time}
     [echo] |
     [echo] |    THE VALID TARGET GRIDS ARE:
     [echo] |      - nci_dev-1.1
     [echo] |      - nci_dev-1.2
     [echo] |      - nci_prod-1.1
     [echo] |      - nci_prod-1.2
     [echo] |      - nci_qa-1.1
     [echo] |      - nci_qa-1.2
     [echo] |      - nci_stage-1.1
     [echo] |      - nci_stage-1.2
     [echo] |      - osu_dev-1.1
     [echo] |      - osu_dev-1.2
     [echo] |      - training-1.1
     [echo] |      - training-1.2
     [echo] |
     [echo] -------------------------------------------------------------------------------------
     [echo] |    NOTE: To use a different target grid, set property 'target.grid'
     [echo] |    to the grid's name, and run the 'configure' target.
     [echo] |
     [echo] |    For example, type:
     [echo] |        ant -Dtarget.grid=nci_prod-1.2 configure
     [echo] =====================================================================================

BUILD SUCCESSFUL
Total time: 2 seconds

The first line shows the current target grid, and when caGrid was configured to use it. Next the available target grids are listed. Finally, brief instructions are given for how to change do a different grid.

In order to use the training grid, the following command should be run from the caGrid directory:

ant -Dtarget.grid=training-1.2 configure

NOTE: In the caGrid 1.1 release, you would use:

ant -Dtarget.grid=training configure

Running this command will:

  • run through a process of reconfiguring all of the projects which have some dependency on the grid
  • removes any locally stored preferences which are grid specific (such as used by Introduce and the security UIs)
  • reinstalls all caGrid Introduce extensions into Introduce
  • synchronizes your local machine with the appropriate trust fabric
  • display the configuration information which was just applied (as is shown above from the configureHelp target)

NOTE: If the command is not successful, make sure you are using a target grid as specified in the list of valid grids from the configureHelp target, and you have previously built caGrid (ant all).*Also note that cleaning and rebuilding caGrid does not remove these settings; they must be reset with the configure-clean command.

To change back to the default grid at any time, you may just type the following command from the caGrid directory:

ant configure-clean configure

Issues


If you are building caGrid 1.2, you need to make sure to use a 1.2 grid. If you use a 1.1 grid, you may see an error like this:

[ivy:resolve] :: problems summary ::
[ivy:resolve] :::: WARNINGS
[ivy:resolve] 		::::::::::::::::::::::::::::::::::::::::::::::
[ivy:resolve] 		::          UNRESOLVED DEPENDENCIES         ::
[ivy:resolve] 		::::::::::::::::::::::::::::::::::::::::::::::
[ivy:resolve] 		:: caGrid#target_grid;training-1.1: configuration(s) not found in caGrid#target_grid;training-1.1: cds-ui. It was required from caGrid#gaards-ui;1.2-dev target_grid
[ivy:resolve] 		::::::::::::::::::::::::::::::::::::::::::::::
[ivy:resolve]
[ivy:resolve]
[ivy:resolve] :: USE VERBOSE OR DEBUG MESSAGE LEVEL FOR MORE DETAILS

This is because caGrid 1.2 has new services (such as the CDS) that some components depend on, which did not exist in caGrid 1.1.

Last edited by
Sarah Honacki (1182 days ago) , ...
Adaptavist Theme Builder Powered by Atlassian Confluence