Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/299.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
在WLST(weblogic脚本工具)中导入python模块_Python_Weblogic_Python Module_Wlst - Fatal编程技术网

在WLST(weblogic脚本工具)中导入python模块

在WLST(weblogic脚本工具)中导入python模块,python,weblogic,python-module,wlst,Python,Weblogic,Python Module,Wlst,我需要在WLST中导入python模块。例如,我需要WLST中的“信号”模块来编写超时函数。所以我问你怎么做 环境: Oracle Linux 6, Oracle Weblogic 11 此外,我让您看到WLST中的一段代码,其中我需要一个超时函数,以及它引发异常的原因: import sys import os from java.lang import System import getopt import time as systime [...] def _startServer(S

我需要在WLST中导入python模块。例如,我需要WLST中的“信号”模块来编写超时函数。所以我问你怎么做

环境: Oracle Linux 6, Oracle Weblogic 11

此外,我让您看到WLST中的一段代码,其中我需要一个超时函数,以及它引发异常的原因:

import sys
import os
from java.lang import System
import getopt
import time as systime

[...]

def _startServer(ServerName):
    while(true)
        try:
            cd('domainRuntime:/ServerLifeCycleRuntimes/'+ServerName);

            cmo.start();
            state=_serverstatus(ServerName);
            while (state!='RUNNING'):
                state=_serverstatus(ServerName);
                java.lang.Thread.sleep(5000);

            #=================
            # timeout function
            #=================

        except:
            print 'Error in getting current status of ' +ServerName+ '\n';
            print 'Please check logged in user has full access to complete the start operation on ' +ServerName+ '\n';

            os.popen('sh /home/oracle/scripts/logAnalytics.sh')
            systime.sleep(60)

            exit()
        break

[...]