[Xorp-cvs] XORP cvs commit: xorp/rtrmgr
Pavlin Radoslavov
pavlin@icir.org
Sat, 2 Jul 2005 02:06:07 GMT
CVSROOT: /usr/local/share/doc/apache/cvs
Module name: xorp
Changes by: pavlin@xorpc.icir.org 2005-07-02 02:06:07 UTC
XORP CVS repository
Modified files:
rtrmgr template_commands.cc template_commands.hh
Log message:
* Add new methods XrlAction::related_module() and
ProgramAction::related_module() that return the name of the module
the contains the configuration that will invoke the action.
Note that this module may be different from the module that an XRL
action may be sent to.
* Use related_module() instead of affected_module() to add XRL
and program actions to the task manager. Thus, each action will
be associated with the module where the action is defined
instead of, say, the XRL target.
This allows us to write rtrmgr templates like:
protocols {
bgp {
...
%modinfo: depends policy;
...
import {
%set: xrl "$(policy.targetname)/policy/0.1/foo
}
...
}
}
In the above example, the %set XRL will be invoked in order together
with the rest of the bgp module's XRLs instead of the policy's XRLs.
Though, obviously, to have this working the bgp module MUST depend
on the policy module.
Bug found by: Andrea Bittau
Revision Changes Path
1.53 +21 -3; commitid: 7a2b42c5f49d7ea6; xorp/rtrmgr/template_commands.cc
1.26 +5 -1; commitid: 7a2b42c5f49d7ea6; xorp/rtrmgr/template_commands.hh