[jbosstools-issues] [JBoss JIRA] (JBIDE-14958) Defining runtimes using external file does not work

Rob Stryker (JIRA) jira-events at lists.jboss.org
Mon Jun 24 04:58:21 EDT 2013


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

Rob Stryker commented on JBIDE-14958:
-------------------------------------

I'll be adding a pre-stacks sysprop override as well as changing the sysprop that exists currently for stacks, in a backwards compatible manner. 

I'm not sure if this fits the needs of QE or not, but, it would allow QE to run tests while overriding zero, one, or both of the urls and test the results. 

We already have unit tests in existence that verify accurate stacks will be returned even when reading arbitrary urls via a subclass to StacksManager. 

Because of the nature of the code, though, there really is no way to do what I think QE wants to do. They can change the pre-stacks to either an near-empty stacks file or a stacks file with extra entries and they'll be able to test the effect on downloadRuntimes... but it would be a global change and would need to be tested in its own test plugin. There would be no way to adjust this JUST on an astools downloadRuntime scope without also changing the stacks read by central etc... 

Even if we gave StacksManager a constructor with the URL in it, this would still be impossible to test for several reasons. 

First, the first load of downloadRuntimes caches its result. So if you were to get downloadRuntimes,  then change the sysprop, then get again, it would not work. The result has been cached.  Second, the URL in StacksManager as read by the sysprop is *also* cached, and will not be read or changed again even if the sysprop changes. THis is intentional and by design. 

Third, even having a StacksManger created with a custom URL, it would be impossible to force ASTools to USE that custom stacksmanager, since currently ASTools DownloadRuntimeProvider uses the default urls from StacksManager. It would be possible to test in unit test, but I doubt it'd be possible to test in any meaningful UI way that they're requesting. 


                
> Defining runtimes using external file does not work
> ---------------------------------------------------
>
>                 Key: JBIDE-14958
>                 URL: https://issues.jboss.org/browse/JBIDE-14958
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: runtime-detection
>    Affects Versions: 4.1.0.Beta2
>            Reporter: Petr Suchý
>            Assignee: Rob Stryker
>              Labels: respin-a
>             Fix For: 4.1.0.CR1
>
>
> Runtimes cannot be defined through external XML file.
> Steps are described [here|https://issues.jboss.org/browse/JBIDE-11683?focusedCommentId=12702503&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-12702503].

--
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