Sei sulla pagina 1di 4

mqsiapplybaroverride command

Use the mqsiapplybaroverride command to replace configurable values in the broker archive (BAR) deployment descriptor with new values that you specify in a properties file.

Supported platforms
Windows Linux and UNIX systems z/OS. Run this command by customizing and submitting BIPOBAR.

Purpose
Use the mqsireadbar command to see which properties you can configure using the mqsiapplybaroverride command. Write scripts to create broker archive files and apply different override values in the broker deployment descriptor archive file by using the mqsiapplybaroverride command, together with the mqsicreatebar command. For a list of message flow node properties and the corresponding properties of the mqsiapplybaroverride command, see Configurable properties. The mqsiapplybaroverride command properties are also listed in the tables of properties in the reference topic for each affected node.

Syntax
Syntax diagram format 2? 3? 4? 5? Railroad diagram -b BarFile Dotted decimal 1 mqsiapplybaroverride -p overridesFile -m manualOverrides -o outputFile -v traceFileName

Parameters
-b BarFile (Required) The path to the broker archive file (in compressed format) to which the override values apply. The path can be absolute or relative to the executable command. -p overridesFile (Optional) The path to one of the following resources: A broker archive containing the deployment descriptor that is used to apply overrides to the BAR file. You can use XML for the deployment descriptor file. If you use an XML property file written in EBCDIC onz/OS, ensure that you remove any encoding="UTF-8" from the XML header; for example, change: <?xml version="1.0" encoding="UTF-8"?> to

<?xml version="1.0"?> A properties file in which each line contains a propertyname=override or current-property-value=new-property-value pair. A deployment descriptor that is used to apply overrides to the BAR file. -m manualOverrides (Optional) A list of the property-name=override pairs, current-propertyvalue=override pairs, or a combination of them, to be applied to the BAR file. The pairs in the list are separated by commas (,). On Windows, you must enclose the list in quotation marks (" "). If used with the overridesFile ( p) parameter, overrides specified by the manualOverrides (m) parameter are performed after any overrides specified the p parameter have been made. -o outputFile (Optional) The name of the output BAR file to which the BAR file changes are to be made. If an output file is not specified, the input file is overwritten. -v traceFileName (Optional) Specifies that the internal trace is to be sent to the named file. In all cases, any existing deployment descriptor in the BAR file is renamed to META-INF\broker.xml.old, replacing any existing file of that name. Each override that is specified in a p overrides file or a m overrides list must conform to one of the following syntaxes: FlowName#NodeName.PropertyName=NewPropertyValue (or FlowName#PropertyName=NewPropertyValue for message flow properties) where: o FlowName is the name of the message flow without the .cmf extension (for example, Flow1). o NodeName is the optional name of the node whose property is overridden (for example, InputNode). o PropertyName is the name of the property being overridden (for example, queueName). o NewPropertyValue is the value to assign to that property (for example, PRODUCTION_QUEUE_NAME). OldPropertyValue=NewPropertyValue. This syntax does a global search and replace on the property value OldPropertyValue. It overrides the value fields of OldPropertyValue in the deployment descriptor with NewPropertyValue. FlowName#NodeName.PropertyName (or FlowName#PropertyName for message flow properties). This syntax removes any override applied to the property of the supplied name. When the mqsiapplybaroverride command runs, it displays the version of the command that is being used (either runtime environment or Message Broker Toolkit) before it does anything else. For example: BIP1138I: Overriding BAR File using runtime mqsiapplybaroverride

Authorization

On Windows Vista and Windows Server 2008 systems, the user ID used to run this command must be running with elevated privileges on the local system: The user ID must be a member of the group Administrators. The command must be started from an environment that has Run as Administrator authority. If you do not run the command from a privileged environment, you are asked to confirm that you want to continue. When you click OK, a new privileged command console is created and the command completed, but all responses are written to the privileged environment and are lost when that console closes when the command completes. On all operating systems, the user ID used to invoke this command must have write authority to the BAR file on the local system.

Responses
This command returns the following responses: 0 The command completed successfully. 99 One or more of the parameters that you specified is invalid. This command is supplied as a batch file. If you run the command in an automation system or from a script, use the Windows CALL command, to ensure that the correct ERRORLEVEL is returned: ... CALL mqsiapplybaroverride ...

Examples
Open the BAR file myflow.bar, and replace configurable values in its deployment descriptor (typically broker.xml) with the values that are specified in the properties file mychanges.properties: mqsiapplybaroverride -b myflow.bar -p mychanges.properties Override the deployment descriptor in c:\test.bar by using the key=value pairs specified in c:\my.properties: mqsiapplybaroverride -b c:\test.bar -p c:\my.properties Override the deployment descriptor in c:\test.bar by using the deployment descriptor contained in c:\previous.bar: mqsiapplybaroverride b c:\test.bar p c:\previous.bar Override the deployment descriptor in c:\test.bar by using the deployment descriptor contained in c:\broker.xml: mqsiapplybaroverride b c:\test.bar p c:\broker.xml

Override any properties with values set to OLDA and OLDB in c:\test.bar with the values NEWA and NEWB: mqsiapplybaroverride b c:\test.bar o OLDA=NEWA:OLDB=NEWB Override the value of the property name sampleFlow#MQInput.queueName to NEWC: mqsiapplybaroverride b c:\test.bar o sampleFlow#MQInput.queueName=NEWC

Potrebbero piacerti anche