Uploaded image for project: 'Spring Framework'
  1. Spring Framework
  2. SPR-15603

Spring WebFlux fails with 500 if Accept-Language is set to an empty string

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Complete
    • Affects Version/s: 5.0 RC1
    • Fix Version/s: 5.0 RC2
    • Component/s: Reactive, Web
    • Labels:
      None
    • Last commented by a User:
      true

      Description

      31.05.2017 20:45:06,914 ERROR [org.springframework.web.server.handler.ExceptionHandlingWebHandler] - Could not complete request
      java.lang.IllegalArgumentException: range=
      	at java.util.Locale$LanguageRange.<init>(Locale.java:2913) ~[?:1.8.0_131]
      	at sun.util.locale.LocaleMatcher.parse(LocaleMatcher.java:284) ~[?:1.8.0_131]
      	at java.util.Locale$LanguageRange.parse(Locale.java:3028) ~[?:1.8.0_131]
      	at org.springframework.http.HttpHeaders.getAcceptLanguage(HttpHeaders.java:471) ~[spring-web-5.0.0.M5.jar:5.0.0.M5]
      	at org.springframework.http.HttpHeaders.getAcceptLanguageAsLocale(HttpHeaders.java:492) ~[spring-web-5.0.0.M5.jar:5.0.0.M5]
      	at org.springframework.web.reactive.result.view.ViewResolutionResultHandler.lambda$handleResult$3(ViewResolutionResultHandler.java:214) ~[spring-webflux-5.0.0.M5.jar:5.0.0.M5]
      	at reactor.core.publisher.MonoThenMap$ThenMapMain.onNext(MonoThenMap.java:120) ~[reactor-core-3.0.7.RELEASE.jar:3.0.7.RELEASE]
      ...
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              rstoya05-aop Rossen Stoyanchev
              Reporter:
              blacklion Oleg Alexeyev
              Last updater:
              Spring Issues Spring Issues
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Days since last comment:
                3 years, 37 weeks ago