remoting: PeerSessionFactory [chromium/src : main]

1 view
Skip to first unread message

Yuwei Huang (Gerrit)

unread,
Jul 24, 2026, 3:10:17 PM (13 hours ago) Jul 24
to Chromium LUCI CQ, chromium...@chromium.org, chromotin...@chromium.org

Yuwei Huang added 6 comments

File remoting/host/chromoting_host.h
Line 185, Patchset 10: PeerSessionFactory* peer_session_factory() const {
Yuwei Huang . resolved

Is this getter actually being used? If not, please remove it.

Yuwei Huang

Done

File remoting/host/chromoting_host_unittest.cc
Line 151, Patchset 10: std::make_shared<std::unique_ptr<protocol::ConnectionToClient>>(
Yuwei Huang . resolved

This is a very weird pattern. Are you just trying to pass `ConnectionToClient` into the lambda?

There is the `Return(ByMove())` pattern as demonstrated in remoting/host/desktop_process_unittest.cc. Can it be used instead?

Yuwei Huang

Done

Line 154, Patchset 10: .Times(testing::AtMost(1))
Yuwei Huang . resolved

There is `using testing::AtMost` above, so just use `AtMost(1)` here.

Yuwei Huang

Done

File remoting/host/client_session_unittest.cc
Line 144, Patchset 10: std::make_shared<std::unique_ptr<MockPeerSession>>(std::move(mock_peer));
Yuwei Huang . resolved

Again. Very bizarre construct. See if `Return(ByMove())` works.

Yuwei Huang

Done

File remoting/host/peer_session_impl.h
Line 431, Patchset 10:// Factory implementation for creating `PeerSessionImpl` instances.
Yuwei Huang . resolved

Should probably say "Factory for creating..." and get rid of "implementation".

Yuwei Huang

Done

File remoting/host/remoting_me2me_host.cc
Line 2039, Patchset 10: context_->audio_task_runner(), /*pairing_registry=*/nullptr);
Yuwei Huang . resolved

Looks like you always pass `nullptr` for `pairing_registry` then later call `set_pairing_registry`. What about just getting rid of this argument?

Yuwei Huang

Done

Open in Gerrit

Related details

Attention set is empty
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Ibd66338f1ac65ce6eeff54f44bc71748eb6b6b9b
Gerrit-Change-Number: 8137956
Gerrit-PatchSet: 13
Gerrit-Owner: Yuwei Huang <yuw...@chromium.org>
Gerrit-Reviewer: Yuwei Huang <yuw...@chromium.org>
Gerrit-Comment-Date: Fri, 24 Jul 2026 19:10:07 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Yuwei Huang <yuw...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Yuwei Huang (Gerrit)

unread,
Jul 24, 2026, 3:15:22 PM (13 hours ago) Jul 24
to Joe Downing, Chromium LUCI CQ, chromium...@chromium.org, chromotin...@chromium.org
Attention needed from Joe Downing

Yuwei Huang voted and added 1 comment

Votes added by Yuwei Huang

Auto-Submit+1
Commit-Queue+1

1 comment

Patchset-level comments
File-level comment, Patchset 13 (Latest):
Yuwei Huang . resolved

PTAL thanks!

Open in Gerrit

Related details

Attention is currently required from:
  • Joe Downing
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Ibd66338f1ac65ce6eeff54f44bc71748eb6b6b9b
Gerrit-Change-Number: 8137956
Gerrit-PatchSet: 13
Gerrit-Owner: Yuwei Huang <yuw...@chromium.org>
Gerrit-Reviewer: Joe Downing <joe...@chromium.org>
Gerrit-Reviewer: Yuwei Huang <yuw...@chromium.org>
Gerrit-Attention: Joe Downing <joe...@chromium.org>
Gerrit-Comment-Date: Fri, 24 Jul 2026 19:15:11 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
satisfied_requirement
unsatisfied_requirement
open
diffy

Joe Downing (Gerrit)

unread,
12:07 AM (4 hours ago) 12:07 AM
to Yuwei Huang, Chromium LUCI CQ, chromium...@chromium.org, chromotin...@chromium.org
Attention needed from Yuwei Huang

Joe Downing voted and added 2 comments

Votes added by Joe Downing

Code-Review+1

2 comments

File remoting/host/peer_session_impl.cc
Line 182, Patchset 13 (Latest): event_handler_ = event_handler;
client_jid_ = std::string(client_jid);
Joe Downing . unresolved

Would it be useful to CHECK here that event_handler_ is null (meaning Start was called once) and that event_handler and client_jid are valid?

Line 1576, Patchset 13 (Latest): LOG_IF(WARNING, !get_ice_config_fetcher_cb_)
<< "Missing Ice Config Fetcher callback.";
Joe Downing . unresolved

I know this code was copied but I'm trying to recall whether there is a valid production code use case where ice_config_fethcer_cb is null. IIRC we used to pass the IceConfig down from the website through the NMH but that code is gone since we always pass down an OAuth access token.

Actually that is the case and you just removed the constants. Can we require that get_ice_config_fetcher_cb_ is valid now (since we're close to branch point, feel free to do this in a follow-up if you want this CL to be a pure refactoring effort).

Open in Gerrit

Related details

Attention is currently required from:
  • Yuwei Huang
Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ibd66338f1ac65ce6eeff54f44bc71748eb6b6b9b
    Gerrit-Change-Number: 8137956
    Gerrit-PatchSet: 13
    Gerrit-Owner: Yuwei Huang <yuw...@chromium.org>
    Gerrit-Reviewer: Joe Downing <joe...@chromium.org>
    Gerrit-Reviewer: Yuwei Huang <yuw...@chromium.org>
    Gerrit-Attention: Yuwei Huang <yuw...@chromium.org>
    Gerrit-Comment-Date: Sat, 25 Jul 2026 04:06:52 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy
    Reply all
    Reply to author
    Forward
    0 new messages