File: Autoarchive.rst

package info (click to toggle)
ecflow 5.15.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 51,868 kB
  • sloc: cpp: 269,341; python: 22,756; sh: 3,609; perl: 770; xml: 333; f90: 204; ansic: 141; makefile: 70
file content (73 lines) | stat: -rw-r--r-- 2,769 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
ecflow.Autoarchive
//////////////////


.. py:class:: Autoarchive
   :module: ecflow

   Bases: :py:class:`~Boost.Python.instance`

Provides a way to automatically archive a suite/family which has completed or is *idle*

This is required when dealing with super large suite/families, they can be archived off, and then restored later.
This reduces the time to checkpoint and network band width.
The archived node is written to disk, as ECF_HOME/<host>.<port>.ECF_NAME.check,
where '/' is replaced with ':' in ECF_NAME.
The node can be recovered using 'autorestore', begin,re-queue and manually via ecflow_client --restore.
The archiving is never immediate. The nodes are checked one a minute, and expired autoarchive nodes are archived.
If the node is suspended or any of its parent are suspended,or previously restored then archive does not happen.

Constructor::

   Autoarchive(TimeSlot,relative,idle)
      TimeSlot     : A time
      bool relative: Relative to node state, False means archive the node at the real time specified.

      bool idle:     True includes queued,aborted and complete, False means archive after completion only

   Autoarchive(hour,minute,relative)
      int hour:      hour in 24 hrs
      int minute:    minute <= 59
      bool relative: Relative to node state. False means archive the node at the real time specified.

      bool idle:     True includes queued,aborted and complete, False means archive after completion only

   AutoArchive(days,idle)
      int days:      archive the node after 'days' elapsed 
      bool idle:     True archive if node queued,aborted and complete, False means archive after completion only


Usage:

.. code-block:: python

   attr = Autoarchive( 1,30, true )              # archive node 1 hour and 30 minutes after completion
   attr = Autoarchive( TimeSlot(0,10), true )    # archive node 10 minutes after completion
   attr = Autoarchive( TimeSlot(10,10), false )  # archive node at 10:10 after completion
   attr = Autoarchive( 3  )                      # archive node 3 days after completion
   attr = Autoarchive( 3,true  )                 # archive node 3 days after complete,queued or aborted, i.e node is idle


.. py:method:: Autoarchive.days( (Autoarchive)arg1) -> bool :
   :module: ecflow

Returns a boolean true if time was specified in days


.. py:method:: Autoarchive.idle( (Autoarchive)arg1) -> bool :
   :module: ecflow

Returns a boolean true if archiving when idle, i.e queued,aborted,complete and time elapsed


.. py:method:: Autoarchive.relative( (Autoarchive)arg1) -> bool :
   :module: ecflow

Returns a boolean where true means the time is relative


.. py:method:: Autoarchive.time( (Autoarchive)arg1) -> TimeSlot :
   :module: ecflow

returns archive time as a TimeSlot