It may be useful to consider using a configuration file, more commonly called a properties file -- using Properties class.
System.getEnv() method is deprecated in Java 1.3.1
Also, since you seem to be using eGate, consider the limitation of using environment variables. Since eWay processes are child processes of the control broker, the environment is inherited in the same way. Therefore, changing enviroment variable will require you shut all components from JMS Servers (IQ Managers) to e*Way all the way to the Control broker.
To use the properties file you may want to enter the following in the collabroation rule "initialization string"
Then with the location of the property file (in this case CNX.properties) you can use the Properties class to get a the values you need.
It is most common to use this feature within the userInitialize() method of the collaboration rule -- but rememeber that exceptions in this method do not prevent the executeBusinessRule() method from executing -- althgouth workaround exist for that too.
This forum has good help on using the Properties class.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.