How a .NET application determines what channel definition to use

本文详细解释了在使用WebSphere MQ.NET客户端环境时,如何确定要使用的通道定义,包括多个定义的存在、优先级顺序以及如何从不同资源获取通道定义。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

How a .NET application determines what channel definition to use

In the WebSphere® MQ .NET client environment, the channel definition to be used can be specified in a number of different ways. Multiple specifications of the channel definition can exist. An application derives the channel definition from one or more sources.

If more than one channel definition exists, the one used is selected in the following priority order:
  1. Properties specified on the MQQueueManager constructor, either explicitly or by includingMQC.CHANNEL_PROPERTY in the properties hashtable
  2. A property MQC.CHANNEL_PROPERTY in the MQEnvironment.properties hashtable
  3. The property Channel in MQEnvironment
  4. The .NET application configuration file, section name CHANNELS, key ServerConnectionParms (applies to managed connections only)
  5. The MQSERVER environment variable
  6. The client configuration file, stanza CHANNELS, Attribute ServerConnectionParms
  7. The client channel definition table (CCDT). The location of the CCDT is specified in the .NET application configuration file (applies to managed connections only)
  8. The client channel definition table (CCDT). The location of the CCDT is specified using the environment variables MQCHLLIB and MQCHLTAB
  9. The client channel definition table (CCDT). The location of the CCDT is specified using the client configuration file
For items 1-3, the channel definition is built up field by field from values provided by the application. These values can be provided using different interfaces and multiple values can exist for each one. Field values are added to the channel definition following the priority order given:
  1. The value of connName on the MQQueueManager constructor
  2. Values of properties from the MQQueueManager.properties hashtable
  3. Values of properties from the MQEnvironment.properties hashtable
  4. Values set as MQEnvironment fields (for example, MQEnvironment.Hostname, MQEnvironment.Port)

For items 4-6, the entire channel definition is supplied as the value. Unspecified fields on the channel definition take the system defaults. No values from other methods of defining channels and their fields are merged with these specifications.

For items 7-9, the entire channel definition is taken from the CCDT. Fields which were not specified explicitly when the channel was defined take the system defaults. No values from other methods of defining channels and their fields are merged with these specifications.


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值