JPIS updates:
authorFrantišek Dvořák <valtri@civ.zcu.cz>
Thu, 24 Jul 2008 15:48:39 +0000 (15:48 +0000)
committerFrantišek Dvořák <valtri@civ.zcu.cz>
Thu, 24 Jul 2008 15:48:39 +0000 (15:48 +0000)
- update config file format
- check the test (with debug gsoap-plugin too)
- new attributes to config file
- gsoap 2.7.10
- memleaks

org.glite.jp.index/Makefile
org.glite.jp.index/config/glite-jpis-config.xml
org.glite.jp.index/config/glite-jpis-test-config.xml
org.glite.jp.index/examples/query-tests/run-test.sh
org.glite.jp.index/src/conf.c
org.glite.jp.ws-interface/src/ws_fault.c
org.glite.lb.state-machine/Makefile
org.glite.lb.state-machine/src/jpis_config.xsl [new file with mode: 0644]

index b812b25..38c1821 100644 (file)
@@ -144,7 +144,7 @@ soap_ops.o bones_server.o: soap_version.h
 
 soap_version.h:
        ${gsoap_bin_prefix}/soapcpp2 /dev/null
-       perl -ne '$$. == 2 && /.*([0-9])\.([0-9])\.([0-9]).*/ && printf "#define GSOAP_VERSION %d%02d%02d\n",$$1,$$2,$$3' soapH.h >$@
+       perl -ne '$$. == 2 && /.*([0-9]+)\.([0-9]+)\.([0-9]+).*/ && printf "#define GSOAP_VERSION %d%02d%02d\n",$$1,$$2,$$3' soapH.h >$@
        -rm soapC.cpp soapH.h soapStub.h soapClient.cpp soapServer.cpp soapClientLib.cpp soapServerLib.cpp
 
 db_ops.h: context.h
index fda77f7..e5ed4af 100644 (file)
 <?xml version="1.0" encoding="UTF-8"?>
-<jpelem:ServerConfiguration xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:jptype="http://glite.org/wsdl/types/jp" xmlns:jpsrv="http://glite.org/wsdl/services/jp" xmlns:jpelem="http://glite.org/wsdl/elements/jp">
-       
-       <!-- List of attributes IS want to receive from PS's -->
-       <attrs>http://egee.cesnet.cz/en/Schema/JP/System:owner</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/JP/System:jobId</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/JP/System:regtime</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:LBserver</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:user</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:parent</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:VO</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:aTag</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:rQType</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:eDuration</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:eNodes</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:eProc</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:RB</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:CE</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:host</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:UIHost</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:CPUTime</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:NProc</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatus</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatusDate</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatusReason</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:LRMSDoneStatus</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:LRMSDoneStatusReason</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:retryCount</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:additionalReason</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:jobType</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:nsubjobs</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:subjobs</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:lastStatusHistory</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:fullStatusHistory</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:JDL</attrs>
+<jpelem:ServerConfiguration
+       xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
+       xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+       xmlns:jptype="http://glite.org/wsdl/types/jp"
+       xmlns:jpsrv="http://glite.org/wsdl/services/jp"
+       xmlns:jpelem="http://glite.org/wsdl/elements/jp">
 
