WorldServer

From Lingoport Wiki
Revision as of 19:07, 19 November 2021 by Masnes (talk | contribs)
Jump to: navigation, search

Note: See also L10n Vendors - World Server


When choosing WorldServer as the L10n vendor in Jenkins, the config_l10n_vendor.properties file is created with the following configuration.

With the WorldServer integration, files to be translated are sent via the WorldServer API to a Workflow/Client; The translated files are returned via FTP.

The information that is needed to upload the files to be translated as well as retrieve translated files is:

#WORLDSERVER Attributes
## Worldserver attributes for import kit files
worldserver.in.host=
worldserver.in.location.path=
worldserver.in.password=
worldserver.in.port=22
#SSH, SSL or blank (for FTP)
worldserver.in.ftp.protocol=SSH
worldserver.in.username=
## ssl implicit flag. Set to 0 for explicit, set to 1 for implicit
worldserver.in.ssl.implicit=0

##Zip file name that contains the translated files needs to beone of the following options.
## Option #1 for zip file prefix - Default
worldserver.in.file.name.prefix=${groupname}.${projectname}.${kitversion}.${lrmlocale}
## Option #2 for zip file prefix
#worldserver.in.file.name.prefix=${groupname}.${projectname}.${kitversion}.${wslocale}
## Option #3 for zip file prefix
#worldserver.in.file.name.prefix=${groupname}.${projectname}.${kitversion}.${lrmlocale}.${wslocale}

## WorldServer attributes for send kit files
worldserver.out.url=
worldserver.out.user=
worldserver.out.password=
worldserver.client=
## Available tokens ${groupname},${projectname},${kitversion},${lrmlocale}, ${wslocale}
worldserver.out.project.name=${groupname}.${projectname}.${kitversion}.${lrmlocale}

WorldServer URL Endpoint

The worldserver.out.url needs to be configured with the proper URL endpoint for your WorldServer instance.

 java -jar lingoport-ws-cli.jar --test-connection --group-name <GROUP> -project-name <PROJECT>
 INFO 2019-04-25 10:33:58,638 com.lingoport.lrm.persistence.LrmConnectionFactory.buildSqlSessionFactory: Connect to database successful.
 INFO 2019-04-25 10:34:00,489 com.lingoport.ws.pipeline.stage.TestWorldserverConnectionStage.execute: Testing the Worldserver Connection
 [...]
 INFO 2019-04-25 10:34:03,953 com.lingoport.ws.pipeline.connection.TestConnectionPipelineContext.logIsDoneMessage: Connection to Worldserver was successful
Process completed successfully.

WorldServer Project Type Mapping

The config_ws_locale_projecttype_mapping.properties configuration file contains the mapping between a LRM target locale and the WorldServer project type. All LRM target locales must be represented in this configuration file.

WorldServer Locale Mapping

The config_ws_locale_mapping.properties configuration file contains the mapping between the LRM target locales and the unique WorldServer locale. The mappings must be unique!

All target locales must be represented in this configuration file.

The configuration file can exist at the project level and group levels. The configuration file also exists in the LRM install directory's <HOME>/lingoport/lrm-server-x.y/deploy/templates/dir_structure/group/config folder.

The configuration file can exist at the project level and group levels. The configuration file also exists in the LRM install directory's <HOME>/lingoport/lrm-server-x.y/deploy/templates/dir_structure/group/config folder. the files are mostly named with a two letters locale, like for instance messages_en.json, messages_fr.json, as opposed to a 'four letters' locale, like messages_en_EN.json or messages_fr_FR.json. See Chinese for a bit more on the subject.

To set up the mapping, determine for a group or a project how the locale is defined (2 letters, 4 letters, other) and put on the left side the locale indication on the files or the directories and on the right side the WS locales, to be checked against your WS instance.

In the following mapping example, the repository files are in the form message_fr.json. Example of config_ws_locale_mapping.properties :

en=000_English
es=002_Spanish
da=110_Danish
bg=112_Bulgarian
hr=119_Croatian
nl=120_Dutch
cs=121_Czech
et=124_Estonian
fi=130_Finnish
ka=131_Georgian
el=133_Greek
hu=135_Hungarian
fr=140_French
de=150_German
lv=153_Latvian
lt=156_Lithuanian
mk=158_Macedonian
mt=159_Maltese
it=160_Italian
pl=166_Polish
ro=171_Romanian
ru=173_Russian
sk=176_Slovak
sl=177_Slovenian
sv=180_Swedish
tr=186_Turkish
is=190_Icelandic
uk=192_Ukrainian
hy=201_Armenian
pt=059_Portuguese
km=258_Cambodian
zh=265_Chinese
zh_hans=266_Chinese (Simplified)
hi=294_Hindi
id=299_Indonesian
ja=300_Japanese
ko=320_Korean
lo=331_Laotian
mn=363_Mongolian
th=425_Thai
vi=435_Vietnamese
fj=858_Fijian
sm=890_Samoan
to=900_Tongan
ht=036_Haitian
ms=348_Malay
no=170_Norwegian
sq=101_Albanian
sr=202_Serbian (Cyrillic)
mg=654_Malagasy
sw=743_Swahili