On Wed, Apr 1, 2009 at 17:24,  <uma...@comcast.net> wrote:
> I am delighted to hear there is subscription mechanism!
> I apologize if I have not read through the documentation
> thoroughly. Could you please point me to the documentation
> on CIB events and the subscription mechanism?
>
> What is the protocol by which events are conveyed to
> subscribers?

diffs in the form of xml objects. eg.

<diff>
  <diff-removed>
    <cib num_updates="35">
      <status>
        <node_state id="c001n05">
          <lrm id="c001n05">
            <lrm_resources>
              <lrm_resource id="stateful-1:10">
                <lrm_rsc_op last-run="1238614603" exec-time="50"
id="stateful-1:10_monitor_15000"/>
              </lrm_resource>
              <lrm_resource id="rsc_c001n05">
                <lrm_rsc_op last-run="1238614609" exec-time="60"
id="rsc_c001n05_monitor_5000"/>
              </lrm_resource>
            </lrm_resources>
          </lrm>
        </node_state>
      </status>
   </cib>
  </diff-removed>
  <diff-added>
    <cib num_updates="36">
      <status>
        <node_state id="c001n15">
          <lrm id="c001n15">
            <lrm_resources>
              <lrm_resource id="stateful-1:9">
                <lrm_rsc_op last-run="1238614802"
last-rc-change="1238614531" exec-time="40"
id="stateful-1:9_monitor_15000"/>
              </lrm_resource>
              <lrm_resource id="rsc_c001n15">
                <lrm_rsc_op last-run="1238614803" exec-time="60"
id="rsc_c001n15_monitor_5000"/>
              </lrm_resource>
            </lrm_resources>
          </lrm>
        </node_state>
      </status>
    </cib>
  </diff-added>


>
> Is there a hello world example of how to subscribe to CIB events?

no, but it should be reasonably obvious from reading the crm_mon code.
_______________________________________________
Linux-HA mailing list
Linux-HA@lists.linux-ha.org
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems

Reply via email to