[jbosstools-issues] [JBoss JIRA] (JBIDE-17153) Provide a way to configure IDE properties remotely, supporting multiple product/project versions

Fred Bricon (JIRA) issues at jboss.org
Tue Apr 22 05:44:33 EDT 2014


    [ https://issues.jboss.org/browse/JBIDE-17153?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12962949#comment-12962949 ] 

Fred Bricon commented on JBIDE-17153:
-------------------------------------

More details on the implementation :

{quote}
New IPropertiesProvider and its implementation
(VersionPropertiesProvider) reading IDE -wide properties from remote
resource bundle.

Provides properties depending on the context (project/product) it's
invoked in and the version of the context. Context and version are defined
by the current VersionPropertiesProvider instance.

Competing implementations can be found in the extension registry
(com.jboss.devstudio.core.central provides one implementation). The
provider with the highest priority will take precedence globally.

Consumers are expected to use :

org.jboss.tools.foundation.core.properties.PropertiesHelper.getPropertiesProvider()

Key/Value pairs are expected to be stored using the
key|context|version=value format.

If an exact matching version is not found for the requested key, the
properties provider will try to fall back to parent versions.

The version is provided by a locally Maven-filtered file
(currentversion.properties)

So, for instance, if the key 'foo' is requested in a VersionPropertiesProvider
provided by JBDS 8.0.0.Beta2-123456-65432 then :

It will return bar if foo|devstudio|8.0.0.Beta2=bar is set.

If no matching key/version is defined, then foo|devstudio|8.0.0 would be queried,
then foo|devstudio|8.0,
then foo|devstudio|8,
then foo|devstudio,
then foo.
Properties are retrieved from a URI
(http://download.jboss.org/jbosstools/configuration/ide-config.properties
by default). This URI can be overridden using the
org.jboss.tools.foundation.core.config.properties.url VM argument. For
instance, to test a local properties file, the following argument needs to
be added to the JVM

-Dorg.jboss.tools.foundation.core.config.properties.url=file://path/to/resource.properties

Additionally, the org.jboss.tools.foundation.core.test plugin was turned into a
fragment, so we can test package visible methods.
{quote}
                
> Provide a way to configure IDE properties remotely, supporting multiple product/project versions
> ------------------------------------------------------------------------------------------------
>
>                 Key: JBIDE-17153
>                 URL: https://issues.jboss.org/browse/JBIDE-17153
>             Project: Tools (JBoss Tools)
>          Issue Type: Feature Request
>          Components: central, discovery
>    Affects Versions: 4.2.0.Beta1
>            Reporter: Fred Bricon
>            Assignee: Fred Bricon
>             Fix For: 4.2.0.Beta2
>
>
> Currently, discovery urls are defined at build time and require modifying eclipse.ini or jbdevstudio.ini for each release. This is often error prone / annoying.
> [~maxandersen] came up with the following idea :
> make all these URLs (and others if applicable) defined in one place, that we can update remotely.
> So a remote properties file would contain the urls per project/product and per version. 
> If we have foo|devstudio|8.0.0.Beta2=bar then : 
> * devstudio 8.0.0.Beta2-123456-65432 will get bar. 
> * If no matching key/version is defined, then we'd look for foo|devstudio|8.0.0
> * then foo|devstudio|8.0
> * then foo|devstudio|8 
> * then foo|devstudio 
> * then foo
> That solution allows us to fine tune discovery urls per version if needed and doesn't require users/QE to mess with *.ini to test each milestone.
> http://download.jboss.org/jbosstools/configuration/ide-config.properties would be the bundle resource master of all properties. 

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jbosstools-issues mailing list