[v6r12] Fixes for the new pilot

Some real bugs, some more documentation, some slight code changes mostly for logging, debugging, and extensibility
I might have missed something but the pilot script must be self contained.

All the needed functions and Commands need to be included in a single file
that it is steer either via command line options or some configuration file.

With respect to this commit I agree that we should avoid double headers,
but the way to do it is no to capture the stdout and print it out at the
end. This is wrong since it will not allow debugging of a running
pilot/agent.

On the other hand I do not agree with "In the pilot using logger is not as
crucial as elsewhere". It is important to have all the timestamps, thus the
"pilot" logger should be used systematically.

Ricardo



On 1 August 2014 19:57, Andrei Tsaregorodtsev <notifications@github.com>
wrote:

> In WorkloadManagementSystem/PilotAgent/pilotCommands.py:
>
> >
> >      self.log.info( "JobAgent execution command:\n%s" % jobAgent )
> >
> >
> >      if not self.pp.dryRun:
> >        retCode, output = self.executeAndGetOutput( jobAgent, self.pp.installEnv )
> > -      print output
> > +      self.log.info( output )
>
> This was done deliberately to avoid double headers - from JobAgent and
> from the local logger. In the pilot using logger is not as crucial as
> elsewhere
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/DIRACGrid/DIRAC/pull/2026/files#r15709456>.
>



-- 
================================================================================

Ricardo Graciani Diaz

Dept. Estructura i Constituents de la Materia
Facultat de Fisica                              Tel:  +34 93 403 9183
Universitat de Barcelona                 Fax: +34 93 402 1198

Diagonal, 645
E-08028 Barcelona

================================================================================