2018-08-28 14:43:46 +00:00
|
|
|
#ifndef ODYSSEY_ROUTER_CANCEL_H
|
|
|
|
#define ODYSSEY_ROUTER_CANCEL_H
|
2018-02-22 13:43:52 +00:00
|
|
|
|
|
|
|
/*
|
2018-03-12 14:03:15 +00:00
|
|
|
* Odyssey.
|
2018-02-22 13:43:52 +00:00
|
|
|
*
|
2018-04-04 13:19:58 +00:00
|
|
|
* Scalable PostgreSQL connection pooler.
|
2020-04-02 11:00:56 +00:00
|
|
|
*/
|
2018-02-22 13:43:52 +00:00
|
|
|
|
2020-11-27 18:03:42 +00:00
|
|
|
#include <kiwi.h>
|
|
|
|
|
2020-12-28 10:43:31 +00:00
|
|
|
typedef struct {
|
2020-04-02 11:00:56 +00:00
|
|
|
od_id_t id;
|
2018-12-06 14:23:15 +00:00
|
|
|
od_rule_storage_t *storage;
|
2020-04-02 11:00:56 +00:00
|
|
|
kiwi_key_t key;
|
2018-08-28 14:43:46 +00:00
|
|
|
} od_router_cancel_t;
|
2018-02-22 13:43:52 +00:00
|
|
|
|
2020-12-28 10:43:31 +00:00
|
|
|
static inline void od_router_cancel_init(od_router_cancel_t *cancel)
|
2018-02-22 13:43:52 +00:00
|
|
|
{
|
2018-12-06 14:23:15 +00:00
|
|
|
cancel->storage = NULL;
|
2018-08-28 14:43:46 +00:00
|
|
|
kiwi_key_init(&cancel->key);
|
2018-02-22 13:43:52 +00:00
|
|
|
}
|
|
|
|
|
2020-12-28 10:43:31 +00:00
|
|
|
static inline void od_router_cancel_free(od_router_cancel_t *cancel)
|
2018-02-22 13:43:52 +00:00
|
|
|
{
|
2018-12-06 14:23:15 +00:00
|
|
|
if (cancel->storage)
|
|
|
|
od_rules_storage_free(cancel->storage);
|
2018-02-22 13:43:52 +00:00
|
|
|
}
|
|
|
|
|
2018-08-28 14:43:46 +00:00
|
|
|
#endif /* ODYSSEY_ROUTER_CANCEL_H */
|