{"action":"created","issue":{"url":"https://api.github.com/repos/jenkinsci/build-flow-plugin/issues/58","labels_url":"https://api.github.com/repos/jenkinsci/build-flow-plugin/issues/58/labels{/name}","comments_url":"https://api.github.com/repos/jenkinsci/build-flow-plugin/issues/58/comments","events_url":"https://api.github.com/repos/jenkinsci/build-flow-plugin/issues/58/events","html_url":"https://github.com/jenkinsci/build-flow-plugin/pull/58","id":95779734,"number":58,"title":"Add ability do create build asynchronously and then wait for it when …","user":{"login":"J-cztery","id":4555794,"avatar_url":"https://avatars.githubusercontent.com/u/4555794?v=3","gravatar_id":"","url":"https://api.github.com/users/J-cztery","html_url":"https://github.com/J-cztery","followers_url":"https://api.github.com/users/J-cztery/followers","following_url":"https://api.github.com/users/J-cztery/following{/other_user}","gists_url":"https://api.github.com/users/J-cztery/gists{/gist_id}","starred_url":"https://api.github.com/users/J-cztery/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/J-cztery/subscriptions","organizations_url":"https://api.github.com/users/J-cztery/orgs","repos_url":"https://api.github.com/users/J-cztery/repos","events_url":"https://api.github.com/users/J-cztery/events{/privacy}","received_events_url":"https://api.github.com/users/J-cztery/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-07-18T02:29:55Z","updated_at":"2015-07-27T16:52:14Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/jenkinsci/build-flow-plugin/pulls/58","html_url":"https://github.com/jenkinsci/build-flow-plugin/pull/58","diff_url":"https://github.com/jenkinsci/build-flow-plugin/pull/58.diff","patch_url":"https://github.com/jenkinsci/build-flow-plugin/pull/58.patch"},"body":"…needed. This will allow to build multiple parallel blocks with common dependency as below (Windows, OSX and Linux all include android builds but they can build their respective dependencies and then wait for android to complete before building final installers):\r\n\r\ndef allParams = new HashMap(params)\r\ndef buildLinux \t\t\t= \tbuildAsync(allParams,\"LINUX\")\r\ndef buildVC120\t\t\t= \tbuildAsync(allParams,\"WINDOWS_VC120\")\r\ndef buildAndroid \t\t= \tbuildAsync(allParams,\"Android\")\r\ndef buildOSX \t\t\t= \tbuildAsync(allParams,\"OSX\")\r\ndef buildiOS \t\t\t= \tbuildAsync(allParams,\"iOS\")\r\n\r\nparallel (\r\n   {\r\n     ignore(FAILURE){\r\n\t \tprintln(\"Building OS X installer\")\r\n     \t        waitForAsyncBuild(buildOSX)\r\n\t \twaitForAsyncBuild(buildAndroid)\r\n \t \twaitForAsyncBuild(buildiOS)\r\n\r\n     \tbuild(allParams,\"MacOSXInstaller\")\r\n     }\r\n   },\r\n   {\r\n     ignore(FAILURE){\r\n     \tprintln(\"Building Linux installer\")\r\n     \twaitForAsyncBuild(buildLinux)\r\n     \twaitForAsyncBuild(buildAndroid)\r\n     \tbuild(allParams, \"LinuxInstaller\")\r\n     }\r\n   },\r\n   {\r\n     ignore(FAILURE){\r\n     \tprintln(\"Building Windows installer\")\r\n\r\n     \twaitForAsyncBuild(buildVC120)\r\n     \twaitForAsyncBuild(buildAndroid)\r\n     \tbuild(allParams,\"WindowsInstaller\")\r\n     }\r\n   }\r\n)"},"comment":{"url":"https://api.github.com/repos/jenkinsci/build-flow-plugin/issues/comments/125270186","html_url":"https://github.com/jenkinsci/build-flow-plugin/pull/58#issuecomment-125270186","issue_url":"https://api.github.com/repos/jenkinsci/build-flow-plugin/issues/58","id":125270186,"user":{"login":"marcingrzejszczak","id":3297437,"avatar_url":"https://avatars.githubusercontent.com/u/3297437?v=3","gravatar_id":"","url":"https://api.github.com/users/marcingrzejszczak","html_url":"https://github.com/marcingrzejszczak","followers_url":"https://api.github.com/users/marcingrzejszczak/followers","following_url":"https://api.github.com/users/marcingrzejszczak/following{/other_user}","gists_url":"https://api.github.com/users/marcingrzejszczak/gists{/gist_id}","starred_url":"https://api.github.com/users/marcingrzejszczak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marcingrzejszczak/subscriptions","organizations_url":"https://api.github.com/users/marcingrzejszczak/orgs","repos_url":"https://api.github.com/users/marcingrzejszczak/repos","events_url":"https://api.github.com/users/marcingrzejszczak/events{/privacy}","received_events_url":"https://api.github.com/users/marcingrzejszczak/received_events","type":"User","site_admin":false},"created_at":"2015-07-27T16:52:14Z","updated_at":"2015-07-27T16:52:14Z","body":"Hi! @J-cztery - can you tell me how did you manage to build the plugin locally? I've tried \r\n\r\n`mvn clean install`\r\n\r\nthen I checked how it's built on Jenkins during PRs and I've tried\r\n\r\n`mvn clean install -e -U -Dignore.random.failures`\r\n\r\nstill nothing. Nothing means I have plenty of failed tests with exceptions like\r\n\r\n```\r\nRunning com.cloudbees.plugins.flow.UpstreamTest\r\nJul 27, 2015 6:30:30 PM hudson.triggers.SafeTimerTask run\r\nSEVERE: Timer task hudson.triggers.Trigger$2@176e99 failed\r\njava.lang.NoClassDefFoundError: Could not initialize class hudson.model.ComputerSet\r\n\tat hudson.triggers.Trigger$2.doRun(Trigger.java:305)\r\n\tat hudson.triggers.SafeTimerTask.run(SafeTimerTask.java:54)\r\n\tat java.util.TimerThread.mainLoop(Timer.java:555)\r\n\tat java.util.TimerThread.run(Timer.java:505)\r\n\r\nJul 27, 2015 6:30:30 PM org.mortbay.log.Slf4jLog info\r\nINFO: jetty-6.1.26\r\nJul 27, 2015 6:30:30 PM org.mortbay.log.Slf4jLog info\r\nINFO: NO JSP Support for , did not find org.apache.jasper.servlet.JspServlet\r\nJul 27, 2015 6:30:30 PM org.mortbay.log.Slf4jLog info\r\nINFO: Started SocketConnector@0.0.0.0:57790\r\nJul 27, 2015 6:30:30 PM jenkins.InitReactorRunner$1 onAttained\r\nINFO: Started initialization\r\nJul 27, 2015 6:30:30 PM jenkins.InitReactorRunner$1 onAttained\r\nINFO: Listed all plugins\r\nJul 27, 2015 6:30:30 PM jenkins.InitReactorRunner$1 onAttained\r\nINFO: Prepared all plugins\r\nJul 27, 2015 6:30:30 PM jenkins.InitReactorRunner$1 onAttained\r\nINFO: Started all plugins\r\nJul 27, 2015 6:30:30 PM jenkins.InitReactorRunner$1 onAttained\r\nINFO: Augmented all extensions\r\nJul 27, 2015 6:30:30 PM jenkins.InitReactorRunner$1 onAttained\r\nINFO: Loaded all jobs\r\nJul 27, 2015 6:30:31 PM jenkins.InitReactorRunner$1 onAttained\r\nINFO: Completed initialization\r\nJul 27, 2015 6:30:31 PM hudson.triggers.SafeTimerTask run\r\nSEVERE: Timer task hudson.model.LoadStatistics$LoadStatisticsUpdater@3f008ed3 failed\r\njava.lang.NoClassDefFoundError: Could not initialize class hudson.model.ComputerSet\r\n\tat hudson.model.OverallLoadStatistics.computeTotalExecutors(OverallLoadStatistics.java:63)\r\n\tat hudson.model.LoadStatistics.updateExecutorCounts(LoadStatistics.java:188)\r\n\tat hudson.model.LoadStatistics$LoadStatisticsUpdater.doRun(LoadStatistics.java:226)\r\n\tat hudson.triggers.SafeTimerTask.run(SafeTimerTask.java:54)\r\n\tat java.util.TimerThread.mainLoop(Timer.java:555)\r\n\tat java.util.TimerThread.run(Timer.java:505)\r\n\r\nJul 27, 2015 6:30:31 PM hudson.TcpSlaveAgentListener <init>\r\nINFO: JNLP slave agent listener started on TCP port 37366\r\nTests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.414 sec <<< FAILURE!\r\n```\r\n\r\nand the overall list is:\r\n\r\n```\r\nTests in error: \r\n  testIgnoreJobUnstableButFailureFailure(com.cloudbees.plugins.flow.IgnoreTest): -1\r\n  testIgnoreJobUnstable(com.cloudbees.plugins.flow.IgnoreTest): second instance\r\n  testIgnoreJobFailure(com.cloudbees.plugins.flow.IgnoreTest): -1\r\n  testUseExtension(com.cloudbees.plugins.flow.BuildFlowDSLExtensionTest): second instance\r\n  testImportStatement(com.cloudbees.plugins.flow.BuildTest): -1\r\n  testBuildWithParams(com.cloudbees.plugins.flow.BuildTest): second instance\r\n  testSequentialBuildsWithFailure(com.cloudbees.plugins.flow.BuildTest): -1\r\n  testSequentialBuilds(com.cloudbees.plugins.flow.BuildTest): second instance\r\n  testUnknownJob(com.cloudbees.plugins.flow.BuildTest): -1\r\n  testDisabledJob(com.cloudbees.plugins.flow.BuildTest): second instance\r\n  testJobFailure(com.cloudbees.plugins.flow.BuildTest): -1\r\n  testJobUnstable(com.cloudbees.plugins.flow.BuildTest): second instance\r\n  testBuildWithParamsAsMap(com.cloudbees.plugins.flow.BuildTest): -1\r\n  testSingleBuild(com.cloudbees.plugins.flow.BuildTest): second instance\r\n  testParametersFromBuild(com.cloudbees.plugins.flow.BuildTest): -1\r\n  testParametersFromBuildWithDefaultValues(com.cloudbees.plugins.flow.BuildTest): second instance\r\n  testGuardPass(com.cloudbees.plugins.flow.GuardTest): -1\r\n  testConcurrencyWithNonConcurrentDownstream(com.cloudbees.plugins.flow.ConcurrencyTest): second instance\r\n  testConcurrency(com.cloudbees.plugins.flow.ConcurrencyTest): -1\r\n  testRetryGuard(com.cloudbees.plugins.flow.RetryTest): second instance\r\n  testRetry(com.cloudbees.plugins.flow.RetryTest): -1\r\n  testRetryThenSuccess(com.cloudbees.plugins.flow.RetryTest): second instance\r\n  testNoRetryUnstable(com.cloudbees.plugins.flow.RetryTest): -1\r\n  testNoQuotesNotation(com.cloudbees.plugins.flow.RetryTest): second instance\r\n  testNoRetry(com.cloudbees.plugins.flow.RetryTest): -1\r\n  testBuiltinImports(com.cloudbees.plugins.flow.BindingTest): second instance\r\n  testEnvBinding(com.cloudbees.plugins.flow.BindingTest): -1\r\n  testBindings(com.cloudbees.plugins.flow.BindingTest): second instance\r\n  testThatAbortAbortsStartedJobs(com.cloudbees.plugins.flow.AbortTest): -1\r\n  testGuardWithParallel(com.cloudbees.plugins.flow.CombinationTest): second instance\r\n  testParallelSubFlows(com.cloudbees.plugins.flow.CombinationTest): -1\r\n  testRetryWithGuard(com.cloudbees.plugins.flow.CombinationTest): second instance\r\n  Flow cause not blocking the upstream causes(com.cloudbees.plugins.flow.FlowCauseTest): -1\r\n  testFailOnParallelFailed(com.cloudbees.plugins.flow.ParallelTest): second instance\r\n  testParallelMap(com.cloudbees.plugins.flow.ParallelTest): -1\r\n  testFailOnJobSequenceFailed(com.cloudbees.plugins.flow.ParallelTest): second instance\r\n  testGetParallelResults(com.cloudbees.plugins.flow.ParallelTest): -1\r\n  testParallel(com.cloudbees.plugins.flow.ParallelTest): second instance\r\n  testUpstream(com.cloudbees.plugins.flow.UpstreamTest): -1\r\n  org.jvnet.hudson.test.JellyTestSuiteBuilder$JellyTestSuite(org.jvnet.hudson.test.junit.FailedTest): second instance\r\n  testCliSanity(org.jvnet.hudson.test.PluginAutomaticTestBuilder$CliSanityTest): -1\r\n\r\n```"}}