Skip to content

Commit

Permalink
chore: apply clang format
Browse files Browse the repository at this point in the history
Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
  • Loading branch information
dotnwat committed Dec 21, 2022
1 parent ce890dd commit 208e09d
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 10 deletions.
4 changes: 1 addition & 3 deletions src/v/kafka/server/connection_context.h
Original file line number Diff line number Diff line change
Expand Up @@ -190,9 +190,7 @@ class connection_context final
ss::future<> process_one_request();
bool is_finished_parsing() const;
ss::net::inet_address client_host() const { return _client_addr; }
uint16_t client_port() const {
return conn ? conn->addr.port() : 0;
}
uint16_t client_port() const { return conn ? conn->addr.port() : 0; }

private:
// Reserve units from memory from the memory semaphore in proportion
Expand Down
4 changes: 2 additions & 2 deletions src/v/net/server.cc
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,8 @@ static inline void print_exceptional_future(
}
}

ss::future<>
server::apply_proto(ss::lw_shared_ptr<net::connection> conn, conn_quota::units cq_units) {
ss::future<> server::apply_proto(
ss::lw_shared_ptr<net::connection> conn, conn_quota::units cq_units) {
return apply(conn)
.then_wrapped(
[this, conn, cq_units = std::move(cq_units)](ss::future<> f) {
Expand Down
3 changes: 2 additions & 1 deletion src/v/net/server.h
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,8 @@ class server {
ss::future<> accept(listener&);
ss::future<ss::stop_iteration>
accept_finish(ss::sstring, ss::future<ss::accept_result>);
ss::future<> apply_proto(ss::lw_shared_ptr<net::connection>, conn_quota::units);
ss::future<>
apply_proto(ss::lw_shared_ptr<net::connection>, conn_quota::units);
void setup_metrics();
void setup_public_metrics();

Expand Down
7 changes: 4 additions & 3 deletions src/v/rpc/rpc_server.cc
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ namespace rpc {
static constexpr size_t reply_min_compression_bytes = 1024;

struct server_context_impl final : streaming_context {
server_context_impl(net::server& server, ss::lw_shared_ptr<net::connection> conn, header h)
server_context_impl(
net::server& server, ss::lw_shared_ptr<net::connection> conn, header h)
: server(server)
, conn(conn)
, hdr(h) {
Expand Down Expand Up @@ -107,8 +108,8 @@ ss::future<> rpc_server::send_reply_skip_payload(
co_await send_reply(std::move(ctx), std::move(buf));
}

ss::future<>
rpc_server::dispatch_method_once(header h, ss::lw_shared_ptr<net::connection> conn) {
ss::future<> rpc_server::dispatch_method_once(
header h, ss::lw_shared_ptr<net::connection> conn) {
const auto method_id = h.meta;
auto ctx = ss::make_lw_shared<server_context_impl>(*this, conn, h);
probe().add_bytes_received(size_of_rpc_header + h.payload_size);
Expand Down
3 changes: 2 additions & 1 deletion src/v/rpc/rpc_server.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@ class rpc_server : public net::server {
}

private:
ss::future<> dispatch_method_once(header, ss::lw_shared_ptr<net::connection>);
ss::future<>
dispatch_method_once(header, ss::lw_shared_ptr<net::connection>);
ss::future<> send_reply(ss::lw_shared_ptr<server_context_impl>, netbuf);
ss::future<>
send_reply_skip_payload(ss::lw_shared_ptr<server_context_impl>, netbuf);
Expand Down

0 comments on commit 208e09d

Please sign in to comment.