使用脚本来配置新的协议

可以使用脚本编制和 wsadmin 工具来配置新的协议。

开始之前

开始本任务前,wsadmin 工具必须正在运行。请参阅使用 wsadmin 脚本编制启动 wsadmin 脚本编制客户机一文,以了解更多信息。

关于此任务

执行以下步骤配置新的协议:

过程

  1. 确定父标识:
    • 使用 Jacl:

      set newmp [$AdminConfig getid /Cell:mycell/Node:mynode/MailProvider:MP1/]
    • 使用 Jython:
      newmp = AdminConfig.create('MailProvider', node, mpAttrs)
      print newmp
    示例输出:
    MP1(cells/mycell/nodes/mynode|resources.xml#MailProvider_1)
  2. 获取必需的属性:
    • 使用 Jacl:

      $AdminConfig required ProtocolProvider
    • 使用 Jython:
      print AdminConfig.required('ProtocolProvider')
    示例输出:
    Attribute   Type
    protocol		    String
    classname   String
  3. 设置必需的属性:
    • 使用 Jacl:

      set protocol [list protocol "Put the protocol here"]
      set classname [list classname "Put the class name here"]
      set ppAttrs [list $protocol $classname]
      示例输出:
      {protocol protocol1} {classname classname1}
    • 使用 Jython:
      protocol = ['protocol', "Put the protocol here"]
      classname = ['classname', "Put the class name here"]
      ppAttrs = [protocol, classname]
      print ppAttrs
      示例输出:
      [[protocol, protocol1], [classname, classname1]]
  4. 创建协议提供程序:
    • 使用 Jacl:

      $AdminConfig create ProtocolProvider $newmp $ppAttrs
    • 使用 Jython:
      print AdminConfig.create('ProtocolProvider', newmp, ppAttrs)
    示例输出:
    (cells/mycell/nodes/mynode|resources.xml#ProtocolProvider_4)
  5. 保存配置更改。
  6. 仅在 Network Deployment 环境中使节点同步。

指示主题类型的图标 任务主题



时间戳记图标 最近一次更新时间: last_date
http://www14.software.ibm.com/webapp/wsbroker/redirect?version=cord&product=was-nd-mp&topic=txml_protocol
文件名:txml_protocol.html