{"action":"created","issue":{"url":"https://api.github.com/repos/spring-gradle-plugins/dependency-management-plugin/issues/40","labels_url":"https://api.github.com/repos/spring-gradle-plugins/dependency-management-plugin/issues/40/labels{/name}","comments_url":"https://api.github.com/repos/spring-gradle-plugins/dependency-management-plugin/issues/40/comments","events_url":"https://api.github.com/repos/spring-gradle-plugins/dependency-management-plugin/issues/40/events","html_url":"https://github.com/spring-gradle-plugins/dependency-management-plugin/issues/40","id":59583611,"number":40,"title":"Populate bom properties before dependency resolution","user":{"login":"pearj","id":237821,"avatar_url":"https://avatars.githubusercontent.com/u/237821?v=3","gravatar_id":"","url":"https://api.github.com/users/pearj","html_url":"https://github.com/pearj","followers_url":"https://api.github.com/users/pearj/followers","following_url":"https://api.github.com/users/pearj/following{/other_user}","gists_url":"https://api.github.com/users/pearj/gists{/gist_id}","starred_url":"https://api.github.com/users/pearj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pearj/subscriptions","organizations_url":"https://api.github.com/users/pearj/orgs","repos_url":"https://api.github.com/users/pearj/repos","events_url":"https://api.github.com/users/pearj/events{/privacy}","received_events_url":"https://api.github.com/users/pearj/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/spring-gradle-plugins/dependency-management-plugin/labels/invalid","name":"invalid","color":"e6e6e6"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-03-03T01:56:52Z","updated_at":"2015-03-03T11:27:46Z","closed_at":"2015-03-03T09:29:47Z","body":"I would like to use the properties from a [JBoss BOM](https://maven.repository.redhat.com/techpreview/all/org/jboss/bom/eap/jboss-eap-bom-parent/6.3.3.GA/jboss-eap-bom-parent-6.3.3.GA.pom) file, however the they don't seem to be populated by the time that gradle resolves dependencies.\r\n\r\nFor example I have tried\r\n\r\n    testCompile \"org.jboss.arquillian.testng:arquillian-testng-container:\" + ext['version.org.jboss.arquillian']\r\n\r\nBut it failed with\r\n\r\n    FAILURE: Build failed with an exception.\r\n\r\n    * Where:\r\n    Script '/home/japearson/dev/project/main/arquillian-testable.gradle' line: 35\r\n\r\n    * What went wrong:\r\n    A problem occurred evaluating script.\r\n    > Cannot get property 'version.org.jboss.arquillian' on extra properties extension as it does not exist\r\n\r\n    * Try:\r\n    Run with --stacktrace option to get the stack trace. Run with --debug option to get more log output.\r\n\r\n    BUILD FAILED\r\n\r\nI have tried to use this plugin to resolve the dependencies automatically, however it causes build issues for my project such as:\r\n\r\n    * What went wrong:\r\n    Execution failed for task ':project-analytics:ejb-jar:dependencyInsight'.\r\n    > Could not resolve all dependencies for configuration ':project-analytics:ejb-jar:jbossasRemoteTestRuntimeCopy'.\r\n       > Module version main.project-analytics:ejb-jar:unspecified, configuration 'jbossasRemoteTestRuntimeCopy' declares a dependency on configuration 'core' which is not declared in the module descriptor for main.project-analytics:ejb-jar:unspecified\r\n\r\nHowever, when I specify versions manually it works properly ie ```testCompile \"org.jboss.arquillian.testng:arquillian-testng-container:1.1.0.Final\"```"},"comment":{"url":"https://api.github.com/repos/spring-gradle-plugins/dependency-management-plugin/issues/comments/76929025","html_url":"https://github.com/spring-gradle-plugins/dependency-management-plugin/issues/40#issuecomment-76929025","issue_url":"https://api.github.com/repos/spring-gradle-plugins/dependency-management-plugin/issues/40","id":76929025,"user":{"login":"pearj","id":237821,"avatar_url":"https://avatars.githubusercontent.com/u/237821?v=3","gravatar_id":"","url":"https://api.github.com/users/pearj","html_url":"https://github.com/pearj","followers_url":"https://api.github.com/users/pearj/followers","following_url":"https://api.github.com/users/pearj/following{/other_user}","gists_url":"https://api.github.com/users/pearj/gists{/gist_id}","starred_url":"https://api.github.com/users/pearj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pearj/subscriptions","organizations_url":"https://api.github.com/users/pearj/orgs","repos_url":"https://api.github.com/users/pearj/repos","events_url":"https://api.github.com/users/pearj/events{/privacy}","received_events_url":"https://api.github.com/users/pearj/received_events","type":"User","site_admin":false},"created_at":"2015-03-03T11:27:46Z","updated_at":"2015-03-03T11:27:46Z","body":"I did try something like:\r\n\r\n\tdependencies {\r\n\t\ttestCompile \"org.jboss.arquillian.testng:arquillian-testng-container\"\r\n\t}\r\n\r\nHowever it worked for some subprojects and not others, by simply applying the plugin to some of the subprojects it fails with:\r\n\r\n\t* What went wrong:\r\n\tExecution failed for task ':project-analytics:ejb-jar:dependencyInsight'.\r\n\t> Could not resolve all dependencies for configuration ':project-analytics:ejb-jar:jbossasRemoteTestRuntimeCopy'.\r\n\t   > Module version main.project-analytics:ejb-jar:unspecified, configuration 'jbossasRemoteTestRuntimeCopy' declares a dependency on configuration 'core' which is not declared in the module descriptor for main.project-analytics:ejb-jar:unspecified\r\n\r\nSo ```dependencyManagement.importedProperties['version.org.jboss.arquillian']``` is a nice workaround where the plugin causes havock on particular subprojects."}}