`PortBuilder::add_layer` doesn't need a mutex

オープン 初心者向け
#1,061 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 2 日以内に返信

@FelixMcFelix がすでに取り組んでいます。

2026年10月1日 から。

  • #1066 @FelixMcFelix による — オープン

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
84/100
issue の種類
リファクタリング
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
rust
領域
networking

調査の方向性

lib/opte/src/engine/port/mod.rs の 230-239 行目から始めて PortBuilder::add_layer を調べ、その後 issues #744 と #1059 のコンテキストを確認してください。add_layer が不要な内部可変性や mutex を使用せず、同時に builder の動作を維持できれば変更は完了です。その後、関連するプロジェクトのチェックを実行してください。

索引モデルが issue の本文から書いたものです。

説明

cleanup

https://github.com/oxidecomputer/opte/blob/fd2d6ad625cef6fb903660e57dcd4729ff66a6fe/lib/opte/src/engine/port/mod.rs#L230-L239

Ports are always constructed in an environment where we have exclusive access to the builder, so there's no need for us to handle any sort of interior mutability here. If we ever wanted that we would just put a mutex on the outside.

This came up in #744 (and I was reminded of it during #1059), but it's fairly simple and worth breaking out.

主要言語
Rust
スター
82
フォーク
16
平均マージ
3日 6時間
マージ済み PR(30日)
11

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

oxidecomputer/opte のほかの issue

oxidecomputer/opte の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。