Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gossip cleanups #3044

Merged
merged 9 commits into from Sep 12, 2019

Conversation

@rustyrussell
Copy link
Contributor

commented Sep 10, 2019

Various gossip-related cleanups I had lying around and which I needed for my next patches.

We overrode this with travis, but it's not a travis issue.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
@rustyrussell rustyrussell added the gossip label Sep 10, 2019
@rustyrussell rustyrussell added this to the 0.7.3 milestone Sep 10, 2019
@rustyrussell rustyrussell requested a review from niftynei Sep 10, 2019
@rustyrussell rustyrussell requested a review from cdecker as a code owner Sep 10, 2019
@rustyrussell rustyrussell added this to To Do in Gossip: sip, don't gulp. via automation Sep 10, 2019
Gossip: sip, don't gulp. automation moved this from To Do to Working... Sep 11, 2019
@@ -711,7 +711,7 @@ bool gossip_store_load(struct routing_state *rstate, struct gossip_store *gs)
goto corrupt;

/* If last timestamp is within 24 hours, say we're OK. */
contents_ok = (last_timestamp >= time_now().ts.tv_sec - 24*3600);
contents_ok = (last_timestamp >= gossip_time_now(rstate).ts.tv_sec - 24*3600);

This comment has been minimized.

Copy link
@niftynei

niftynei Sep 11, 2019

Collaborator

does this belong with c5ab892?

*
* Usefully, you can refer to DEVELOPER-only fields here. */
#if DEVELOPER
/* Makes ure that nondev is evaluated, and valid */

This comment has been minimized.

Copy link
@niftynei

niftynei Sep 11, 2019

Collaborator

ure -> sure

* for the entire stream.
*/
unsigned long compressed_len = tal_bytelen(data)
+ 6 + 5*(tal_bytelen(data) + 16384)/16384;

This comment has been minimized.

Copy link
@niftynei

niftynei Sep 11, 2019

Collaborator

🆒

@niftynei

This comment has been minimized.

Copy link
Collaborator

commented Sep 11, 2019

ack e5b5d2b

We've been slack, but it's going to be important for testing
ratelimiting.  And it currently has a minor memory leak.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
In particular, the timestamp might be wrong once we start checking that.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
There are some more #if DEVELOPER one-liners coming, this makes them
clear, but still lets them stand out.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
For memory-usage reasons, struct chan doesn't use a tal destructor, in
favor of us calling free_chan in the right places.

In DEVELOPER mode, we should check that is the case.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
In particular, it does zlib.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
@rustyrussell rustyrussell force-pushed the rustyrussell:gossip-cleanups branch from 719bac7 to 9989154 Sep 12, 2019
@rustyrussell rustyrussell merged commit f4e7ed1 into ElementsProject:master Sep 12, 2019
2 of 3 checks passed
2 of 3 checks passed
ackbot Need at least 1 ACKs
bitcoin-bot/fixups PR does not contain unsquashed fixups
continuous-integration/travis-ci/pr The Travis CI build passed
Details
Gossip: sip, don't gulp. automation moved this from Working... to Done Sep 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
2 participants
You can’t perform that action at this time.