-       <!-- List of attributes IS will index -->
-       <indexedAttrs>http://egee.cesnet.cz/en/Schema/JP/System:owner</indexedAttrs>
-       <indexedAttrs>http://egee.cesnet.cz/en/Schema/JP/System:jobId</indexedAttrs>
+<!-- List of attributes IS want to receive from PS's -->
+       <!-- Internal attributes -->
+       <!--
+       <attrs><name>http://egee.cesnet.cz/en/Schema/JP/System:jobId</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/JP/System:owner</name></attrs>
+       -->
+       <!-- Job status -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:status</name></attrs>
+       <!-- Id of the job -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:jobId</name></attrs>
+       <!-- Job owner -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:owner</name></attrs>
+       <!-- Type of job -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:jobtype</name></attrs>
+       <!-- parent job of subjob -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:parentJob</name></attrs>
+       <!-- string used for generation of subjob IDs -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:seed</name></attrs>
+       <!-- number of subjobs -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:childrenNum</name></attrs>
+       <!-- list of subjob IDs -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:children</name></attrs>
+       <!-- summary (histogram) of children job states -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:childrenHist</name></attrs>
+       <!-- full status information of the children -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:childrenStates</name></attrs>
+       <!-- Id within Condor-G -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorId</name></attrs>
+       <!-- Globus allocated Id -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:globusId</name></attrs>
+       <!-- Id within LRMS -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:localId</name></attrs>
+       <!-- User submitted job description -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:jdl</name></attrs>
+       <!-- Full job description after matchmaking -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:matchedJdl</name></attrs>
+       <!-- ID of CE where the job is being sent -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:destination</name></attrs>
+       <!-- ClassAd passed to Condor-G for last job execution -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorJdl</name></attrs>
+       <!-- Job RSL sent to Globus -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:rsl</name></attrs>
+       <!-- Reason of being in this status, if any -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:reason</name></attrs>
+       <!-- Where the job is being processed -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:location</name></attrs>
+       <!-- Worker node where the job is executed -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:ceNode</name></attrs>
+       <!-- Network server handling the job -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:networkServer</name></attrs>
+       <!-- Subjob failed (the parent job will fail too) -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:subjobFailed</name></attrs>
+       <!-- Return code -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:doneCode</name></attrs>
+       <!-- Unix exit code -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:exitCode</name></attrs>
+       <!-- The job was resubmitted -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:resubmitted</name></attrs>
+       <!-- Cancellation request in progress -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:cancelling</name></attrs>
+       <!-- Reason of cancel -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:cancelReason</name></attrs>
+       <!-- Consumed CPU time -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:cpuTime</name></attrs>
+       <!-- List of pairs (user_tag, user_value) -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:userTags</name></attrs>
+       <!-- When entered this status -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:stateEnterTime</name></attrs>
+       <!-- Last known event of the job -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:lastUpdateTime</name></attrs>
+       <!-- When all previous states were entered -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:stateEnterTimes</name></attrs>
+       <!-- Some logged information has not arrived yet -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:expectUpdate</name></attrs>
+       <!-- Sources of the missing information -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:expectFrom</name></attrs>
+       <!-- ACL of the job -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:acl</name></attrs>
+       <!-- User payload started -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:payloadRunning</name></attrs>
+       <!-- Possible job destinations -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:possibleDestinations</name></attrs>
+       <!-- CE nodes matching to possible_destinations -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:possibleCeNodes</name></attrs>
+       <!-- Job is suspended -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:suspended</name></attrs>
+       <!-- Reason for the suspend -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:suspendReason</name></attrs>
+       <!-- Concatenated job failure reasons, possibly from deeper middleware layers -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:failureReasons</name></attrs>
+       <!-- Job reached final status and may be removed from proxy -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:removeFromProxy</name></attrs>
+       <!-- Hostname or address of UI used to submit the job -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:uiHost</name></attrs>
+       <!-- FQAN used to register the job -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:userFqans</name></attrs>
+       <!-- Job state which would probably return PBS qstat (Q/R/C/....) -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:pbsState</name></attrs>
+       <!-- Name of queue in which is job queued -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:pbsQueue</name></attrs>
+       <!-- Owner of job -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:pbsOwner</name></attrs>
+       <!-- Name of job -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:pbsName</name></attrs>
+       <!-- Glued reasons/errors leading to pending events -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:pbsReason</name></attrs>
+       <!-- Name of pbs scheduler -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:pbsScheduler</name></attrs>
+       <!-- Hostname of node where job is running -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:pbsDestHost</name></attrs>
+       <!-- PID of running job -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:pbsPid</name></attrs>
+       <!-- Glued resource usage -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:pbsResourceUsage</name></attrs>
+       <!-- Job exit status -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:pbsExitStatus</name></attrs>
+       <!-- Glued error descriptions from error events -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:pbsErrorDesc</name></attrs>
+       <!-- Condor job status  -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorStatus</name></attrs>
+       <!-- Condor job Universe (in job ClassAds) -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorUniverse</name></attrs>
+       <!-- Job owner -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorOwner</name></attrs>
+       <!-- Job preempting -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorPreempting</name></attrs>
+       <!-- PID of Shadow -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorShadowPid</name></attrs>
+       <!-- Condor shadow exit status (see h/exit.h) -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorShadowExitStatus</name></attrs>
+       <!-- PID of Starter -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorStarterPid</name></attrs>
+       <!-- Condor starter exit status -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorStarterExitStatus</name></attrs>
+       <!-- PID of running job -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorJobPid</name></attrs>
+       <!-- Job exit status -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorJobExitStatus</name></attrs>
+       <!-- Hostname of node where job is running -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorDestHost</name></attrs>
+       <!-- Glued reasons/errors leading to pending events -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorReason</name></attrs>
+       <!-- Glued error descriptions from error events -->
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:condorErrorDesc</name></attrs>
+
+
+<!-- List of attributes IS will index -->
+       <!-- default filter -->
+       <!--<indexedAttrs>http://egee.cesnet.cz/en/Schema/JP/System:owner</indexedAttrs>-->
+       <!-- internal attribute (index replacement) -->
+       <!--<indexedAttrs>http://egee.cesnet.cz/en/Schema/JP/System:jobId</indexedAttrs>-->
        <indexedAttrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:user</indexedAttrs>
        <indexedAttrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:CE</indexedAttrs>
        <indexedAttrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:VO</indexedAttrs>
        <indexedAttrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatus</indexedAttrs>
 
