]> git.bitcoin.ninja Git - rust-lightning/commit
Implement (de)serialization for Scorer
authorJeffrey Czyz <jkczyz@gmail.com>
Fri, 29 Oct 2021 04:44:26 +0000 (23:44 -0500)
committerJeffrey Czyz <jkczyz@gmail.com>
Tue, 2 Nov 2021 19:48:40 +0000 (14:48 -0500)
commitae210e7d09758560b0e418b939222e7bc26ee009
treec93d886f1d4cb876dc63371ce213d26ff5951536
parenta8d3b5aabf88487cb72dccd4553ba1894166fbb9
Implement (de)serialization for Scorer

Scorer should be serialized to retain penalty data between restarts.
Implement (de)serialization for Scorer by serializing last failure times
as duration since the UNIX epoch. For no-std, the zero-Duration is used.
lightning/src/routing/scorer.rs
lightning/src/util/ser.rs