Michael Potter <mega...@gmail.com> writes:

> I'm not I'm understanding what you mean by class persistance. Do you
> mean persistant over invokations of cf-agent?

Yes. The logic that defines the class is run every hour, but the
resulting class lives on for 120 minutes or until it is reset by another
run of the logic. It is somewhat difficult to explain, I'll try to
illustrate by subsequent cf-agent runs:

  10:00 : splayclass "hourly" is set, the class "myclass" is set
  10:05 : "myclass" is still defined
  10:10 : "myclass" is still defined
  10:15 : ... etc.
  ...
  11:00 : splayclass "hourly" is set, the class "myclass" is set
  11:05 : "myclass" is still defined
  11:10 : "myclass" is still defined
  11:15 : ... etc.

> Also, in your 'doesnt work' example, you need to show the classes body
> you are using to make the class 'persistant'. I suspect the reason it
> doesn't work is that definition of a scoped class (myclass) does not
> fall into the categories of promise repaired, kept etc. But that is
> just a guess...

Sorry, I was referring to the classes body in my first email:

  body classes persist(class,time)
  {
    promise_repaired => { "$(class)" };
    persist_time     => "$(time)";
    timer_policy     => "reset";
  }

There is clearly something about this that I don't understand, but I
can't put my finger on it...

Regards,
-- 
Trond H. Amundsen <t.h.amund...@usit.uio.no>
Center for Information Technology Services, University of Oslo
_______________________________________________
Help-cfengine mailing list
Help-cfengine@cfengine.org
https://cfengine.org/mailman/listinfo/help-cfengine

Reply via email to