Changeset 7aec37d for fedd


Ignore:
Timestamp:
Aug 1, 2008 2:50:26 PM (16 years ago)
Author:
Ted Faber <faber@…>
Branches:
axis_example, compt_changes, info-ops, master, version-1.30, version-2.00, version-3.01, version-3.02
Children:
e5a8b44
Parents:
808889e
Message:

split out internal interfaces

Location:
fedd
Files:
3 added
6 edited

Legend:

Unmodified
Added
Removed
  • fedd/Makefile

    r808889e r7aec37d  
    11
    2 GENERATED_MODS=fedd_services.py fedd_services_types.py
    3 WSDL_FILES=fedd.wsdl fedd_bindings.wsdl fedd_messages.wsdl fedd_types.xsd
     2GENERATED_MODS= fedd_services.py fedd_internal_services.py \
     3                fedd_services_types.py
     4WSDL_FILES= fedd.wsdl fedd_bindings.wsdl fedd_messages.wsdl fedd_types.xsd \
     5            fedd_internal.wsdl fedd_internal_bindings.wsdl \
     6            fedd_internal_messages.wsdl
    47
    58all:    ${GENERATED_MODS}
     
    811${GENERATED_MODS}:      ${WSDL_FILES}
    912        /usr/local/bin/wsdl2py --file fedd.wsdl --complexType
     13        /usr/local/bin/wsdl2py --file fedd_internal.wsdl --complexType \
     14                --types=fedd_services_types
    1015
    1116clean:
  • fedd/fedd.py

    r808889e r7aec37d  
    5555        """Confirm that this class implements the namespace and SOAP method"""
    5656        root = ps.body_root
    57         if root.namespaceURI != self.server.impl.soap_namespace:
     57        if root.namespaceURI not in self.server.impl.soap_namespaces:
    5858            self.send_fault(Fault(Fault.Client,
    5959                'Unknown namespace "%s"' % root.namespaceURI))
  • fedd/fedd_allocate_project.py

    r808889e r7aec37d  
    1919
    2020from fedd_services import *
     21from fedd_internal_services import *
    2122from fedd_util import *
    2223import parse_detail
     
    195196        if certs != None and isinstance(certs, type(tuple())):
    196197            self.cert_file, self.trusted_certs, self.cert_pwd = certs
    197             # self.cert_file = certs[0]
    198             # self.trusted_certs = certs[1]
    199             # self.cert_pwd = certs[2]
    200         else:
    201             self.cert_file = None
    202             self.trusted_certs = None
    203             self.cert_pwd = None
     198        else:
     199            self.cert_file, self.trusted_certs, self.cert_pwd = \
     200                    (None, None, None)
    204201
    205202    def dynamic_project(self, req, fedid=None):
     
    219216                    "Server certificates misconfigured")
    220217
    221         loc = feddServiceLocator();
    222         port = loc.getfeddPortType(self.url,
     218        loc = feddInternalServiceLocator();
     219        port = loc.getfeddInternalPortType(self.url,
    223220                transport=M2Crypto.httpslib.HTTPSConnection,
    224221                transdict={ 'ssl_context' : ctx })
  • fedd/fedd_bindings.wsdl

    r808889e r7aec37d  
    3737        </fault>
    3838      </operation>
    39       <operation name="AllocateProject">
    40         <documentation>
    41           The bindings of this operation are straightforward SOAP RPC 1.1.
    42         </documentation>
    43         <soap:operation soapAction="AllocateProject"/>
    44         <input>
    45           <soap:body use="encoded" parts="tns:AllocateProjectRequestBody"
    46             namespace="http://www.isi.edu/faber/fedd.wsdl"
    47             encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
    48         </input>
    49         <output>
    50           <soap:body use="encoded" parts="tns:AllocateProjectResponseBody"
    51             namespace="http://www.isi.edu/faber/fedd.wsdl"
    52             encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
    53         </output>
    54         <fault>
    55           <soap:fault use="encoded"  name="tns:AllocateProjectFault"
    56             namespace="http://www.isi.edu/faber/fedd.wsdl"
    57             encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
    58         </fault>
    59       </operation>
    6039    </binding>
    6140
  • fedd/fedd_messages.wsdl

    r808889e r7aec37d  
    1919  </message>
    2020
    21   <message name="AllocateProjectRequestMessage">
    22     <part name="AllocateProjectRequestBody" type="xsd1:projectAllocType"/>
    23   </message>
    24 
    25   <message name="AllocateProjectResponseMessage">
    26     <part name="AllocateProjectResponseBody"
    27       type="xsd1:projectAllocResponseType"/>
    28   </message>
    29 
    3021  <portType name="feddPortType">
    3122    <operation name="RequestAccess">
     
    3829        message="tns:FaultMessage"/>
    3930    </operation>
    40 
    41     <operation name="AllocateProject">
    42       <input message="tns:AllocateProjectRequestMessage"/>
    43       <output message="tns:AllocateProjectResponseMessage"/>
    44       <fault name="AllocateProjectFault"
    45         message="tns:FaultMessage"/>
    46     </operation>
    4731  </portType>
    4832</definitions>
  • fedd/fedd_proj.py

    r808889e r7aec37d  
    3939
    4040    # Used by the SOAP caller
    41     soap_namespace = 'http://www.isi.edu/faber/fedd.wsdl'
     41    soap_namespaces = ('http://www.isi.edu/faber/fedd.wsdl',
     42            'http://www.isi.edu/faber/fedd_internal.wsdl')
    4243    soap_methods = { 'RequestAccess': 'soap_RequestAccess' }
    4344    xmlrpc_methods = { 'RequestAccess': 'xmlrpc_RequestAccess' }
     
    449450                               
    450451                    ap = self.allocate_project.dynamic_project(preq)
    451                 else: pass    # SSH key additions
     452                else:
     453                    # XXX ssh key additions
     454                    ap = { 'project': \
     455                            { 'name' : { 'username' : found[0] },\
     456                              'user' : [ {\
     457                                'userID': { 'username' : found[1] }, \
     458                                'access': [ { 'sshPubkey': s } for s in ssh]}\
     459                                ]\
     460                            }\
     461                    }
    452462            else:
    453463                raise service_error(service_error.req,
Note: See TracChangeset for help on using the changeset viewer.