Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ src_libbitcoin_node_la_SOURCES = \
src/protocols/protocol_header_in_70012.cpp \
src/protocols/protocol_header_out_31800.cpp \
src/protocols/protocol_header_out_70012.cpp \
src/protocols/protocol_html.cpp \
src/protocols/protocol_observer.cpp \
src/protocols/protocol_peer.cpp \
src/protocols/protocol_performer.cpp \
Expand Down
1 change: 1 addition & 0 deletions builds/cmake/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,7 @@ add_library( ${CANONICAL_LIB_NAME}
"../../src/protocols/protocol_header_in_70012.cpp"
"../../src/protocols/protocol_header_out_31800.cpp"
"../../src/protocols/protocol_header_out_70012.cpp"
"../../src/protocols/protocol_html.cpp"
"../../src/protocols/protocol_observer.cpp"
"../../src/protocols/protocol_peer.cpp"
"../../src/protocols/protocol_performer.cpp"
Expand Down
1 change: 1 addition & 0 deletions builds/msvc/vs2022/libbitcoin-node/libbitcoin-node.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,7 @@
<ClCompile Include="..\..\..\..\src\protocols\protocol_header_in_70012.cpp" />
<ClCompile Include="..\..\..\..\src\protocols\protocol_header_out_31800.cpp" />
<ClCompile Include="..\..\..\..\src\protocols\protocol_header_out_70012.cpp" />
<ClCompile Include="..\..\..\..\src\protocols\protocol_html.cpp" />
<ClCompile Include="..\..\..\..\src\protocols\protocol_observer.cpp" />
<ClCompile Include="..\..\..\..\src\protocols\protocol_peer.cpp" />
<ClCompile Include="..\..\..\..\src\protocols\protocol_performer.cpp" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,9 @@
<ClCompile Include="..\..\..\..\src\protocols\protocol_header_out_70012.cpp">
<Filter>src\protocols</Filter>
</ClCompile>
<ClCompile Include="..\..\..\..\src\protocols\protocol_html.cpp">
<Filter>src\protocols</Filter>
</ClCompile>
<ClCompile Include="..\..\..\..\src\protocols\protocol_observer.cpp">
<Filter>src\protocols</Filter>
</ClCompile>
Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/block_arena.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#ifndef LIBBITCOIN_NODE_BLOCK_ARENA_HPP
#define LIBBITCOIN_NODE_BLOCK_ARENA_HPP

#include <bitcoin/system.hpp>
#include <bitcoin/node/define.hpp>

namespace libbitcoin {
Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/block_memory.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#define LIBBITCOIN_NODE_BLOCK_MEMORY_HPP

#include <atomic>
#include <bitcoin/network.hpp>
#include <bitcoin/node/block_arena.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/channels/channel.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#define LIBBITCOIN_NODE_CHANNELS_CHANNEL_HPP

#include <memory>
#include <bitcoin/network.hpp>
#include <bitcoin/node/channels/channel.hpp>
#include <bitcoin/node/configuration.hpp>
#include <bitcoin/node/define.hpp>
Expand Down
3 changes: 1 addition & 2 deletions include/bitcoin/node/channels/channel_http.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#define LIBBITCOIN_NODE_CHANNELS_CHANNEL_HTTP_HPP

#include <memory>
#include <bitcoin/network.hpp>
#include <bitcoin/node/channels/channel.hpp>
#include <bitcoin/node/configuration.hpp>
#include <bitcoin/node/define.hpp>
Expand All @@ -35,7 +34,7 @@ class BCN_API channel_http
{
public:
typedef std::shared_ptr<node::channel_http> ptr;
using options_t = network::settings::http_server;
using options_t = network::channel_http::options_t;

channel_http(const network::logger& log, const network::socket::ptr& socket,
const node::configuration& config, uint64_t identifier=zero,
Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/channels/channel_peer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#define LIBBITCOIN_NODE_CHANNELS_CHANNEL_PEER_HPP

#include <memory>
#include <bitcoin/network.hpp>
#include <bitcoin/node/channels/channel.hpp>
#include <bitcoin/node/configuration.hpp>
#include <bitcoin/node/define.hpp>
Expand Down
3 changes: 1 addition & 2 deletions include/bitcoin/node/channels/channel_tcp.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#define LIBBITCOIN_NODE_CHANNELS_CHANNEL_TCP_HPP

#include <memory>
#include <bitcoin/network.hpp>
#include <bitcoin/node/channels/channel.hpp>
#include <bitcoin/node/configuration.hpp>
#include <bitcoin/node/define.hpp>
Expand All @@ -35,7 +34,7 @@ class BCN_API channel_tcp
{
public:
typedef std::shared_ptr<node::channel_tcp> ptr;
using options_t = network::settings::tcp_server;
using options_t = network::channel_tcp::options_t;

channel_tcp(const network::logger& log, const network::socket::ptr& socket,
const node::configuration& config, uint64_t identifier=zero,
Expand Down
1 change: 1 addition & 0 deletions include/bitcoin/node/channels/channels.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
#include <bitcoin/node/channels/channel_peer.hpp>
#include <bitcoin/node/channels/channel_tcp.hpp>
#include <bitcoin/node/channels/channel_http.hpp>
// add channel_websocket to network and derive here

#endif

2 changes: 0 additions & 2 deletions include/bitcoin/node/chasers/chaser.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@
#ifndef LIBBITCOIN_NODE_CHASERS_CHASER_HPP
#define LIBBITCOIN_NODE_CHASERS_CHASER_HPP

#include <bitcoin/database.hpp>
#include <bitcoin/network.hpp>
#include <bitcoin/node/configuration.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/chasers/chaser_block.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#ifndef LIBBITCOIN_NODE_CHASERS_CHASER_BLOCK_HPP
#define LIBBITCOIN_NODE_CHASERS_CHASER_BLOCK_HPP

#include <bitcoin/system.hpp>
#include <bitcoin/node/chasers/chaser_organize.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/chasers/chaser_check.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@

#include <deque>
#include <unordered_map>
#include <bitcoin/network.hpp>
#include <bitcoin/node/chasers/chaser.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/chasers/chaser_confirm.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#ifndef LIBBITCOIN_NODE_CHASERS_CHASER_CONFIRM_HPP
#define LIBBITCOIN_NODE_CHASERS_CHASER_CONFIRM_HPP

#include <bitcoin/database.hpp>
#include <bitcoin/node/chasers/chaser.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/chasers/chaser_header.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#ifndef LIBBITCOIN_NODE_CHASERS_CHASER_HEADER_HPP
#define LIBBITCOIN_NODE_CHASERS_CHASER_HEADER_HPP

#include <bitcoin/system.hpp>
#include <bitcoin/node/chasers/chaser_organize.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
2 changes: 0 additions & 2 deletions include/bitcoin/node/chasers/chaser_organize.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@
#define LIBBITCOIN_NODE_CHASERS_CHASER_ORGANIZE_HPP

#include <unordered_map>
#include <bitcoin/database.hpp>
#include <bitcoin/network.hpp>
#include <bitcoin/node/chasers/chaser.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/chasers/chaser_snapshot.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#define LIBBITCOIN_NODE_CHASERS_CHASER_SNAPSHOT_HPP

#include <atomic>
#include <bitcoin/system.hpp>
#include <bitcoin/node/chasers/chaser.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/chasers/chaser_storage.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#ifndef LIBBITCOIN_NODE_CHASERS_CHASER_STORAGE_HPP
#define LIBBITCOIN_NODE_CHASERS_CHASER_STORAGE_HPP

#include <bitcoin/network.hpp>
#include <bitcoin/node/chasers/chaser.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/chasers/chaser_transaction.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#ifndef LIBBITCOIN_NODE_CHASERS_CHASER_TRANSACTION_HPP
#define LIBBITCOIN_NODE_CHASERS_CHASER_TRANSACTION_HPP

#include <bitcoin/system.hpp>
#include <bitcoin/node/chasers/chaser.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
2 changes: 0 additions & 2 deletions include/bitcoin/node/chasers/chaser_validate.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@
#define LIBBITCOIN_NODE_CHASERS_CHASER_VALIDATE_HPP

#include <atomic>
#include <bitcoin/database.hpp>
#include <bitcoin/network.hpp>
#include <bitcoin/node/chasers/chaser.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
3 changes: 1 addition & 2 deletions include/bitcoin/node/configuration.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@
#ifndef LIBBITCOIN_NODE_CONFIGURATION_HPP
#define LIBBITCOIN_NODE_CONFIGURATION_HPP

#include <bitcoin/database.hpp>
#include <bitcoin/network.hpp>
#include <bitcoin/node/define.hpp>
#include <bitcoin/node/settings.hpp>

Expand Down Expand Up @@ -62,6 +60,7 @@ class BCN_API configuration

/// Settings.
log::settings log;
server::settings server;
node::settings node;
network::settings network;
database::settings database;
Expand Down
2 changes: 0 additions & 2 deletions include/bitcoin/node/full_node.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@
#ifndef LIBBITCOIN_NODE_FULL_NODE_HPP
#define LIBBITCOIN_NODE_FULL_NODE_HPP

#include <bitcoin/database.hpp>
#include <bitcoin/network.hpp>
#include <bitcoin/node/block_memory.hpp>
#include <bitcoin/node/chasers/chasers.hpp>
#include <bitcoin/node/configuration.hpp>
Expand Down
2 changes: 0 additions & 2 deletions include/bitcoin/node/impl/chasers/chaser_organize.ipp
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@

#include <algorithm>
#include <ranges>
#include <bitcoin/database.hpp>
#include <bitcoin/network.hpp>
#include <bitcoin/node/chasers/chaser.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/parser.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#ifndef LIBBITCOIN_NODE_PARSER_HPP
#define LIBBITCOIN_NODE_PARSER_HPP

#include <bitcoin/system.hpp>
#include <bitcoin/node/configuration.hpp>
#include <bitcoin/node/define.hpp>

Expand Down
7 changes: 3 additions & 4 deletions include/bitcoin/node/protocols/protocol.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@
#define LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_HPP

#include <memory>
#include <bitcoin/network.hpp>
#include <bitcoin/node/channels/channels.hpp>
#include <bitcoin/node/configuration.hpp>
#include <bitcoin/node/define.hpp>

// Only session.hpp.
#include <bitcoin/node/sessions/session.hpp>

namespace libbitcoin {
Expand All @@ -45,15 +46,13 @@ namespace node {
class BCN_API protocol
{
protected:
typedef std::shared_ptr<node::protocol> ptr;

DELETE_COPY_MOVE_DESTRUCT(protocol);

/// Constructors.
/// -----------------------------------------------------------------------

// reinterpret_pointer_cast because channel is abstract.
protocol(const node::session::ptr& session,
protocol(const auto& session,
const network::channel::ptr& channel) NOEXCEPT
: channel_(std::reinterpret_pointer_cast<node::channel>(channel)),
session_(session)
Expand Down
3 changes: 0 additions & 3 deletions include/bitcoin/node/protocols/protocol_bitcoind.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#define LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_BITCOIND_HPP

#include <memory>
#include <bitcoin/network.hpp>
#include <bitcoin/node/channels/channels.hpp>
#include <bitcoin/node/define.hpp>
#include <bitcoin/node/protocols/protocol_http.hpp>
Expand All @@ -34,8 +33,6 @@ class BCN_API protocol_bitcoind
{
public:
typedef std::shared_ptr<protocol_bitcoind> ptr;
using options_t = network::settings::http_server;
using channel_t = node::channel_http;

protocol_bitcoind(const auto& session,
const network::channel::ptr& channel,
Expand Down
2 changes: 0 additions & 2 deletions include/bitcoin/node/protocols/protocol_block_in_106.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@
#define LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_BLOCK_IN_106_HPP

#include <unordered_set>
#include <bitcoin/network.hpp>
#include <bitcoin/node/define.hpp>
#include <bitcoin/node/protocols/protocol.hpp>
#include <bitcoin/node/protocols/protocol_peer.hpp>

namespace libbitcoin {
Expand Down
1 change: 0 additions & 1 deletion include/bitcoin/node/protocols/protocol_block_in_31800.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#ifndef LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_BLOCK_IN_31800_HPP
#define LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_BLOCK_IN_31800_HPP

#include <bitcoin/network.hpp>
#include <bitcoin/node/chasers/chasers.hpp>
#include <bitcoin/node/define.hpp>
#include <bitcoin/node/protocols/protocol_performer.hpp>
Expand Down
2 changes: 0 additions & 2 deletions include/bitcoin/node/protocols/protocol_block_out_106.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,7 @@
#ifndef LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_BLOCK_OUT_106_HPP
#define LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_BLOCK_OUT_106_HPP

#include <bitcoin/network.hpp>
#include <bitcoin/node/define.hpp>
#include <bitcoin/node/protocols/protocol.hpp>
#include <bitcoin/node/protocols/protocol_peer.hpp>

namespace libbitcoin {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#ifndef LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_BLOCK_OUT_70012_HPP
#define LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_BLOCK_OUT_70012_HPP

#include <bitcoin/network.hpp>
#include <bitcoin/node/define.hpp>
#include <bitcoin/node/protocols/protocol_block_out_106.hpp>

Expand Down
3 changes: 0 additions & 3 deletions include/bitcoin/node/protocols/protocol_electrum.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#define LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_ELECTRUM_HPP

#include <memory>
#include <bitcoin/network.hpp>
#include <bitcoin/node/channels/channels.hpp>
#include <bitcoin/node/define.hpp>
#include <bitcoin/node/protocols/protocol_tcp.hpp>
Expand All @@ -34,8 +33,6 @@ class BCN_API protocol_electrum
{
public:
typedef std::shared_ptr<protocol_electrum> ptr;
using options_t = network::settings::tcp_server;
using channel_t = node::channel_tcp;

protocol_electrum(const auto& session,
const network::channel::ptr& channel,
Expand Down
8 changes: 0 additions & 8 deletions include/bitcoin/node/protocols/protocol_explore.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@
#define LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_EXPLORE_HPP

#include <memory>
#include <bitcoin/network.hpp>
#include <bitcoin/node/channels/channels.hpp>
#include <bitcoin/node/define.hpp>
#include <bitcoin/node/protocols/protocol_html.hpp>

Expand All @@ -34,8 +32,6 @@ class BCN_API protocol_explore
{
public:
typedef std::shared_ptr<protocol_explore> ptr;
using options_t = network::settings::html_server;
using channel_t = node::channel_http;

protocol_explore(const auto& session,
const network::channel::ptr& channel,
Expand All @@ -54,10 +50,6 @@ class BCN_API protocol_explore
protected:
void handle_receive_get(const code& ec,
const network::http::method::get& request) NOEXCEPT override;

private:
// This is thread safe.
////const options_t& options_;
};

} // namespace node
Expand Down
2 changes: 0 additions & 2 deletions include/bitcoin/node/protocols/protocol_filter_out_70015.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@
#define LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_CLIENT_FILTER_HPP

#include <memory>
#include <bitcoin/network.hpp>
#include <bitcoin/node/define.hpp>
#include <bitcoin/node/protocols/protocol.hpp>
#include <bitcoin/node/protocols/protocol_peer.hpp>

namespace libbitcoin {
Expand Down
2 changes: 0 additions & 2 deletions include/bitcoin/node/protocols/protocol_header_in_31800.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,7 @@
#ifndef LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_HEADER_IN_31800_HPP
#define LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_HEADER_IN_31800_HPP

#include <bitcoin/network.hpp>
#include <bitcoin/node/define.hpp>
#include <bitcoin/node/protocols/protocol.hpp>
#include <bitcoin/node/protocols/protocol_peer.hpp>

namespace libbitcoin {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#ifndef LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_HEADER_IN_70012_HPP
#define LIBBITCOIN_NODE_PROTOCOLS_PROTOCOL_HEADER_IN_70012_HPP

#include <bitcoin/network.hpp>
#include <bitcoin/node/define.hpp>
#include <bitcoin/node/protocols/protocol_header_in_31800.hpp>

Expand Down
Loading
Loading