使用wlst更改mbean中的属性。

时间:2012-11-27 10:13:26

标签: oracle weblogic jmx wlst osb

我正在使用Oracle Service Bus,我想创建一个脚本,它将更改特定mbean中的属性。

我找到了mbean:

com.bea:Name=OperationsConfig,
Location=AdminServer,
Type=com.bea.wli.sb.management.configuration.operations.OperationsConfigMBean 

我要更改的属性是DomainSLAAlertingEnabled

有人可以帮助我如何使用wlst(weblogic脚本工具)更改此mbean中的属性吗?

如何导航到此mbean,然后如何更改它?

DomainSLAAlertingEnabled是布尔值。

1 个答案:

答案 0 :(得分:4)

这是一个nice tutorial,显示如何使用WSLT 来配置各种Weblogic mbeans。

基本上,您需要:

  1. 连接给管理员:例如__connectToAdmin(properties)
  2. 检索Mbean :例如

    SOAInfraConfigobj = ObjectName(soaconfigmbean+’:Location=’+locationinfo+’,
                         name=’+appname+’, type=SoaInfraConfig,Application=’+appname)
    
  3. 设置所需的属性

    mbs.setAttribute(SOAInfraConfigobj, Attribute(auditlevel,auditlevelvalue))

  4. 当然,您需要修改特定MBean和特定属性的值。

相关问题