I'm using Spring's @DateTimeFormat annotation, with a custom pattern, on the field of an object which is passed in via an HTTP POST endpoint. The particular field is set on the front end UI with a javascript widget which always uses the 'en_us' locale. However, if the browser is set to a locale other than 'en_us' then the parsing of the date/time may fail on the backend because the @DateTimeFormat uses the browser (or HTTP header) locale instead of 'en_us'.
Is there anyway to force the DateTimeFormat annotation to use the 'en_us' locale?
I realize the DateTimeFormat is doing what makes sense by using the HTTP header locale. However, since I control the front end, and for the time being don't want to change the front end javascript widget, I'm wondering if there is a way to set the locale of DateTimeFormat.