Skip to content

Commit

Permalink
fix(legal): Use correct licenses for tower-batch-control and zebra-ne…
Browse files Browse the repository at this point in the history
…twork (#6927)
  • Loading branch information
teor2345 authored Jun 12, 2023
1 parent 619f737 commit 7632aef
Show file tree
Hide file tree
Showing 6 changed files with 53 additions and 5 deletions.
9 changes: 8 additions & 1 deletion tower-batch-control/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
[package]
name = "tower-batch-control"
version = "0.2.40"
authors = ["Zcash Foundation <[email protected]>"]
authors = ["Zcash Foundation <[email protected]>", "Tower Maintainers <[email protected]>"]
description = "Tower middleware for batch request processing"
# # Legal
#
# This licence is deliberately different to the rest of Zebra.
#
# This code was modified from a 2019 version of:
# https://github.com/tower-rs/tower/tree/master/tower/src/buffer
license = "MIT"
license-file = "LICENSE"
repository = "https://github.com/ZcashFoundation/zebra"
edition = "2021"

Expand Down
26 changes: 26 additions & 0 deletions tower-batch-control/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
Copyright (c) 2019-2023 Zcash Foundation
Copyright (c) 2019 Tower Contributors

Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:

The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
8 changes: 8 additions & 0 deletions tower-batch-control/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,14 @@
//! a `Service<R>`. The wrapped service does not need to implement any batch
//! control logic, as it will receive explicit [`Flush`](BatchControl::Flush)
//! requests from the wrapper.
//!
//! ## Implementation History
//!
//! The `tower-batch-control` code was modified from a 2019 version of:
//! https://github.com/tower-rs/tower/tree/master/tower/src/buffer
//!
//! A modified fork of this crate is available on crates.io as `tower-batch`.
//! It is focused on batching disk writes.
pub mod error;
pub mod future;
Expand Down
6 changes: 6 additions & 0 deletions zebra-network/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@ name = "zebra-network"
version = "1.0.0-beta.25"
authors = ["Zcash Foundation <[email protected]>", "Tower Maintainers <[email protected]>"]
description = "Networking code for Zebra"
# # Legal
#
# This licence is deliberately different to the rest of Zebra.
#
# zebra-network/src/peer_set/set.rs was modified from a 2019 version of:
# https://github.com/tower-rs/tower/tree/master/tower/src/balance/p2c/service.rs
license = "MIT"
license-file = "LICENSE"
repository = "https://github.com/ZcashFoundation/zebra"
Expand Down
3 changes: 2 additions & 1 deletion zebra-network/LICENSE
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
Copyright (c) 2019-2023 Zcash Foundation
Copyright (c) 2019 Tower Contributors

Permission is hereby granted, free of charge, to any
Expand All @@ -22,4 +23,4 @@ SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
DEALINGS IN THE SOFTWARE.
6 changes: 3 additions & 3 deletions zebra-network/src/peer_set/set.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
//!
//! # Implementation
//!
//! The [`PeerSet`] implementation is adapted from the one in the [Tower Balance][tower-balance] crate.
//! As described in that crate's documentation, it:
//! The [`PeerSet`] implementation is adapted from the one in [tower::Balance][tower-balance].
//! As described in Tower's documentation, it:
//!
//! > Distributes requests across inner services using the [Power of Two Choices][p2c].
//! >
Expand Down Expand Up @@ -40,7 +40,7 @@
//!
//! [finagle]: https://twitter.github.io/finagle/guide/Clients.html#power-of-two-choices-p2c-least-loaded
//! [p2c]: http://www.eecs.harvard.edu/~michaelm/postscripts/handbook2001.pdf
//! [tower-balance]: https://crates.io/crates/tower-balance
//! [tower-balance]: https://github.com/tower-rs/tower/tree/master/tower/src/balance
//!
//! # Behavior During Network Upgrades
//!
Expand Down

0 comments on commit 7632aef

Please sign in to comment.