Changeset 1775


Ignore:
Timestamp:
28/11/06 11:34:39 (13 years ago)
Author:
spascoe
Message:

Updated config importing in top-level script.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • TI03-DataExtractor/branches/repackaging/server/lib/ndg/dx/server/scripts/DXWSInterface.py

    r1764 r1775  
    3333import urllib 
    3434import os, types 
    35 from ConfigParser import SafeConfigParser 
    3635 
    3736# Import package modules 
     
    4342# Set global variables 
    4443timePattern=re.compile("(\d{4})-(\d{1,2})-(\d{1,2}).(\d{1,2}):(\d{1,2}):(\d{1,2}(\.\d+)?)") 
    45            
    46 # Create config object 
    47 config = SafeConfigParser() 
     44 
     45# Import configuration 
     46from ndg.util.config import config 
    4847configSection = 'ndg.dx.server' 
     48SOAP_SERVER_PORT = config.get(configSection, 'SOAP_SERVER_PORT') 
    4949 
    5050def callControllerDirectly(argList): 
     
    479479    # Serve all functions as Web Service methods.     
    480480    print "Setting up server" 
    481     portNumber=config.getint(configSection, SOAP_SERVER_PORT) 
    482     print "Serving Web Service on port: %s" % portNumber     
    483     dispatch.AsServer(port=portNumber, rpc=True)    
     481    print "Serving Web Service on port: %s" % SOAP_SERVER_PORT 
     482    dispatch.AsServer(port=SOAP_SERVER_PORT, rpc=True)    
Note: See TracChangeset for help on using the changeset viewer.