|
|
Helper class for helping with Fti transactions via an Xrl interface.
The class provides error messages suitable for Xrl return values and does some extra checking not in the FtiTransactionManager class.
XrlFtiTransactionManager (EventLoop& e,
FtiConfig& ftic,
XrlRouter* xrl_router,
uint32_t max_ops = 200)
| XrlFtiTransactionManager |
Constructor
Parameters:
e | the EventLoop. |
ftic | the ForwardingTableInterface configuration object. |
max_ops | the maximum number of operations pending. |
~XrlFtiTransactionManager ()
| ~XrlFtiTransactionManager |
XrlCmdError start_transaction (uint32_t& tid)
| start_transaction |
Start a Fti transaction.
Parameters:
tid | the return-by-reference transaction ID. |
Returns: the XRL command error.
XrlCmdError commit_transaction (uint32_t tid)
| commit_transaction |
Commit a Fti transaction.
Parameters:
tid | the ID of the transaction to commit. |
Returns: the XRL command error.
XrlCmdError abort_transaction (uint32_t tid)
| abort_transaction |
Abort a Fti transaction.
Parameters:
tid | the ID of the transaction to abort. |
Returns: the XRL command error.
XrlCmdError add (uint32_t tid, const FtiTransactionManager::Operation& op)
| add |
Add a Fti operation.
Parameters:
tid | the transaction ID. |
op | the operation to add. |
Returns: the XRL command error.
FtiConfig& ftic ()
| ftic |
Get the FtiConfig entry.
Returns: a reference to the corresponding FtiConfig entry.
See also: FtiConfig.
void process_fib_changes (const list<Fte4>& fte_list)
| process_fib_changes |
Process a list of IPv4 FIB route changes.
The FIB route changes come from the underlying system.
Parameters:
fte_list | the list of Fte entries to add or delete. |
Reimplemented from FibTableObserverBase.
void process_fib_changes (const list<Fte6>& fte_list)
| process_fib_changes |
Process a list of IPv6 FIB route changes.
The FIB route changes come from the underlying system.
Parameters:
fte_list | the list of Fte entries to add or delete. |
Reimplemented from FibTableObserverBase.
XrlCmdError add_fib_client4 (const string& client_target_name,
const bool send_updates,
const bool send_resolves)
| add_fib_client4 |
Add an IPv4 FIB client.
Parameters:
client_target_name | the target name of the client to add. |
send_updates | whether updates should be sent. |
send_resolves | whether resolve requests should be sent. |
Returns: the XRL command error.
XrlCmdError add_fib_client6 (const string& client_target_name,
const bool send_updates,
const bool send_resolves)
| add_fib_client6 |
Add an IPv6 FIB client.
Parameters:
client_target_name | the target name of the client to add. |
send_updates | whether updates should be sent. |
send_resolves | whether resolve requests should be sent. |
Returns: the XRL command error.
XrlCmdError delete_fib_client4 (const string& client_target_name)
| delete_fib_client4 |
Delete an IPv4 FIB client.
Parameters:
client_target_name | the target name of the client to delete. |
Returns: the XRL command error.
XrlCmdError delete_fib_client6 (const string& client_target_name)
| delete_fib_client6 |
Delete an IPv6 FIB client.
Parameters:
client_target_name | the target name of the client to delete. |
Returns: the XRL command error.
int send_fib_client_add_route (const string& target_name,
const Fte4& fte)
| send_fib_client_add_route |
Send an XRL to a FIB client to add an IPv4 route.
Parameters:
target_name | the target name of the FIB client. |
fte | the Fte with the route information to add. |
Returns: XORP_OK on success, otherwise XORP_ERROR.
See also: Fte4.
int send_fib_client_add_route (const string& target_name,
const Fte6& fte)
| send_fib_client_add_route |
Send an XRL to a FIB client to add an IPv6 route.
Parameters:
target_name | the target name of the FIB client. |
fte | the Fte with the route information to add. |
Returns: XORP_OK on success, otherwise XORP_ERROR.
See also: Fte6.
int send_fib_client_delete_route (const string& target_name,
const Fte4& fte)
| send_fib_client_delete_route |
Send an XRL to a FIB client to delete an IPv4 route.
Parameters:
target_name | the target name of the FIB client. |
fte | the Fte with the route information to delete. |
Returns: XORP_OK on success, otherwise XORP_ERROR.
See also: Fte4.
int send_fib_client_delete_route (const string& target_name,
const Fte6& fte)
| send_fib_client_delete_route |
Send an XRL to a FIB client to delete an IPv6 route.
Parameters:
target_name | the target name of the FIB client. |
fte | the Fte with the route information to delete. |
Returns: XORP_OK on success, otherwise XORP_ERROR.
See also: Fte6.
int send_fib_client_resolve_route (const string& target_name,
const Fte4& fte)
| send_fib_client_resolve_route |
Send an XRL to a FIB client to inform it of an IPv4 route miss.
Parameters:
target_name | the target name of the FIB client. |
fte | the Fte with the destination to resolve. |
Returns: XORP_OK on success, otherwise XORP_ERROR.
See also: Fte4.
int send_fib_client_resolve_route (const string& target_name,
const Fte6& fte)
| send_fib_client_resolve_route |
Send an XRL to a FIB client to inform it of an IPv6 route miss.
Parameters:
target_name | the target name of the FIB client. |
fte | the Fte with the destination to resolve. |
Returns: XORP_OK on success, otherwise XORP_ERROR.
See also: Fte6.
FtiTransactionManager _ftm | _ftm |
[protected]
uint32_t _max_ops | _max_ops |
[protected]