-       <!-- List of type plugins -->
+<!-- List of type plugins -->
        <plugins></plugins>
 
-       <!-- List of feeds IS wants to receive from PS's-->
-       <feeds>
-               <primaryServer>https://localhost:8901</primaryServer>
-               <!-- List of conditions triggering attrs sending -->
-               <condition>
-                       <attr>http://egee.cesnet.cz/en/Schema/JP/System:owner</attr>
-                       <op>EQUAL</op>
-                       <value>
-                               <string>/DC=cz/DC=cesnet-ca/O=Masaryk University/CN=Milos Mulac</string>
-                       </value>
-               </condition>
-               <history>1</history>
-               <continuous>1</continuous>
-       </feeds>
+<!-- List of feeds IS wants to receive from PS's-->
+       <!-- no filter, historic batch and incremental changes -->
+        <feeds>
+               <!-- replace this by Job Provenance Primare Storage endpoint -->
+                <primaryServer>https://localhost:8901</primaryServer>
+                <!-- List of conditions triggering attrs sending -->
+                <condition>
+                        <attr>http://egee.cesnet.cz/en/Schema/JP/System:regtime</attr>
+                        <op>GREATER</op>
+                        <value>
+                                <string>0</string>
+                        </value>
+                </condition>
+                <history>1</history>
+                <continuous>1</continuous>
+        </feeds>
 </jpelem:ServerConfiguration>
index b81b342..c860037 100644 (file)
@@ -2,25 +2,24 @@
 <jpelem:ServerConfiguration xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:jptype="http://glite.org/wsdl/types/jp" xmlns:jpsrv="http://glite.org/wsdl/services/jp" xmlns:jpelem="http://glite.org/wsdl/elements/jp">
        
        <!-- List of attributes IS want to receive from PS's -->
-       <attrs>http://egee.cesnet.cz/en/Schema/JP/System:owner</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/JP/System:jobId</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/JP/System:regtime</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:user</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:aTag</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:eNodes</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:RB</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:CE</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:UIHost</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:CPUTime</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:NProc</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatus</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatusDate</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:retryCount</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:jobType</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:nsubjobs</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:lastStatusHistory</attrs>
-       <attrs>http://egee.cesnet.cz/en/Schema/LB/Attributes:fullStatusHistory</attrs>
-
+       <attrs><name>http://egee.cesnet.cz/en/Schema/JP/System:owner</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/JP/System:jobId</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/JP/System:regtime</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:user</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:aTag</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:eNodes</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:RB</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:CE</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:UIHost</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:CPUTime</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:NProc</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatus</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatusDate</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:retryCount</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:jobType</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:nsubjobs</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:lastStatusHistory</name></attrs>
+       <attrs><name>http://egee.cesnet.cz/en/Schema/LB/Attributes:fullStatusHistory</name></attrs>
 
        <!-- List of attributes IS will index -->
        <indexedAttrs>http://egee.cesnet.cz/en/Schema/JP/System:owner</indexedAttrs>
