Search code examples
javainternationalizationpootleweblate

What is your recommended tool suite for internationalization of a complex multi-module java application?


I am currently doing an intership in a company and my task is to reevaluate the tool suite used to translate applications as it has become a problem internally. I've looked everywhere on the web and my conclusion is there is just no proper documented end to end workflow for this type of task, so I am asking the community to help me understand what they have seen in the field.

Our current flow looks like this:

  • java, properties files and resource bundles in the code

  • custom made tool to extract keys from code based on classes. bit clunky, as it uses class loading and therefore has many practical constraints

  • custom made web tool to do translations and handle code revisions

Here are some constraints and improvements we're looking towards:

  • we'd like for external translators to help us for additional languages our company cannot handle

  • we would like to add metadata to translation keys, such as validation flags, categorization data and description data, something not handled by properties files

  • we're going to have external translators and would wish to be able to use standards where possible to properly integrate with their tools

Here's what I've found on the web:

  • GNU Gettext's plural handling and context messages are nice. However, our existing code is written using keys and would not work with writing plain english messages in the code.

  • XLIFF provides means to have all the extra metadata we would like to add. However, all existing tools are either incomplete, buggy, or costly. Many of the tools add their own metadata which complicates working with XLIFF.

  • Pootle pretty much does what our custom made web tool does except fails to work on multiple Git branches.

  • Weblate, which is similar to Pootle, has the ability to work on multiple Git branches. However, updating a project with many languages and many translations takes time. It fails to meet our needs of continuous development.

So what is your recommended tool suite for internationalization of a complex multi-module java application?


Solution

  • Gettext (.po) is possible by a two stage key: key -> English, English as key. Disambiguation can be done with the original key. The original key can be preserved.

    Gettext seems to be more extensively used than XLIFF - but I may be wrong meanwhile.

    Web interfaces are fine - as a secondary tool. Translation agencies will complain when offered such a thing.

    I cannot stress sufficiently that the delivery of the text is very important, to prevent that every translator has to do extra work. Almost the same text that might be united is such an example. A Translation Memory might give a fuzzy translation, but it is better to do processing by someone dedicated, before delivering things to translate. Also things like "Select from the menu 'Process thumbleweed'" and "Process thumbleweed" could well need a translation responsible person, to have coherent translations. XLIFF might offer more technicalities, but in general I think it is best to let an experienced developer ensure, develop this process. A common glossary of specific terms.

    Also being able to have the application switch between showing a specific language and the key "[key]".