Wrong fallback language

Cantor, Scott cantor.2 at osu.edu
Tue May 30 12:03:18 EDT 2017

> I'm trying to configure my IdP (version 3.3.1) to use the correct locale
> (translation). There should be three ways (scenarios) to set the locale:

Assuming you're going by Spring's documentation I'll take your word for it, but we have nothing special in the software for this and whatever Spring supports is the limit of what we will do. It has significant limitations in fact, IMHO, among them handling multiple language precedence (e.g. a client suppying multiple locales in its header).

> All these three scenarios are working if I you use a known locale, in my case
> "en", "de" or "zh". If I choose an unknown locale, e.g. "es", the login page will
> be displayed in German instead of English.
> My configuration looks like as follows:
> File "idp.properties":
> 	[...]
> 	idp.ui.fallbackLanguages=en

This actually isn't involved. That drives the behavior of the code that looks up logo and name information in metadata, it's entirely separate from Spring's message layer. That isn't obvious of course, it's understandable it would be confused with that.

I believe Spring would default to the "bare" message file. You should turn up logging there and see what it's doing I suspect, but I have certainly tested that much back during the original incorporation of the message code.

> (I've also renamed messages_en.properties to messages.properties without
> success)

I believe you'd have to, so my guess is you're mistaken about that. It will not just pick a language to use as a default as far as I'm aware. Perhaps you didn't restart afterwards.

Also, there's going to be a system/messages/messages.properties file that should get used anyway, so it shouldn't matter whether you actually create your own. But that is the default we provide, so don't rename it.

-- Scott

More information about the users mailing list