Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [p2-dev] self profile

Our installer has capability to update itself, so we need check the
updates in online repository based on the profile of installer itself.
The simplest way to obtain the profile of installer itself is
getProfile(SELF), it also avoids to write hard code.
Meanwhile, we also contribute customized profile registry, no longer use
the default directory to store profile. So latest profile implementation
won't read self profile id from the system property unless the store
location of profile is the default one. It breaks our original way to
get profile of installer itself. So I wonder whether any bug push this
changes. If it exists, could you tell me the number? I can refer to it.
Personally, I think 'SELF' is a simple way to obtain the profile of
installer(or other p2 installations you want to maintain), and it's easy
to be configured via configuration files.

-- 
Best Regards,
Meng Xin(Kane)


On Tue, 2010-02-02 at 10:48 -0500, John Arthorne wrote:
> 
> Yes, the concept of "self" is limiting and most of the p2 code doesn't
> use "self" as far as I know (with some exceptions in UI, console, and
> automated tests). Is there a particular place where self is being used
> that is causing problems for you, or are you suggesting that we get
> rid of the concept completely? 
> 
> 
> 
> Meng Xin Zhu
> <kane.zhu@xxxxxxxxxxxxx> 
> Sent by:
> p2-dev-bounces@xxxxxxxxxxx 
> 
> 02/02/2010 04:42 AM 
>          Please respond to
>      P2 developer discussions
>        <p2-dev@xxxxxxxxxxx>
> 
> 
> 
> 
>                To
> P2 developer
> discussions
> <p2-dev@xxxxxxxxxxx> 
>                cc
> 
>           Subject
> [p2-dev] self
> profile
> 
> 
> 
> 
> 
> 
> 
> 
> Hi dev,
> 
> The algorithm of finding self profile has a bit changes. It considers
> it's the running system when store equals the default registry
> location. 
> But we change the default registry directory via contributing the
> profile registry, and specify the profile of running system(installer)
> via system property "eclipse.p2.profile".
> The new changes take away the benefit of
> getProfile(IProfileRegistry.SELF). Is there any bug opened for
> reporting
> it? Might there is some requirements need it.
> 
>                                  if
> (store.equals(getDefaultRegistryDirectory(location))) {
>                                                   //we are the
> registry for the currently running system
>                                                   self =
> EngineActivator.getContext().getProperty("eclipse.p2.profile"); //$NON-NLS-1$
>                                  }
> 
> -- 
> Best Regards,
> Meng Xin(Kane)
> 
> 
> _______________________________________________
> p2-dev mailing list
> p2-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/p2-dev
> 
> _______________________________________________
> p2-dev mailing list
> p2-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/p2-dev


Back to the top