title: URLDecoder: Incomplete trailing escape (%) pattern when upload using spring
body: <p>I have only one starter in my porject : </p>
  
  <pre class="lang-xml prettyprint-override"><code>        &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-webflux&lt;/artifactId&gt;
          &lt;/dependency&gt;
  </code></pre>
  
  <p>2.1.6-RELEASE  </p>
  
  <p>I try to upload file and use <code>MultipartFile</code> but not working.<br>
  The framework works like <code>urlencoded form</code> </p>
  
  <pre><code>    @PostMapping(value = "/image", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
      public Mono&lt;ResponseEntity&lt;List&lt;String&gt;&gt;&gt; searchByImage(@RequestParam("file") MultipartFile file) throws Exception {
          return Mono.just(ResponseEntity.ok(service.guess(file.getBytes())));
      }
  </code></pre>
  
  <p>and throws  </p>
  
  <pre><code>java.lang.IllegalArgumentException: URLDecoder: Incomplete trailing escape (%) pattern
      at java.base/java.net.URLDecoder.decode(URLDecoder.java:225) ~[na:na]
      at java.base/java.net.URLDecoder.decode(URLDecoder.java:142) ~[na:na]
      at org.springframework.http.codec.FormHttpMessageReader.parseFormData(FormHttpMessageReader.java:146) ~[spring-web-5.1.8.RELEASE.jar:5.1.8.RELEASE]
      at org.springframework.http.codec.FormHttpMessageReader.lambda$readMono$0(FormHttpMessageReader.java:113) ~[spring-web-5.1.8.RELEASE.jar:5.1.8.RELEASE]
      at reactor.core.publisher.FluxMapFuseable$MapFuseableSubscriber.onNext(FluxMapFuseable.java:107) ~[reactor-core-3.2.10.RELEASE.jar:3.2.10.RELEASE]
      at reactor.core.publisher.FluxContextStart$ContextStartSubscriber.onNext(FluxContextStart.java:103) ~[reactor-core-3.2.10.RELEASE.jar:3.2.10.RELEASE]
  </code></pre>
  
  <p>the error happens:  </p>
  
  <pre><code>    private MultiValueMap&lt;String, String&gt; parseFormData(Charset charset, String body) {
          String[] pairs = StringUtils.tokenizeToStringArray(body, "&amp;");
          MultiValueMap&lt;String, String&gt; result = new LinkedMultiValueMap&lt;&gt;(pairs.length);
          try {
              for (String pair : pairs) {
                  int idx = pair.indexOf('=');
                  if (idx == -1) {
                      result.add(URLDecoder.decode(pair, charset.name()), null);
                  }
                  else {
                      String name = URLDecoder.decode(pair.substring(0, idx),  charset.name());
                      String value = URLDecoder.decode(pair.substring(idx + 1), charset.name());
                      result.add(name, value);
                  }
              }
          }
  </code></pre>
  
  <p>I turn to use <code>FilePart</code> but get the same result...<br>
  Did I miss some configs? </p>