TDIing out loud

Ramblings on the paradigm-shift that is TDI.

Thursday, June 12, 2008

Changing the Solution Directory

Normally, TDI is installed to a program area (e.g. Program Files) and the TDI project files are located in the Solution Directory, which under Windows is "My Documents/TDI"; In the same way that you store your text processor binaries separately from the documents you write with them. This making it easier to include TDI solutions in your existing backup plan.

I've seen a lot of people configure TDI to use the installation folder as the solution directory. Understandable. When I first install some new piece of software, I also want to limit it's spread on my disk until I've decided whether that to let it stay or not.

So when that time comes when you want to change this choice of Solution Directory, then you only have to edit a couple of batch/script files:

o ibmdisrv - which starts the TDI Server.
o ibmditk - for the Config Editor dev environment).

Both are either batch-files or scripts and reside in the TDI install folder.

Just change the third line shown in the snippet below for both files (Windows example):

. . .
rem Only set TDI_SOLDIR if it hasn't been set already in caller's shell
if .%TDI_SOLDIR%==. (
set TDI_SOLDIR="C:\Documents and Settings\\My Documents\TDI"
)
call "C:\Program Files\IBM\TDI\V6.1.1_GA\ibmdicwd" %TDI_SOLDIR%
. . .

As you can see, there is also a Windows environment variable (TDI_SOLDIR) that you can use as well to change this setting.

And finally, there is the -s commandline option for specifying the Solution Directory on startup of either the Server or the CE:

ibmdisrv -c ITIL.xml -r Omnibus_2_TSRM, TSRM_2_Omnibus -s d:\ISM\

This is also a handy option if you need to run someone else's Config, but don't want to mix their project files in with yours. Or if you want to have multiple TDI Servers running on the same machine but with different API ports. Multiple SolDirs means multiple solution.properties files, each with its own api.remote.naming.port value.

P.S. I don't have the Unix scripts in front of me right now, but they are also easy to fix.

No comments: