1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115
|
1. Get the grisu WSDL (from ngportal.vpac.org/grisu-ws/services/grisu)
2. Create C header (no sample xml)
wsdl2h -c -x -o grisu_ws.h grisu.wsdl
(NB: was a complaint here about missing typemap.dat)
3. Create C stub functions (no sample xml, client side only)
soapcpp2 -C -L -c -x grisu_ws.h
===========================
soapStub.h -> prototypes extracted from the WSDL
soapClient.c -> actual code for calling these web services
NB: link against soapssl NOT soap ... or it will complain.
--------------------------------
GRISU Authentication
Requires adding info to the soap header.
The basic steps are:
1) rewrite the SOAP_ENV__Header struct (soapStub.h) to
contain fields for the information we want to send
2) then we add some calls to the serializer routine
soap_out_SOAP_ENV__Header() (soapC.c) to embed and tag
these fields with the appropriate namespace and element names
3) now the client can allocate and set a new soap header, fill out
the fields and then make soap calls and the new header containing
authentication info will be serialized and sent as well.
myproxy credentials
===================
NB - the -a is needed for retrieval to work. Not 100% sure, but
could be because the myproxy server doesnt recognize the
certificate of the remote host that tries to retireve a credential
NB - also need to do setenv GT_PROXY_MODE = "old" for grisu to work.
This is a legacy issue, that will hopefully be fixed soon
NB - on my ubuntu box at home - some complaints about
MYPROXY_SERVER_DN which I havent yet been able to fix
Uploading: (do before running GDIS)
myproxy-init -l <name> -a -s myproxy.arcs.org.au
Retrieving: (test - if works - GDIS' soap requests should work)
myproxy-logon -l <name> -s myproxy.arcs.org.au
=======================
Current - create a text string containing XML (below) that describes
the job we want run. Pass this as the JDL to grisu ws?
Sample jdl taken from.
http://projects.gridaus.org.au/trac/grisu/wiki/GrisuTemplates
<?xml version="1.0" encoding="UTF-8"?>
<JobDefinition xmlns="http://schemas.ggf.org/jsdl/2005/11/jsdl">
<JobDescription>
<JobIdentification>
<JobName>cat_job</JobName>
</JobIdentification>
<Application>
<ApplicationName>cat</ApplicationName>
<POSIXApplication
xmlns="http://schemas.ggf.org/jsdl/2005/11/jsdl-posix">
<Executable>/bin/cat</Executable>
<Argument>textfile.txt</Argument>
<WorkingDirectory>path_relative_to_user_home_directory_to_where_stage_in_files_are</WorkingDirectory>
<Output>stdout.txt</Output>
<Error>stderr.txt</Error>
<Email>markus@vpac.org</Email> <!-- this is actually not in the jsdl specification -->
</POSIXApplication>
<TotalCPUTime>60</TotalCPUTime>
<TotalCPUCount>1</TotalCPUCount>
</Application>
<Resources>
<CandidateHosts>
<HostName>ng2.vpac.org</HostName>
</CandidateHosts>
<FileSystem name="userExecutionHostFs">
<MountSource>gsiftp://ngdata.vpac.org/home/grid-admin</MountSource>
<FileSystemType>normal</FileSystemType>
</FileSystem>
</Resources>
<DataStaging>
<FileName>workingDirectory/textfile.txt</FileName>
<FileSystemName>userExecutionHostFs</FileSystemName>
<Source>
<URI>gsiftp://ngdata.vpac.org/tmp/textfile.txt</URI>
</Source>
</DataStaging>
</JobDescription>
</JobDefinition>
|