index 9c01ad0..e15d1c4 100755 (executable)
@@ -176,7 +176,7 @@ run_test_query() {
        echo -n "Q"
        X509_USER_KEY=${X509_USER_KEY} X509_USER_CERT=${X509_USER_CERT} \
        $GLITE_LOCATION/examples/glite-jpis-client -f hr -q $1 \
-                -i http://localhost:$GLITE_JPIS_TEST_PORT > /tmp/result 2>&1
+                -i http://localhost:$GLITE_JPIS_TEST_PORT 2>&1 | grep -v '^GSLITE_GSPLUGIN: ' > /tmp/result
        echo -n "R "
        DIFF=`diff -b -B --ignore-matching-lines="query: using JPIS" $2 /tmp/result`
        if [ -z "$DIFF" -a "$?" -eq "0" ] ; then
index 1506faf..e52b41f 100644 (file)
@@ -116,6 +116,7 @@ int glite_jp_get_conf(int argc, char **argv, glite_jp_is_conf **configuration)
        if (!conf_file) {
                fprintf(stderr,"JP IS configuration file must be specified! "\
                        "Exiting.\n");
+               free(conf);
                return 1;
        }
        else {
@@ -192,6 +193,7 @@ static int read_conf(glite_jp_is_conf *conf, char *conf_file)
        if (!soap_get__jpelem__ServerConfigurationResponse(&soap, &out, "ServerConfiguration", NULL)) {
                 soap_end_recv(&soap);
                 soap_end(&soap);
+               soap_print_fault(&soap, stderr);
                 return EINVAL;
         }
        soap_end_recv(&soap);
@@ -205,6 +207,10 @@ static int read_conf(glite_jp_is_conf *conf, char *conf_file)
                for (i=0; i < out.__sizeattrs; i++) {
                        struct jptype__attrType *attr;
                        attr = GLITE_SECURITY_GSOAP_LIST_GET(out.attrs, i);
+                       if (!attr->name) {
+                               fprintf(stderr, "missing name of %d attribute in %s\n", i + 1, conf_file);
+                               goto err;
+                       }
                        conf->attrs[i] = strdup(attr->name);
                        if (attr->multival == jptype__yesNo__YES){
                                conf->multival_attrs = realloc(conf->multival_attrs, (mva+2)*sizeof(*conf->multival_attrs));
@@ -240,7 +246,7 @@ static int read_conf(glite_jp_is_conf *conf, char *conf_file)
                        conf->feeds[i]->PS_URL=strdup(feed->primaryServer);
 
                        if (glite_jpis_SoapToPrimaryQueryConds(feed->__sizecondition,
-                               feed->condition, &conf->feeds[i]->query)) return EINVAL;
+                               feed->condition, &conf->feeds[i]->query)) goto err;
                        
                        conf->feeds[i]->history = feed->history;
                        conf->feeds[i]->continuous = feed->continuous;
@@ -253,6 +259,13 @@ static int read_conf(glite_jp_is_conf *conf, char *conf_file)
        soap_done(&soap);
 
        return 0;
+
+err:
+       glite_jp_free_conf(conf);
+       soap_destroy(&soap);
+       soap_end(&soap);
+       soap_done(&soap);
+       return EINVAL;
 }
 
 #if 0
index 4cb07d9..af43511 100644 (file)
@@ -73,7 +73,7 @@ static int clientGetFault(struct soap *soap, int err, const char **reason, struc
                }
                // client is based on gSoap 2.7.9b
                assert(detail->__type == GFNUM);
-#if GSOAP_VERSIO >= 20709
+#if GSOAP_VERSION >= 20709
                *f = (struct jptype__genericFault *)detail->fault;
 #elif GSOAP_VERSION >= 20700
                *f = ((struct _genericFault *)detail->fault)->jpelem__genericFault;
index c37df71..cac5f1c 100644 (file)
@@ -113,3 +113,5 @@ job_attrs.h: lb-job-attrs.xsd job_attrs.xsl
 job_attrs2.h: lb-job-attrs2.xsd job_attrs2.xsl
        ${XSLTPROC} ../src/job_attrs2.xsl $< >$@
 
+jpis_config.xml: lb-job-attrs2.xsd jpis_config.xsl
+       ${XSLTPROC} ../src/jpis_config.xsl lb-job-attrs2.xsd >$@
diff --git a/org.glite.lb.state-machine/src/jpis_config.xsl b/org.glite.lb.state-machine/src/jpis_config.xsl
new file mode 100644 (file)
index 0000000..b9adaa3
--- /dev/null
@@ -0,0 +1,67 @@
+<?xml version="1.0"?>
+
+<xsl:stylesheet version="1.0"
+       xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+       xmlns:xs="http://www.w3.org/2001/XMLSchema"
+>
+
+<xsl:output method="text"/>
+
+<xsl:template match="xs:schema">&lt;?xml version="1.0" encoding="UTF-8"?&gt;
+
+&lt;!-- generated using org.glite.lb.state-machine module --&gt;
+
+&lt;jpelem:ServerConfiguration
+       xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
+       xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+       xmlns:jptype="http://glite.org/wsdl/types/jp"
+       xmlns:jpsrv="http://glite.org/wsdl/services/jp"
+       xmlns:jpelem="http://glite.org/wsdl/elements/jp"&gt;
+
+&lt;!-- List of attributes IS want to receive from PS's --&gt;
+       &lt;!-- Internal attributes --&gt;
+       &lt;!--
+       &lt;attrs&gt;&lt;name&gt;http://egee.cesnet.cz/en/Schema/JP/System:jobId&lt;/name&gt;&lt;/attrs&gt;
+       &lt;attrs&gt;&lt;name&gt;http://egee.cesnet.cz/en/Schema/JP/System:owner&lt;/name&gt;&lt;/attrs&gt;
+       --&gt;
+<xsl:apply-templates select="xs:element" mode="define"/>
+
+&lt;!-- List of attributes IS will index --&gt;
+       &lt;!-- default filter --&gt;
+       &lt;!--&lt;indexedAttrs&gt;http://egee.cesnet.cz/en/Schema/JP/System:owner&lt;/indexedAttrs&gt;--&gt;
+       &lt;!-- internal attribute (index replacement) --&gt;
+       &lt;!--&lt;indexedAttrs&gt;http://egee.cesnet.cz/en/Schema/JP/System:jobId&lt;/indexedAttrs&gt;--&gt;
+       &lt;indexedAttrs&gt;http://egee.cesnet.cz/en/Schema/LB/Attributes:user&lt;/indexedAttrs&gt;
+       &lt;indexedAttrs&gt;http://egee.cesnet.cz/en/Schema/LB/Attributes:CE&lt;/indexedAttrs&gt;
+       &lt;indexedAttrs&gt;http://egee.cesnet.cz/en/Schema/LB/Attributes:VO&lt;/indexedAttrs&gt;
+       &lt;indexedAttrs&gt;http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatus&lt;/indexedAttrs&gt;
+
+&lt;!-- List of type plugins --&gt;
+       &lt;plugins&gt;&lt;/plugins&gt;
+
+&lt;!-- List of feeds IS wants to receive from PS's--&gt;
+       &lt;!-- no filter, historic batch and incremental changes --&gt;
+        &lt;feeds&gt;
+               &lt;!-- replace this by Job Provenance Primare Storage endpoint --&gt;
+                &lt;primaryServer&gt;https://localhost:8901&lt;/primaryServer&gt;
+                &lt;!-- List of conditions triggering attrs sending --&gt;
+                &lt;condition&gt;
+                        &lt;attr&gt;http://egee.cesnet.cz/en/Schema/JP/System:regtime&lt;/attr&gt;
+                        &lt;op&gt;GREATER&lt;/op&gt;
+                        &lt;value&gt;
+                                &lt;string&gt;0&lt;/string&gt;
+                        &lt;/value&gt;
+                &lt;/condition&gt;
+                &lt;history&gt;1&lt;/history&gt;
+                &lt;continuous&gt;1&lt;/continuous&gt;
+        &lt;/feeds&gt;
+&lt;/jpelem:ServerConfiguration&gt;
+</xsl:template>
+
+<xsl:template match="xs:element" mode="define">        &lt;!-- <xsl:value-of select="xs:documentation/text()"/> --&gt;
+       &lt;attrs&gt;&lt;name&gt;http://egee.cesnet.cz/en/Schema/LB/Attributes:<xsl:value-of select="@name"/>&lt;/name&gt;&lt;/attrs&gt;
+</xsl:template>
+
+</xsl:stylesheet>