Preferences framework

Add preferences for HPC/Batch scheduler
Add slurm and LSF support
Add batch job monitor
Support launcher specific user settings
Use internal timer, not global view timer
Add some more options to batch monitor
Improve naming
Add tests for job lists
This commit is contained in:
Jon Jenssen authored and jonjenssen committed 2026-10-19 12:09:52 +02:00
1 parent 8dc1d56bd3
commit d9d7507bcd
61 files changed
+2735 -165

No files matched your search

@@ -0,0 +1,58 @@
/////////////////////////////////////////////////////////////////////////////////
//
// Copyright (C) 2026 Equinor ASA
//
// ResInsight is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// ResInsight is distributed in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or
// FITNESS FOR A PARTICULAR PURPOSE.
//
// See the GNU General Public License at <http://www.gnu.org/licenses/gpl.html>
// for more details.
//
/////////////////////////////////////////////////////////////////////////////////
#pragma once
#include "RiaHpcDefines.h"
#include "cafPdmField.h"
#include "cafPdmObject.h"
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
class RiaPreferencesBatch : public caf::PdmObject
{
CAF_PDM_HEADER_INIT;
public:
RiaPreferencesBatch();
static RiaPreferencesBatch* current();
void appendItems( caf::PdmUiOrdering& uiOrdering );
size_t maxParallelJobs() const;
RiaDefines::BatchSchedulerType batchScheduler() const;
QString queueName() const;
QString batchSchedulerOptions() const;
bool exclusiveJob() const;
static QString selectQueue( RiaDefines::BatchSchedulerType scheduler, QString currentQueue );
protected:
void defineEditorAttribute( const caf::PdmFieldHandle* field, QString uiConfigName, caf::PdmUiEditorAttribute* attribute );
private:
caf::PdmField<size_t> m_maxParallelJobs;
caf::PdmField<caf::AppEnum<RiaDefines::BatchSchedulerType>> m_batchScheduler;
caf::PdmField<QString> m_queueName;
caf::PdmField<QString> m_additionalLsfOptions;
caf::PdmField<QString> m_additionalSlurmOptions;
caf::PdmField<bool> m_exclusive;
};