/** * @file AAFRailway.C * @author Christian Holm Christensen * @date Tue Oct 16 19:02:14 2012 * * @brief AAF analysis helper * * @ingroup pwglf_forward_trains_helper * */ #ifndef AAFHELPER_C #define AAFHELPER_C #include "ProofRailway.C" #ifndef __CINT__ # include "AvailableSoftware.C" # include # include # include # include #else class TUrl; class AliAnalysisAlien; #endif // =================================================================== /** * Handle analysis on an Alice Analysis Facility (AAF) * * This helper is triggered by a URL of the form * * @code * proof://[@][:]/[?][#] * @endcode * where <host@&t; is a known AAF (e.g., alice-caf.cern.ch) *
*
<user>
*
Optional user name
*
<host>
*
PROOF cluster master host
*
<port>
*
Optional PROOF cluster port on master host
*
<dsname>
*
Data set name
*
<treename>
*
Optional tree name in data set, often esdTree or * aodTree
*
<options>
*
List of options separated by an & *
*
dsname[=<output dataset>]
*
Register tree output (e.g., AOD) as a new data set on the * PROOF cluster. If <output dataset> is not specified, take * the name of the train.
*
storage=<url>
*
Specify a non-default storage location for special output * (e.g., AOD trees). <url> should be a valid XRootd * server URI accessible to the slaves - e.g., * root://lxplus.cern.ch:10930//tmp.
*
mode=[default,rec,sim,train,custom]
*
Set the AliROOT mode. If not specified default * is assumed. See also CreateAliROOTPar
*
par
*
Use par files
*
*
*
* * Note, this helper does not use the AliAnalysisAlien plugin * * @ingroup pwglf_forward_trains_helper */ struct AAFRailway : public ProofRailway { /** * Constructor * * @param url Url * @param verbose Verbosity */ AAFRailway(const TUrl& url, Int_t verbose) : ProofRailway(url, verbose) { fOptions.Add("aliroot", "VERSION", "AliROOT version", "last"); fOptions.Add("root", "VERISON", "ROOT version", "last"); fOptions.Add("nocache", "Disable tree cache"); } virtual ~AAFRailway() {} /** * Get the name of the AliROOT par file to use * * @return String */ virtual const char* AliROOTParName() const { return Form("VO_ALICE@AliRoot::%s", fOptions.Get("aliroot").Data()); } virtual Bool_t CreateAliROOTPar() { return true; } /** * Set-up done before task set-ups. Overload ProofRailway::PreSetup * to specify the ROOT version using TProofMgr::SetROOTVersion * * @return true on success */ virtual Bool_t PreSetup() { TString aliroot("last"); TString root("last"); if (fOptions.Has("aliroot")) aliroot = fOptions.Get("aliroot"); if (fOptions.Has("root")) root = fOptions.Get("root"); AvailableSoftware::Check(aliroot, root); fOptions.Set("aliroot", aliroot); fOptions.Set("root", root); fBasePars = false; // Set this before we try to access the cluster gEnv->SetValue("XSec.GSI.DelegProxy", "2"); TProof::Mgr(fUrl.GetHost()) ->SetROOTVersion(Form("VO_ALICE@ROOT::%s", root.Data())); if (!ProofRailway::PreSetup()) return false; if (fOptions.Has("nocache")) gProof->SetParameter("PROOF_UseTreeCache", 0); return true; } /** * @return URI help string */ virtual const Char_t* UrlHelp() const { return "proof:///?[&][#]"; } /** * @return short description */ virtual const char* Desc() const { return "AAF"; } }; #endif // // EOF //