diff options
author | Yigit Sever | 2021-04-07 04:33:45 +0300 |
---|---|---|
committer | Yigit Sever | 2021-04-07 04:35:44 +0300 |
commit | 20dad7d4290f2c98583168cd4b9afcdec4802944 (patch) | |
tree | b761b56e8b629d8a295b4dd7ca55a5d7745fd4c6 /Cargo.lock | |
parent | 95ff6371303ac28d05b25fd9f6e436c5d0a58d4c (diff) | |
download | gradecoin-20dad7d4290f2c98583168cd4b9afcdec4802944.tar.gz gradecoin-20dad7d4290f2c98583168cd4b9afcdec4802944.tar.bz2 gradecoin-20dad7d4290f2c98583168cd4b9afcdec4802944.zip |
Implement Block GET/PUT with new schema
- `Arc`+`Mutex` is replaced by `parking_lot::RwLock,` decoupled
Read+Write and ability to upgrade read locks into write locks if
needed
- Schema has changed, `Db` is now a struct that implements `new()` to
return a new instance of itself, pros/cons listed in code but tl;dr
blockchain and pending transactions are separate now
- `custom_filters` now supports extracting Block json and Transaction
json in separate functions too
- /block GET and PUT implemented, `Blocks` currently have one check
(transactions appear in pending transaction)
- debug is working after something, dunno how I fixed it
Diffstat (limited to 'Cargo.lock')
-rw-r--r-- | Cargo.lock | 63 |
1 files changed, 62 insertions, 1 deletions
@@ -108,6 +108,15 @@ dependencies = [ | |||
108 | ] | 108 | ] |
109 | 109 | ||
110 | [[package]] | 110 | [[package]] |
111 | name = "cloudabi" | ||
112 | version = "0.0.3" | ||
113 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
114 | checksum = "ddfc5b9aa5d4507acaf872de71051dfd0e309860e88966e1051e462a077aac4f" | ||
115 | dependencies = [ | ||
116 | "bitflags", | ||
117 | ] | ||
118 | |||
119 | [[package]] | ||
111 | name = "cpuid-bool" | 120 | name = "cpuid-bool" |
112 | version = "0.1.2" | 121 | version = "0.1.2" |
113 | source = "registry+https://github.com/rust-lang/crates.io-index" | 122 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -273,6 +282,7 @@ version = "0.1.0" | |||
273 | dependencies = [ | 282 | dependencies = [ |
274 | "chrono", | 283 | "chrono", |
275 | "log", | 284 | "log", |
285 | "parking_lot", | ||
276 | "pretty_env_logger", | 286 | "pretty_env_logger", |
277 | "serde", | 287 | "serde", |
278 | "serde_json", | 288 | "serde_json", |
@@ -475,6 +485,15 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
475 | checksum = "9385f66bf6105b241aa65a61cb923ef20efc665cb9f9bb50ac2f0c4b7f378d41" | 485 | checksum = "9385f66bf6105b241aa65a61cb923ef20efc665cb9f9bb50ac2f0c4b7f378d41" |
476 | 486 | ||
477 | [[package]] | 487 | [[package]] |
488 | name = "lock_api" | ||
489 | version = "0.3.4" | ||
490 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
491 | checksum = "c4da24a77a3d8a6d4862d95f72e6fdb9c09a643ecdb402d754004a557f2bec75" | ||
492 | dependencies = [ | ||
493 | "scopeguard", | ||
494 | ] | ||
495 | |||
496 | [[package]] | ||
478 | name = "log" | 497 | name = "log" |
479 | version = "0.4.14" | 498 | version = "0.4.14" |
480 | source = "registry+https://github.com/rust-lang/crates.io-index" | 499 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -597,6 +616,30 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
597 | checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" | 616 | checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" |
598 | 617 | ||
599 | [[package]] | 618 | [[package]] |
619 | name = "parking_lot" | ||
620 | version = "0.10.2" | ||
621 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
622 | checksum = "d3a704eb390aafdc107b0e392f56a82b668e3a71366993b5340f5833fd62505e" | ||
623 | dependencies = [ | ||
624 | "lock_api", | ||
625 | "parking_lot_core", | ||
626 | ] | ||
627 | |||
628 | [[package]] | ||
629 | name = "parking_lot_core" | ||
630 | version = "0.7.2" | ||
631 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
632 | checksum = "d58c7c768d4ba344e3e8d72518ac13e259d7c7ade24167003b8488e10b6740a3" | ||
633 | dependencies = [ | ||
634 | "cfg-if 0.1.10", | ||
635 | "cloudabi", | ||
636 | "libc", | ||
637 | "redox_syscall 0.1.57", | ||
638 | "smallvec", | ||
639 | "winapi 0.3.9", | ||
640 | ] | ||
641 | |||
642 | [[package]] | ||
600 | name = "percent-encoding" | 643 | name = "percent-encoding" |
601 | version = "2.1.0" | 644 | version = "2.1.0" |
602 | source = "registry+https://github.com/rust-lang/crates.io-index" | 645 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -784,6 +827,12 @@ dependencies = [ | |||
784 | 827 | ||
785 | [[package]] | 828 | [[package]] |
786 | name = "redox_syscall" | 829 | name = "redox_syscall" |
830 | version = "0.1.57" | ||
831 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
832 | checksum = "41cc0f7e4d5d4544e8861606a285bb08d3e70712ccc7d2b84d7c0ccfaf4b05ce" | ||
833 | |||
834 | [[package]] | ||
835 | name = "redox_syscall" | ||
787 | version = "0.2.5" | 836 | version = "0.2.5" |
788 | source = "registry+https://github.com/rust-lang/crates.io-index" | 837 | source = "registry+https://github.com/rust-lang/crates.io-index" |
789 | checksum = "94341e4e44e24f6b591b59e47a8a027df12e008d73fd5672dbea9cc22f4507d9" | 838 | checksum = "94341e4e44e24f6b591b59e47a8a027df12e008d73fd5672dbea9cc22f4507d9" |
@@ -836,6 +885,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
836 | checksum = "ea6a9290e3c9cf0f18145ef7ffa62d68ee0bf5fcd651017e586dc7fd5da448c2" | 885 | checksum = "ea6a9290e3c9cf0f18145ef7ffa62d68ee0bf5fcd651017e586dc7fd5da448c2" |
837 | 886 | ||
838 | [[package]] | 887 | [[package]] |
888 | name = "scopeguard" | ||
889 | version = "1.1.0" | ||
890 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
891 | checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" | ||
892 | |||
893 | [[package]] | ||
839 | name = "serde" | 894 | name = "serde" |
840 | version = "1.0.125" | 895 | version = "1.0.125" |
841 | source = "registry+https://github.com/rust-lang/crates.io-index" | 896 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -907,6 +962,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
907 | checksum = "c111b5bd5695e56cffe5129854aa230b39c93a305372fdbb2668ca2394eea9f8" | 962 | checksum = "c111b5bd5695e56cffe5129854aa230b39c93a305372fdbb2668ca2394eea9f8" |
908 | 963 | ||
909 | [[package]] | 964 | [[package]] |
965 | name = "smallvec" | ||
966 | version = "1.6.1" | ||
967 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
968 | checksum = "fe0f37c9e8f3c5a4a66ad655a93c74daac4ad00c441533bf5c6e7990bb42604e" | ||
969 | |||
970 | [[package]] | ||
910 | name = "socket2" | 971 | name = "socket2" |
911 | version = "0.3.19" | 972 | version = "0.3.19" |
912 | source = "registry+https://github.com/rust-lang/crates.io-index" | 973 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -937,7 +998,7 @@ dependencies = [ | |||
937 | "cfg-if 1.0.0", | 998 | "cfg-if 1.0.0", |
938 | "libc", | 999 | "libc", |
939 | "rand 0.8.3", | 1000 | "rand 0.8.3", |
940 | "redox_syscall", | 1001 | "redox_syscall 0.2.5", |
941 | "remove_dir_all", | 1002 | "remove_dir_all", |
942 | "winapi 0.3.9", | 1003 | "winapi 0.3.9", |
943 | ] | 1004 | ] |