Looking up protocol file server properties: ProtocolBridgePropertiesExit2
If you have a large number of protocol file servers, you can implement the
com.ibm.wmqfte.exitroutine.api.ProtocolBridgePropertiesExit2 interface to look up
protocol file server properties that are referenced in transfers. You can implement this interface
in preference to maintaining a ProtocolBridgeProperties.xml file.
About this task
Managed File Transfer provides a sample user exit that looks up protocol file server properties. For more information, see Using the sample user exit to look up protocol file server properties.
Any user exit that looks up protocol bridge properties must implement the interface
com.ibm.wmqfte.exitroutine.api.ProtocolBridgePropertiesExit2. For more information,
see ProtocolBridgePropertiesExit.java interface.
You can chain multiple protocol server properties exits together in a similar manner to other
user exits. The exits are called in the order that they are specified in using the
protocolBridgePropertiesExitClasses property in the agent properties file. The
initialize methods all return separately and if one or more returns a value of false, the agent does
not start. The error is reported in the agent event log.
Only one overall result is returned for the getProtocolServerProperties methods of all of the exits. If the method returns a properties object as the result code, this value is the returned result and the getProtocolServerProperties methods of the subsequent exits are not called. If the method returns a value of null as the result code, the getProtocolServerProperties method of the next exit is called. If there is no subsequent exit, the null result is returned. An overall result code of null is considered as a lookup failure by the protocol bridge agent.
You are recommended to use the ProtocolBridgePropertiesExit2.java interface, but for information about the ProtocolBridgePropertiesExit.java interface, see Looking up protocol file server properties: ProtocolBridgePropertiesExit.
To run your exit, complete the following steps:
Procedure
- Compile the protocol server properties user exit.
- Create a Java archive (JAR) file containing the compiled exit and its package structure.
- Put the JAR file containing the exit class in the exits directory of the protocol bridge agent . This directory is found in the MQ_DATA_PATH/mqft/config/coordination_queue_manager/agents/bridge_agent_name directory.
-
Edit the property file of the protocol bridge agent to include the property
protocolBridgePropertiesExitClasses. For the value of this property, specify a comma-separated list of classes that implement a protocol bridge server properties user exit. The exit classes are called in the order that they are specified in this list. For more information, see The MFT agent.properties file. -
You can optionally specify the
protocolBridgePropertiesConfigurationproperty. The value you specify for this property is passed in as a String to the initialize() method of the exit classes specified byprotocolBridgePropertiesExitClasses. For more information, see The MFT agent.properties file.