【问题标题】:WLST Scripting Error - Must Activate Changes BugWLST 脚本错误 - 必须激活更改错误
【发布时间】:2017-03-20 21:55:29
【问题描述】:

我编写了一个脚本来自动化 Weblogic 部署,并且在脚本的 undeploy 和有时 deploy 部分有一条错误消息说,“任务不能进一步处理,直到激活当前编辑会话。发生这种情况时,任务处理将继续。用户可以退出部署工具而不影响任务。“发生这种情况时,我必须单击“激活更改”在管理控制台的 GUI 上,以便脚本继续执行我希望它执行的操作。 是否有任何 WLST Jython 程序员知道如何避免这个问题?我正在尝试在不接触 GUI 的情况下运行脚本。

此外,有时托管服务器的状态会更改为“部署初始化”。当这种情况发生时,我知道事情真的一团糟。我认为当我选择另一个选项“撤消所有更改”时会发生这种情况。

【问题讨论】:

    标签: weblogic wlst


    【解决方案1】:

    blog 中有一个很好的代码答案

    【讨论】:

      【解决方案2】:

      最好总是做一些小事,激活这些更改,然后继续下一个任务。

      在进行取消部署和部署时,最好先取消部署,激活更改,然后再进行部署并再次激活,这样可以保持干净,否则在一次性激活所有更改时可能会发生冲突。

      你不必从控制台激活,你可以从 wlst 使用 activate([timeout], [block])

      【讨论】:

      • @SridharS,你能在这里提供一个示例代码吗?
      • @SridharS,你能在这里提供一个示例代码吗?我从我的 python 程序执行了 deploy(application, path, targets=servername) 命令..它挂断了以下日志[Deployer:149140]The task cannot be processed further until the current edit session is activated. When this occurs, task processing will continue. The user can exit the deployer tool without affecting the task..............................................................
      【解决方案3】:

      确保每个会话提交一个事务。这样您就不会因为当前部署/取消部署任务引发的问题而错过您之前的取消部署/部署状态。请在下面找到示例代码块。

          app-list = [app1 app2 app3 ... app60]
          for app in app-list:
              edit()
              startEdit()
              app-path = "<path-to-your-apps>/"+app1
              deploy(app,app-path,targets=<your-targets>)
              print 'deployed '+app
              activate()
      

      【讨论】:

      • @praveen-raj-kumar,你能在这里提供一个示例代码吗?我从我的 python 程序执行了 deploy(application, path, targets=servername) 命令..它挂断了以下日志[Deployer:149140]The task cannot be processed further until the current edit session is activated. When this occurs, task processing will continue. The user can exit the deployer tool without affecting the task..............................................................
      • 将其添加到我的原始答案中
      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-05-31
      • 2015-12-29
      相关资源
      最近更新 更多