mirror of
https://github.com/ElementsProject/lightning.git
synced 2024-12-27 09:04:40 +01:00
7bbfef5054
We were waiting too long for the reconnect to happen (60s default), which caused this test to timeout. When testing, let's speed up the reconnect. L2 tried to reconnect but didn't have connection information in its gossip -- is there a way to ask/save connection data from a node you're making a channel with that doesn't rely on their node_announcement?
33 lines
1.0 KiB
C
33 lines
1.0 KiB
C
#ifndef LIGHTNING_LIGHTNINGD_CONNECT_CONTROL_H
|
|
#define LIGHTNING_LIGHTNINGD_CONNECT_CONTROL_H
|
|
#include "config.h"
|
|
#include <ccan/short_types/short_types.h>
|
|
#include <ccan/tal/tal.h>
|
|
#include <common/utils.h>
|
|
|
|
struct lightningd;
|
|
struct peer;
|
|
struct pubkey;
|
|
struct wireaddr_internal;
|
|
|
|
/* Speedy reconnect timeout! */
|
|
#define DEV_FAST_RECONNECT(dev_fast_reconnect_flag, fast, normal) \
|
|
IFDEV((dev_fast_reconnect_flag) ? (fast) : (normal), (normal))
|
|
|
|
/* Returns fd for gossipd to talk to connectd */
|
|
int connectd_init(struct lightningd *ld);
|
|
void connectd_activate(struct lightningd *ld);
|
|
|
|
void try_reconnect(const tal_t *ctx,
|
|
struct peer *peer,
|
|
u32 seconds_delay,
|
|
const struct wireaddr_internal *addrhint);
|
|
void connect_succeeded(struct lightningd *ld, const struct peer *peer,
|
|
bool incoming,
|
|
const struct wireaddr_internal *addr);
|
|
void connect_failed_disconnect(struct lightningd *ld,
|
|
const struct node_id *id,
|
|
const struct wireaddr_internal *addr);
|
|
|
|
#endif /* LIGHTNING_LIGHTNINGD_CONNECT_CONTROL_H */
|