Return even partial results for job queries. Do not get confused by failure on last...
authorZdeněk Šustr <sustr4@cesnet.cz>
Wed, 5 Sep 2012 14:02:39 +0000 (14:02 +0000)
committerZdeněk Šustr <sustr4@cesnet.cz>
Wed, 5 Sep 2012 14:02:39 +0000 (14:02 +0000)
org.glite.lb.server/src/query.c

index 8e3f7b7..17768f6 100644 (file)
@@ -680,6 +680,11 @@ limit_cycle_cleanup:
                        else edg_wll_SetError(ctx, ENOENT, "no matching jobs found");
                }
        }
+       else {
+               // There was permission problem but there were still some results
+               glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG, "Results were returned for query, but also error code %d. Resetting.", edg_wll_Error(ctx,NULL,NULL));
+               if (edg_wll_Error(ctx,NULL,NULL) == EPERM) edg_wll_ResetError(ctx);
+       }
 
 cleanup:
        // finish