ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/CRAB/python/SchedulerEdg.py
(Generate patch)

Comparing COMP/CRAB/python/SchedulerEdg.py (file contents):
Revision 1.10 by fanzago, Wed Aug 31 16:06:40 2005 UTC vs.
Revision 1.11 by corvo, Fri Sep 23 10:26:41 2005 UTC

# Line 44 | Line 44 | class SchedulerEdg(Scheduler):
44          # Add EDG_WL_LOCATION to the python path
45  
46          try:
47 <            path = os.environ['EDG_WL_LOCATION']
47 >            path = os.environ['GLITE_WMS_LOCATION']
48 > #            path = os.environ['EDG_WL_LOCATION']
49          except:
50 <            msg = "Error: the EDG_WL_LOCATION variable is not set."
50 >            msg = "Error: the GLITE_WMS_LOCATION variable is not set."
51 > #            msg = "Error: the EDG_WL_LOCATION variable is not set."
52              raise CrabException(msg)
53  
54          libPath=os.path.join(path, "lib")
# Line 77 | Line 79 | class SchedulerEdg(Scheduler):
79          Returns part of a job script which does scheduler-specific work.
80          """
81          txt = '\n'
82 <        txt += 'CloseCEs=`edg-brokerinfo getCE`\n'
82 >        # MARCO
83 >        txt += 'CloseCEs=`glite-brokerinfo getCE`\n'
84 >        # MARCO
85          txt += 'echo "CloseCEs = $CloseCEs"\n'
86          txt += 'CE=`echo $CloseCEs | sed -e "s/:.*//"`\n'
87          txt += 'echo "CE = $CE"\n'
# Line 214 | Line 218 | class SchedulerEdg(Scheduler):
218          """ Query a status of the job with id """
219  
220          hstates = {}
221 <        Status = importName('edg_wl_userinterface_common_LbWrapper', 'Status')
221 > #        Status = importName('edg_wl_userinterface_common_LbWrapper', 'Status')
222 >        Status = importName('glite_wmsui_LbWrapper', 'Status')
223          # Bypass edg-job-status interfacing directly to C++ API
224          # Job attribute vector to retrieve status without edg-job-status
225          level = 0
# Line 276 | Line 281 | class SchedulerEdg(Scheduler):
281          if timeleft < 1:  ok=0
282  
283          if ok==0:
284 <            msg = 'No valid proxy found !\n'
285 <            msg += "Please do 'grid-proxy-init'."
286 <            raise CrabException(msg)
284 >            print "No valid proxy found !\n"
285 >            print "Creating a user proxy with default length of 100h\n"
286 >            msg = "Unable to create a valid proxy!\n"
287 >            if os.system("grid-proxy-init -valid 100:00"):
288 >                raise CrabException(msg)
289          return
290      
291      def createSchScript(self, nj):
# Line 375 | Line 382 | class SchedulerEdg(Scheduler):
382                 req = req + ' && ('
383               for i in range(len(common.analisys_common_info['sites'])):
384                  req = req + 'other.GlueCEInfoHostName == "' \
385 <                      + common.analisys_common_info['sites'][i] + '"'
385 >                     + common.analisys_common_info['sites'][i] + '"'
386                  if ( i < (int(len(common.analisys_common_info['sites']) - 1)) ):
387                      req = req + ' || '
388               req = req + ')'

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines