Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Replace manual activateProxyService() with declarative Require-Capability on IProxyService?

オープン
#3,932 コメント 4 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

まだ誰も着手していません。

評価

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

調査の方向性

Read IDEWorkbenchAdvisor in org.eclipse.ui.ide.application and its META-INF/MANIFEST.MF. Compare the EventAdmin Require-Capability declarations in org.eclipse.e4.ui.workbench and org.eclipse.e4.ui.services, then check the relevant startup tests. Done means the imperative activation method and call are removed, the manifest declares IProxyService, and startup still resolves correctly.

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

説明

enhancement

IDEWorkbenchAdvisor.activateProxyService() (in org.eclipse.ui.ide.application) eagerly fetches IProxyService via OSGi BundleContext.getService(...) purely to force activation of org.eclipse.core.net.

The returned service is never used; the variable exists only to trigger the side effect.
If the lookup fails, the result is a logged warning that is easy to miss.

The same activation can be expressed declaratively in META-INF/MANIFEST.MF:

  Require-Capability: osgi.service;                                                                                                                                                                                                             
    filter:="(objectClass=org.eclipse.core.net.proxy.IProxyService)";
    effective:="active"                                                                                                                                                                                                                         

This is the modern OSGi pattern and is already used in this repository for EventAdmin in org.eclipse.e4.ui.workbench and org.eclipse.e4.ui.services.
Benefits

  • Removes ~15 lines of imperative activation code (activateProxyService() and its call site in postStartup()), including the awkward Object proxyService assigned-but-unused variable.
  • Dependency becomes visible in the manifest alongside other declared capabilities.
  • A missing IProxyService provider becomes a hard resolution failure at startup instead of a runtime log line, which is the more useful failure mode for the IDE.
  • No measurable runtime cost change — both paths end up activating org.eclipse.core.net in the same way.
主要言語
Java
スター
124
フォーク
269
平均マージ
2日 5時間
マージ済み PR(30日)
65

環境構築

はじめの一歩

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

eclipse-platform/eclipse.platform.ui のほかの issue

eclipse-platform/eclipse.platform.ui の issue をすべて見る

似ている issue

Java の issue をもっと見る

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

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