Skip to content

Commit

Permalink
IOSS: heartbeat - add HEARTBEAT_FLUSH_INTERVAL property, document 0 w…
Browse files Browse the repository at this point in the history
…ill flush every step
  • Loading branch information
gdsjaar committed Apr 24, 2024
1 parent 4929ff4 commit 051d961
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
3 changes: 2 additions & 1 deletion packages/seacas/libraries/ioss/src/Ioss_Doxygen.h
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,8 @@ file. Then, the first file will be reopened and steps 0.7, 0.8, and
Property | Value | Description
-----------------------|:------:|-----------------------------------------------------------
FILE_FORMAT | [default], spyhis, csv, ts_csv, text, ts_text | predefined formats for heartbeat output. The ones starting with `ts_` output timestamps.
FLUSH_INTERVAL | int | Minimum time interval between flushing heartbeat data to disk. Default is 10 seconds
FLUSH_INTERVAL | int | Minimum time interval between flushing heartbeat data to disk. Default is 10 seconds. Set to 0 to flush every step (bad performance)
HEARTBEAT_FLUSH_INTERVAL | int | Minimum time interval between flushing heartbeat data to disk. Default is 10 seconds (Same as FLUSH_INTERVAL, but doesn't affect other database types)
TIME_STAMP_FORMAT | [%H:%M:%S] | Format used to format time stamp. See strftime man page
SHOW_TIME_STAMP | on/off | Should the output lines be preceded by the timestamp
FIELD_SEPARATOR | [, ] | separator to be used between output fields.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright(C) 1999-2023 National Technology & Engineering Solutions
// Copyright(C) 1999-2024 National Technology & Engineering Solutions
// of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with
// NTESS, the U.S. Government retains certain rights in this software.
//
Expand Down Expand Up @@ -209,6 +209,10 @@ namespace Iohb {
new_this->flushInterval_ = properties.get("FLUSH_INTERVAL").get_int();
}

if (properties.exists("HEARTBEAT_FLUSH_INTERVAL")) {
new_this->flushInterval_ = properties.get("HEARTBEAT_FLUSH_INTERVAL").get_int();
}

if (properties.exists("TIME_STAMP_FORMAT")) {
new_this->tsFormat = properties.get("TIME_STAMP_FORMAT").get_string();
}
Expand Down Expand Up @@ -332,6 +336,7 @@ namespace Iohb {
// Flush the buffer to disk...
// flush if there is more than 'flushInterval_' seconds since the last flush to avoid
// the flush eating up cpu time for small fast jobs...
// If want a flush every step for some reason, set `flushInterval_` to 0.0.

// This code is derived from code in finalize_write() in Ioex_DatabaseIO.C
// See other comments there...
Expand Down

0 comments on commit 051d961

Please sign in to comment.