English Français

Documentation / Developer's manual

Available modules

Calibration,  DataServer,  Launcher,  MetaModelOptim,  Modeler,  Optimizer,  ReLauncher,  Reliability,  ReOptimizer,  Sampler,  Sensitivity,  UncertModeler,  XmlProblem,   Uranie / Launcher: TSlurmCluster.h Source File
Uranie / Launcher v4.9.0
/* @license-end */
TSlurmCluster.h
Go to the documentation of this file.
1
2// Copyright (C) 2013-2024 CEA/DES
3//
4// This program is free software: you can redistribute it and/or modify
5// it under the terms of the GNU Lesser General Public License as published
6// by the Free Software Foundation, either version 3 of the License, or any
7// later version.
8//
9// This program is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU Lesser General Public License for more details.
13//
14// You should have received a copy of the GNU Lesser General Public License
15// along with this program. If not, see <http://www.gnu.org/licenses/>.
18// $Id$
19// $Author$
20// $Date$
21// $Revision$
22// $State$
24
41#ifndef TSLURMCLUSTER_H
42#define TSLURMCLUSTER_H
43
44#include <iostream>
45#include <sstream>
46
47using std::cout;
48using std::endl;
49using std::istringstream;
50using std::string;
51#define BUF_SIZE 128
52//ROOT
53#include "Rtypes.h"
54
55// Uranie
56#include "TCluster.h"
57
58namespace URANIE
59{
60namespace Launcher
61{
62
64{
65private:
66 static const char *nodeList();
67
68public:
69
70 static bool eligible();
71
72 //---------------------------------------------
76
78#ifdef WITH_LIBSSH
79 TSlurmCluster(URANIE::DataServer::TDataServer *tds, TCode *code);
80 TSlurmCluster(TCode *code);
81#endif
82
84 virtual ~TSlurmCluster();
86
87 //---------------------------------------------
91
92 virtual void init();
93 virtual void getCommandPrefix(char *, char *);
95
96 //---------------------------------------------
100 void setLog()
101 {
102 _blog = kTRUE;
103 }
104 void unsetLog()
105 {
106 _blog = kFALSE;
107 }
109 {
110 _blog = _blog ? kFALSE : kTRUE;
111 }
112 Bool_t getLog()
113 {
114 return _blog;
115 }
116 virtual void printLog(Option_t *option = "") ;
118
121#ifdef WITH_LIBSSH
123
126 void setCluster(TString cluster_name);
127
128 void selectHeader(TString SkeletonHeaderName="header_skeleton.in",TString localHeaderFolderPath=gSystem->pwd() );
129 void generateHeader(Option_t *option = "");
130 void generateHeaderSplit(Option_t *option = "");
131 TString getJobStatusCommand(TString JobIDs);
132 TString checkJobStatus(TString JobId, TString Command);
133
134#endif
135
136 ClassDef(URANIE::Launcher::TSlurmCluster , ID_LAUNCHER)
137
138};
139
140} // Fin du namespace Launcher
141} // Fin du namespace URANIE
142#endif
Interface of the class URANIE::Launcher::TCluster.
Description of the class TCluster.
Definition TCluster.h:71
Bool_t _blog
Boolean to edit the log.
Definition TCluster.h:73
Description of the class TCode.
Definition TCode.h:46
Definition TSlurmCluster.h:64
virtual void printLog(Option_t *option="")
static const char * nodeList()
virtual void getCommandPrefix(char *, char *)
void unsetLog()
Definition TSlurmCluster.h:104
virtual ~TSlurmCluster()
Default destructor.
void setLog()
Definition TSlurmCluster.h:100
TSlurmCluster()
Default constructor.
void changeLog()
Definition TSlurmCluster.h:108
Bool_t getLog()
Definition TSlurmCluster.h:112
virtual void init()
Construct and return the list of nodes.
Definition TCluster.h:67