[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [p2-dev] Provisioning p2 with p2?
- From: "Haigermoser, Helmut" <Helmut.Haigermoser@xxxxxxxxxxxxx>
- Date: Thu, 26 Feb 2009 12:10:56 +0100
- Delivered-to: firstname.lastname@example.org
- Thread-index: AcmX/rql+aX3jP9nRgueW/hvM5jfQgAAz7DA
- Thread-topic: [p2-dev] Provisioning p2 with p2?
Ciao Fredrik :)
A profile registry is maintaining a list of currently available profiles. You're right, the default is to look at it's own p2 directory for profiles, but the SimpleProfileRegistry can be given any directory containing Profiles, it will load things from there. So, you can fire up p2 admin, point it it the profile registry dir of another installation and administer the profiles as well. Is this what you're looking for? Not sure if there is UI for that use case but the code is all there...
From: p2-dev-bounces@xxxxxxxxxxx [mailto:p2-dev-bounces@xxxxxxxxxxx] On Behalf Of Fredrik Alströmer
Sent: Thursday, February 26, 2009 11:23 AM
To: P2 developer discussions
Subject: Re: [p2-dev] Provisioning p2 with p2?
Basically, what I want is for one p2 instance to convey information to the system being installed about what IUs have been installed and so on, so that it may update itself later on, when it's running. That's what I mean with autonomous. Currently, when I use the p2-agent to create a profile and install a product, the profile description ends up in the profile registry of the agent, not in the directory created of the created profile...
Given that this appears to be what is done with the eclipse sdk, it should work. My second question was, is it possible to, with an external p2 instance like the p2-agent, tap into this self contained system and manage it (assuming it's not running of course)? This is obviously true, I just need to make sure the p2-agent works with the profile available in the installed system, rather than in its own registry, the question is, how do I get the profile in there?
On Thu, Feb 26, 2009 at 10:52, Haigermoser, Helmut <Helmut.Haigermoser@xxxxxxxxxxxxx> wrote:
> Ciao Frederik :)
> Profiles can be "roaming", i.e. installable anywhere you want them to. Does that fit your definition of "autonomous"?
> What happens under the hood is at first launch the profile will look at itself and it's current install dir and modify itself to fit the new place. That's how eclipse SDK manages to be distributable by zip and yet come with a complete profile...
> Ciao, hh
> -----Original Message-----
> From: p2-dev-bounces@xxxxxxxxxxx [mailto:p2-dev-bounces@xxxxxxxxxxx]
> On Behalf Of Fredrik Alströmer
> Sent: Thursday, February 26, 2009 10:46 AM
> To: P2 developer discussions
> Subject: Re: [p2-dev] Provisioning p2 with p2?
> This is where I get lost, I understand that this might very well be the case (I found the profile registry in the p2 agent, which I'm using), but how would I go about to 'zip-up' my profile, which is done with the eclipse SDK as John described, and ship it off to somewhere else? Point being, I want my profile to be autonomous.
> If I'm able to achieve this, would I still be able to use a second p2 agent to manage the now 'autonomous' system, as long as it's offline, or are these set-ups mutually exclusive (i.e. is an externally manageable autonomous system a contradiction in terms)?
> On Thu, Feb 26, 2009 at 00:16, Henrik Lindberg <henrik.lindberg@xxxxxxxxxxxxxx> wrote:
>> The profiles are stored in a ProfileRegistry - and the implementation
>> used in p2 stores the profiles under "engine". Snoop around under the "p2"
>> directory in your stand alone Eclipse SDK installation, or under
>> user.home/.p2 if you tried a SharedInstall.
>> Henrik Lindberg
>> On Feb 25, 2009, at 4:47 PM, Fredrik Alströmer wrote:
>>> Excellent, that's what I wanted to hear... Now I only need to figure
>>> out how to do this... ;)
>>> For the second part, that's what I meant, I was just curious whether
>>> an external p2 system (which is creating the profile) is actually
>>> able to convey information to the profile about IUs being installed
>>> and so on. I wasn't able to find a meta data repository (i.e. a
>>> description of the installed IUs) - only an artifact repository - in
>>> the profile I installed into, how does the p2 instance within the
>>> created profile know what it contains? Or does it simply backtrack
>>> and look for matching IUs to the artifacts?
>>> Or am I simply missing some magic here? :)
>>> On Wed, Feb 25, 2009 at 15:01, John Arthorne
>>>> Absolutely, p2 can and does do that. In fact our Eclipse project
>>>> builds run exactly in this way - p2 ant tasks are used to create a
>>>> profile, into which the platform or Eclipse SDK is provisioned. The
>>>> result is then zipped up and delivered on our downloads page. Also,
>>>> once you have installed the platform (which includes p2), p2 will
>>>> manage and be able to upgrade that (including itself). p2 can
>>>> manage a system that is not currently running, or it can manage a
>>>> system that it is currently running inside of.
>>>> What you read about who touches what might have been taken out of
>>>> What that means is that if the user unzips stuff manually into
>>>> eclipse/plugins or eclipse/dropins, then it is the user's
>>>> responsibility to "manage" those plugins manually at the file
>>>> system level (upgrade it, remove it, etc). p2 won't touch them.
>>>> Things that have been provisioned into eclipse/plugins or elsewhere
>>>> by p2 via the user interface or command line tools shouldn't be
>>>> manually edited/removed at the file system level by the end user
>>>> (just like you don't manually move/delete DLL's from Windows apps
>>>> and expect them to continue working).
>>>> Fredrik Alströmer <roe@xxxxxxx>
>>>> Sent by: p2-dev-bounces@xxxxxxxxxxx
>>>> 02/25/2009 08:38 AM
>>>> Please respond to
>>>> P2 developer discussions <p2-dev@xxxxxxxxxxx> To p2-dev@xxxxxxxxxxx
>>>> cc Subject [p2-dev] Provisioning p2 with p2?
>>>> I think I read somewhere that, whatever is managed by p2 you
>>>> shouldn't touch, and whatever you manage p2 won't touch. This makes
>>>> perfect sense, however there's one thing that's not completely
>>>> clear to me. Is it one of the purposes of p2 to be able to create a
>>>> new profile (using p2, that is, like with the p2 agent), install p2
>>>> into that profile, and then let it manage itself?
>>>> p2-dev mailing list
>>>> p2-dev mailing list
>>> p2-dev mailing list
>> p2-dev mailing list
> p2-dev mailing list
> p2-dev mailing list
p2-dev mailing list