Issue
I have read this article about how to mirror a p2 update site to local, but how can I mirror a p2 update site (eg. https://download.eclipse.org/releases/2022-06
) to one of my remote p2 update sites ?
By the way, are there any files required as a p2 update site? I noticed that the contents of the mirror-to local repository were missing some files, such as p2.index, compared to the mirror-from remote p2 update site.
Solution
It does not matter whether your p2 update site is locally (accessed via file://...
) or remotely (http://...
or https://...
). It's a folder structure that can be moved. So you can upload the directory of your to local mirrored p2 update site and vice versa.
A p2 repository must contain an artifacts.xml
file and a content.xml
file that might also be provided compressed as .jar
and/or even more compressed as .xml.xz
(assuming it's an artifact and a metadata repository in one and not separated, which is also possible). The p2.index
file existing only for performance reasons. The best performance you will get with a p2.index
plus an artifacts.xml.xz
and a content.xml.xz
file and for backward compatibility, an artifacts.jar
file and a content.jar
file in addition.
See Eclipse Wiki: What is the p2.index file? for more details.
You can also have a composite p2 repository.
Answered By - howlger
Answer Checked By - Candace Johnson (JavaFixing Volunteer)