[
https://issues.apache.org/jira/browse/DERBY-6828?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15150573#comment-15150573
]
ASF subversion and git services commented on DERBY-6828:
--------------------------------------------------------
Commit 1730839 from [~bryanpendleton] in branch 'code/trunk'
[ https://svn.apache.org/r1730839 ]
DERBY-6828: Network Server fails to start in Czech locale.
This change modifies the drda message properties filename so that it
works more elegantly with the LocalizedResource utility class, and with
the underlying JDK ResourceBundle class on which it is based.
If your locale is cs_CZ, ResourceBundle will look for the message in
messages_cs_CZ.properties. If it is not found there, it will try
with a less specific locale and look for it in messages_cs.properties.
If it is not found there either, it will try with an even less specific
locale and look for it in messages.properties. If we move the English
messages from messages_en.properties to messages.properties, they will
become fallback for messages that lack translation to the requested locale.
The tools messages are already structured like this. There is a
toolsmessages.properties, but not a toolsmessages_en.properties.
The engine messages don't go through LocalizedResource; they have a
different mechanism for falling back to English (using MessageService).
It would be best if we had a single approach for Derby message property
files. However, messages processed by MessageService use a different
naming convention than messages processed by LocalizedResource, so for
the time being it seems the best approach is to rename the drda messages
to follow the LocalizedResource naming convention.
> Network Server don't start in czech localized enviroment due missing key
> DRDA_MissingNetworkJar.S
> -------------------------------------------------------------------------------------------------
>
> Key: DERBY-6828
> URL: https://issues.apache.org/jira/browse/DERBY-6828
> Project: Derby
> Issue Type: Bug
> Components: Localization, Network Server
> Affects Versions: 10.11.1.1
> Environment: Windows 7 Profesional SP1 64bit (localized CS),
> java version "1.8.0_51"
> Java(TM) SE Runtime Environment (build 1.8.0_51-b16)
> Java HotSpot(TM) 64-Bit Server VM (build 25.51-b03, mixed mode)
> Reporter: David Ježek
> Priority: Minor
> Labels: easyfix
> Attachments: nullGuard.diff
>
>
> Network Server don't start in czech localized enviroment due missing key
> DRDA_MissingNetworkJar.S in file
> org/apache/derby/loc/drda/messages_cs.properties
> Exception:
> Thu Jul 23 15:56:24 CEST 2015 : null
> java.lang.NullPointerException
> at
> org.apache.derby.iapi.tools.i18n.LocalizedResource.getTextMessage(Unknown
> Source)
> at
> org.apache.derby.impl.drda.NetworkServerControlImpl.localizeMessage(Unknown
> Source)
> at
> org.apache.derby.impl.drda.NetworkServerControlImpl.localizeMessage(Unknown
> Source)
> at
> org.apache.derby.drda.NetworkServerControl.installSecurityManager(Unknown
> Source)
> at org.apache.derby.drda.NetworkServerControl.main(Unknown Source)
> Missing key is called in file org.apache.derby.drda.NetworkServerControl.java
> at line 818.
> Reproduce under windows in console run:
> set DERBY_OPTS=-Duser.language=cs
> startNetworkServer.bat
> Workaround:
> Run derby server under en localization.
> Windows consola run:
> set DERBY_OPTS=-Duser.language=en
> startNetworkServer.bat
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)