Re: language and label edition regression in 2 =?UTF-8?Q?.1.7=20when=20having=20"_"=20??=

2020-10-28 Thread Francesco Chicchiriccò
On 28/10/20 10:22, te...@net-c.com wrote:
> HI all,
>
> in 2.1.7, language id having a "_" in their name (like "fr_CA") makes schemas 
> not editable and leads to an exception:
> In the same way, impossible to create a label for these languages.
>
> java.lang.ArrayIndexOutOfBoundsException: 2
> at org.apache.syncope.common.lib.to.SchemaTO.toLocale(SchemaTO.java:63)
> at 
> org.apache.syncope.client.console.panels.SchemaTypeWizardBuilder$Labels.lambda$new$0(SchemaTypeWizardBuilder.java:139)
> at java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
> at 
> org.apache.syncope.client.console.panels.SchemaTypeWizardBuilder$Labels.(SchemaTypeWizardBuilder.java:138
>  
>
> It works well in 2.1.6.
> When trying to add a label for these kind of language the REST payload looks 
> weird like:
>
> {"@class":"org.apache.syncope.common.lib.to.PlainSchemaTO","key":"test","anyTypeClass":null,"labels":{"*fr;CA*;":"test"},"type":"String","mandatoryCondition":"false","multivalue":false,"uniqueConstraint":false,"readonly":false,"conversionPattern":null,"validator":null,"enumerationValues":"","enumerationKeys":"","secretKey":null,"cipherAlgorithm":null,"mimeType":null}

Hi.
this is already captured as

https://issues.apache.org/jira/browse/SYNCOPE-1590

and fixed in 2.1.8-SNAPSHOT.

Regards.

-- 
Francesco Chicchiriccò

Tirasa - Open Source Excellence
http://www.tirasa.net/

Member at The Apache Software Foundation
Syncope, Cocoon, Olingo, CXF, OpenJPA, PonyMail
http://home.apache.org/~ilgrosso/



language and label edition regression in 2 =?UTF-8?Q?.1.7=20when=20having=20"_"=20??=

2020-10-28 Thread tempo
HI all,


in 2.1.7, language id having a "_" in their name (like "fr_CA") makes schemas 
not editable and leads to an exception:

In the same way, impossible to create a label for these languages.



java.lang.ArrayIndexOutOfBoundsException: 2
at org.apache.syncope.common.lib.to.SchemaTO.toLocale(SchemaTO.java:63)
at 
org.apache.syncope.client.console.panels.SchemaTypeWizardBuilder$Labels.lambda$new$0(SchemaTypeWizardBuilder.java:139)
at java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
at 
org.apache.syncope.client.console.panels.SchemaTypeWizardBuilder$Labels.(SchemaTypeWizardBuilder.java:138



It works well in 2.1.6.

When trying to add a label for these kind of language the REST payload looks 
weird like:



{"@class":"org.apache.syncope.common.lib.to.PlainSchemaTO","key":"test","anyTypeClass":null,"labels":{"fr;CA;":"test"},"type":"String","mandatoryCondition":"false","multivalue":false,"uniqueConstraint":false,"readonly":false,"conversionPattern":null,"validator":null,"enumerationValues":"","enumerationKeys":"","secretKey":null,"cipherAlgorithm":null,"mimeType":null}