title: SonarQube Ant task, failed to download the file
body: <p>I am running a simple Ant script for SonarQube and have the following error:</p>
  
  <blockquote>
    <p>FileNotFoundException: C:\Users\c5187668\sap\simpleAnt.sonar\batch\sonar-batch-maven-compat-5.1.2.jar|99845a2f47eaef85b29978725f82c50c"</p>
  </blockquote>
  
  <ul>
  <li>SonarQube Server Version 5.1.2</li>
  <li>Apache Ant(TM) version 1.9.6 compiled on June 29 2015</li>
  <li>Sonar Ant Task version: 2.0</li>
  <li>Java 1.6 - so, we cannot use modern version of Sonar Ant.</li>
  </ul>
  
  <p>Can it be fixed somehow? Any ideas?</p>
  
  <p>The Ant script:</p>
  
  <pre><code>&lt;project name="sonar build" default="Sonar" basedir="." xmlns:sonar="antlib:org.sonar.ant"&gt;
  
  &lt;taskdef uri="antlib:org.sonar.ant" resource="org/sonar/ant/antlib.xml"&gt;
      &lt;classpath path="sonar-ant-task.jar"/&gt;
  &lt;/taskdef&gt;
  &lt;!-- Out-of-the-box those parameters are optional --&gt;
  &lt;property name="sonar.jdbc.url" value="dbc:mysql://?????:3306/sonardb?useUnicode=true;characterEncoding=utf8" /&gt;
  &lt;property name="sonar.jdbc.driverClassName" value="com.mysql.jdbc.Driver" /&gt;
  &lt;property name="sonar.jdbc.username" value="?????" /&gt;
  &lt;property name="sonar.jdbc.password" value="?????" /&gt;
  &lt;!-- Additional Sonar configuration (PMD need 1.5 when using annotations)--&gt;
  &lt;property name="sonar.java.source" value="1.6"/&gt;
  &lt;property name="sonar.java.target" value="1.6"/&gt;    
  &lt;property name="sonar.projectName" value="SonarBuild"/&gt;
  &lt;property name="sonar.projectVersion" value="2.0" /&gt;
  &lt;!-- SERVER ON A REMOTE HOST --&gt;
  &lt;property name="sonar.host.url" value="http://??????" /&gt;
  &lt;target name="Sonar"&gt;
      &lt;sonar:sonar /&gt;
  &lt;/target&gt;
  </code></pre>
  
  <p></p>
  
  <p>I got the following error:</p>
  
  <pre><code>BUILD FAILED C:\Users\c5187668\sap\simpleAnt\build.xml:17:
  java.lang.IllegalStateException: Fail to download libraries from
  server
          at org.sonar.runner.Bootstrapper.downloadBatchFiles(Bootstrapper.java:166)
          at org.sonar.runner.Bootstrapper.createClassLoader(Bootstrapper.java:89)
          at org.sonar.runner.Runner.createClassLoader(Runner.java:229)
          at org.sonar.runner.Runner.execute(Runner.java:151)
          at org.sonar.ant.SonarTask.launchAnalysis(SonarTask.java:93)
          at org.sonar.ant.SonarTask.execute(SonarTask.java:75)
          at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:293)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
          at java.lang.reflect.Method.invoke(Method.java:597)
          at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
          at org.apache.tools.ant.Task.perform(Task.java:348)
          at org.apache.tools.ant.Target.execute(Target.java:435)
          at org.apache.tools.ant.Target.performTasks(Target.java:456)
          at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1405)
          at org.apache.tools.ant.Project.executeTarget(Project.java:1376)
          at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
          at org.apache.tools.ant.Project.executeTargets(Project.java:1260)
          at org.apache.tools.ant.Main.runBuild(Main.java:853)
          at org.apache.tools.ant.Main.startAnt(Main.java:235)
          at org.apache.tools.ant.launch.Launcher.run(Launcher.java:285)
          at org.apache.tools.ant.launch.Launcher.main(Launcher.java:112) Caused
  by: java.lang.IllegalStateException: Fail to download the file:
  http://???????/batch/sonar-batch-maven-compat-5.1.2.jar|99845a2f47eaef85b29
  978725f82c50c
  
          at org.sonar.runner.Bootstrapper.remoteContentToFile(Bootstrapper.java:115)
          at org.sonar.runner.Bootstrapper.downloadBatchFiles(Bootstrapper.java:161)
          ... 22 more Caused by: java.io.FileNotFoundException: C:\Users\c5187668\sap\simpleAnt\.sonar\batch\sonar-batch-maven-compat-5.1.2.jar|99845a2f47eaef85b29978725f82c50c
  (The filename, directory name, or volume label syntax is incorrect)
          at java.io.FileOutputStream.open(Native Method)
          at java.io.FileOutputStream.&lt;init&gt;(FileOutputStream.java:194)
          at org.sonar.runner.Bootstrapper.remoteContentToFile(Bootstrapper.java:109)
          ... 23 more
  
  Total time: 0 seconds
  </code></pre>
  
  <p>P.S. by question marks ????? I hide real server name and credentials.</p>