connection_goal

March 26, 2020 Contributors

Name

connection_goal

Synopsis

#include "hooks/core/connection_goal.h"

| void **connection_goal** ( | closure, |   |
|   | dr, |   |
|   | binding_slot, |   |
|   | aq, |   |
|   | goal); |   |

void * <var class="pdparam">closure</var>;
domain_record * <var class="pdparam">dr</var>;
int <var class="pdparam">binding_slot</var>;
Skiplist * <var class="pdparam">aq</var>;
int * <var class="pdparam">goal</var>;

| int **has_core_connection_goal_hook** ( | ); |   |

| void **register_core_connection_goal_hook_first** ( | hook, |   |
|   | closure); |   |

ec_hook_core_connection_goal_func_t <var class="pdparam">hook</var>;
void *<var class="pdparam">closure</var>;

| void **register_core_connection_goal_hook_last** ( | hook, |   |
|   | closure); |   |

ec_hook_core_connection_goal_func_t <var class="pdparam">hook</var>;
void *<var class="pdparam">closure</var>;

| void **call_core_connection_goal_hook** ( | dr, |   |
|   | binding_slot, |   |
|   | aq, |   |
|   | goal); |   |

domain_record * <var class="pdparam">dr</var>;
int <var class="pdparam">binding_slot</var>;
Skiplist * <var class="pdparam">aq</var>;
int * <var class="pdparam">goal</var>;

Description

This hook allows developers to override Momentum’s internal connection allocation algorithms. dr is the domain to which an currently active message is scheduled for immediate delivery. binding_slot is the MultiVIP™ binding slot over which the message should be sent. aq is the current active queue for that domain/binding. goal points to an integer which represents the number of total desired connections.

This hook as no return and thus the last registered hook that chooses to unilaterally set *goal will override all previous goal calculations.