Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 353175 - Allow to disable using mirrors defined in a P2 artifacts repository
Summary: Allow to disable using mirrors defined in a P2 artifacts repository
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Tycho (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Tobias Oberlies CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-27 03:16 EDT by Matthias Gradl CLA
Modified: 2021-04-28 16:55 EDT (History)
1 user (show)

See Also:


Attachments
Allow to disable p2 mirrors defined in artifact repositories (25.57 KB, patch)
2011-07-27 07:34 EDT, Mariya Yordanova CLA
t-oberlies: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Matthias Gradl CLA 2011-07-27 03:16:47 EDT
Build Identifier: 0.13.0-SNAPSHOT

When Tycho resolves the target platform and downloads the artifacts, it makes use of mirrors from the mirror list obtained from p2.mirrorsURL property of the artifact repository.

In our case we have local mirrors of the repositories referenced in the target platform. Using a mirror obtained from the list the artifact is downloaded from an external site instead from the local mirror.

While it is possible to disable this behaviour by setting the system property eclipse.p2.mirrors=false, we'd like to add a configuration option into Tycho's target-platform-configuration for this.

Reproducible: Always
Comment 1 Mariya Yordanova CLA 2011-07-27 07:34:27 EDT
Created attachment 200439 [details]
Allow to disable p2 mirrors defined in artifact repositories

The added patch implements the described enhancement.

A new target-platform-configuration option is introduced. Add <disableP2Mirrors>true</disableP2Mirrors> in order to disable using p2 mirrors during target platform resolution.
Comment 2 Tobias Oberlies CLA 2011-07-29 04:32:10 EDT
Fixed with e3fe86d. The target-platform-configuration parameter disableP2Mirrors=true yields the same effect as eclipse.p2.mirrors=false, but through (inhertiable!) POM configuration
Comment 3 Tobias Oberlies CLA 2011-08-03 09:12:32 EDT
The implementation currently uses reflection because there is no API in p2 to disable mirrors properly. The request for the API has been made in bug 266199.