Difference between revisions of "L10n Vendors"

From Lingoport Wiki
Jump to: navigation, search
(Supported L10n Vendors)
(Transmission Protocol Configuration)
Line 24: Line 24:
 
The default location of the config_l10n_vendor.properties file is at the group level.
 
The default location of the config_l10n_vendor.properties file is at the group level.
 
The default settings do not define a vendor so that an error will occur when prepping a kit, forcing the user to chose a vendor. The global L10n Vendor attributes are:
 
The default settings do not define a vendor so that an error will occur when prepping a kit, forcing the user to chose a vendor. The global L10n Vendor attributes are:
  +
*'''l10n.vendor=ftp''' - uncomment if using FTP/SFTP, the recommended approach
  +
 
*'''l10n.vendor=lingotek''' - uncomment if using Lingotek
 
*'''l10n.vendor=lingotek''' - uncomment if using Lingotek
 
*'''l10n.vendor=local''' - uncomment if storing the prep/translated files locally.
 
*'''l10n.vendor=local''' - uncomment if storing the prep/translated files locally.
 
*'''l10n.vendor=worldserver''' - uncomment if using Worldserver
 
*'''l10n.vendor=worldserver''' - uncomment if using Worldserver
*'''l10n.vendor=ftp''' - uncomment if using FTP/SFTP
 
 
*'''l10n.vendor=globallink''' - uncomment if using GlobalLink
 
*'''l10n.vendor=globallink''' - uncomment if using GlobalLink
 
*'''l10n.vendor.nonsupported.extensions''' - a vendor may not support a specific extension such as .json. Enter any extensions that are not supported by the vendor but are supported by LRM. See [[LRM Fixing Issues]] for LRM supported extensions. An error will occur if there is no conversion protocol for a non-supported extension.
 
*'''l10n.vendor.nonsupported.extensions''' - a vendor may not support a specific extension such as .json. Enter any extensions that are not supported by the vendor but are supported by LRM. See [[LRM Fixing Issues]] for LRM supported extensions. An error will occur if there is no conversion protocol for a non-supported extension.

Revision as of 14:59, 20 June 2018

Supported L10n Vendors

To get a current list of LSP and TMS companies that are integrated with LRM, please email sales@lingoport.com.

Resource File Transmission Protocols

For most use cases, Lingoport recommends sending files to translation over SFTP. Direct API-based connections are also available to some TMS systems.

Overall, LRM supports 5 localization paths for sending files to be translated. They are:

Typical:

  • Local
    • Files are kept on the system LRM resides on. Good for debugging.
  • FTP
    • FTP/SFTP. Typical method of sending resource files to/from translation.

API Based:

  • GlobalLink
  • Lingotek
  • Worldserver

Transmission Protocol Configuration

The type of L10n Vendor is defined in the config_l10n_vendor.properties file that can exist at either the group or project level. See Group Configuration Files. A template of this file can be found at <HOME>/lingoport/lrm-server-x.y/deploy/templates/dir_structure/group/config

The default location of the config_l10n_vendor.properties file is at the group level. The default settings do not define a vendor so that an error will occur when prepping a kit, forcing the user to chose a vendor. The global L10n Vendor attributes are:

  • l10n.vendor=ftp - uncomment if using FTP/SFTP, the recommended approach
  • l10n.vendor=lingotek - uncomment if using Lingotek
  • l10n.vendor=local - uncomment if storing the prep/translated files locally.
  • l10n.vendor=worldserver - uncomment if using Worldserver
  • l10n.vendor=globallink - uncomment if using GlobalLink
  • l10n.vendor.nonsupported.extensions - a vendor may not support a specific extension such as .json. Enter any extensions that are not supported by the vendor but are supported by LRM. See LRM Fixing Issues for LRM supported extensions. An error will occur if there is no conversion protocol for a non-supported extension.

Example file:

#Default to 'no vendor defined'
#l10n.vendor=lingotek
#l10n.vendor=local
#l10n.vendor=worldserver
#l10n.vendor=ftp
#l10n.vendor=globallink
l10n.vendor.nonsupported.extensions=

FTP

FTP Configuration

To choose FTP as the vendor, uncomment the l10n.vendor=ftp in the config_l10n_vendor.properties file.

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

#FTP Attributes
## FTP inbound attributes for import kit files
ftp.in.host=
ftp.in.port=
ftp.in.location.path=
ftp.in.password=
ftp.in.username=
##SSH, SSL or empty
ftp.in.protocol=
## ssl implicit flag. Set to 0 for explicit, set to 1 for implicit
ftp.in.ssl.implicit=0

## FTP outbound attributes for prep kit files
ftp.out.host=
ftp.out.port=
ftp.out.location.path=
ftp.out.username=
ftp.out.password=
##SSH, SSL or empty
ftp.out.protocol=
## ssl implicit flag. Set to 0 for explicit, set to 1 for implicit
ftp.out.ssl.implicit=0

The ftp.out attributes refer to locations for files being sent out for translation. The ftp.in refers to locations for files coming back in (import) from translation.

Note: For special cases, like using One Planet, you may need to create an .ssh key http://www.linuxproblem.org/art_9.html.

FTP attributes

If the end point is FTP, the

  l10n.vendor=ftp

must be uncommented. The 'in' attributes refer to the files coming back to Lingoport Resource Manager after translation. The 'out' attributes refer to the prep-kit files which are send from Lingoport Resource Manager.

  • ftp.in.host - the hostname where the translated files reside
  • ftp.in.location.path - the directory path on the host containing the translated files
  • ftp.in.password - password associated with the username that is using the protocol
  • ftp.in.port - the port for the protocol service. In general, SSH uses port 22 and FTP uses port 21
  • ftp.in.protocol - this can be SSH or SSL. If left blank, the protocol is FTP
  • ftp.in.username - the username used with the protocol to receive the translated files


  • ftp.out.host - The hostname that the prep-kits prepared by LRM are being sent to.
  • ftp.out.location.path - the directory path on the host for the files to be translated
  • ftp.out.password - password associated with the username that is using the protocol
  • ftp.out.port - the port for the protocol service. In general, SSH uses port 22 and FTP uses port 21
  • ftp.out.protocol - this can be SSH or SSL. If left blank, the protocol is FTP
  • ftp.out.username - the username used with the protocol to send the files to be translated.

From a command line attempt to use the protocol (ssh, ssl or ftp) and the username and password to log into the host. This can verify the settings. On the host, verify that the in and out paths exist.

Translation FTP Vendor Integration

Lingoport pushes zip files to the configured FTP outbound endpoint and consumes zip files sent on the incoming endpoint. The structure of the zip file is defined below:

The files sent back and forth over FTP have the following characteristics:

  • The data files to be translated or returned from translation are sent in a zip file.
  • The zip file is named according to this convention: <group-name>.<project-name>.<kit-version>.<locale>.zip. For example, a zip file could be named Queens.Champions.1.fr_fr.zip: The group-name is Queens, the project-name is Champions, the kit version is 1, and the target locale is fr_fr.
  • The zip file consists of one top level directory, <group-name>.<project-name>.<kit-version>.<locale>, with all the files to be translated under it.
  • There is one zip file per target locale. You may target 10 locales for translation for project "Champions" under group "Queens". You then would have 10 zip files to send over FTP.
  • A zip file may contain more than one file and more than one file type.
  • Each file to be translated has a comment at the top of the file which needs to be kept when returning the file from translation vendor.
  • The translated files will be named the same as the original files (so they could be _en.properties even if the content is for French)

Two FTP endpoints are necessary: a 'to translation' end point and a 'from translation' endpoint.

Example of the Zip File Structure

The structure of the zip file for target locale de is as follows:

Acme.frontend.1.de.zip
| -- Acme.frontend.1.de
     | -- resources.properties
     | -- messages.resx
     | -- errors.json

This is the structure of the zip file sent for translation on the FTP outbound endpoint and also the structure and name of the file received from translation on the FTP inbound endpoint.

Notes:

  • The names of the files are the base resource file names
  • The names of the files (resources.properties) must be the same exact name when the translation is returned as it was in the zip file sent for translation.
  • The files in one prep kit must all be returned in the translated zip file with a complete translation. If prep kit #1 had three files, the same three files must be returned in, say, German with every key/value pair returned.

SSH/SFTP proxy server

If the ftp.out.protocol/ftp.in.protocol is SSH and there is a SFTP proxy server then the proxy host and proxy port are set up via java options.

There are 3 proxy protocols supported

  • ProxyHTTP
  • ProxySOCKS4
  • ProxySOCKS5

ProxyHTTP

The expected java options for ProxyHTTP are:

  • ftp.proxyHost
  • ftp.proxyPort

Linux example if setting java options within a shell session.

export _JAVA_OPTIONS='-Dftp.proxyHost=theproxyhost -Dftp.proxyPort=123'

ProxySOCKS4

The expected java options for ProxySOCKS4 are:

  • ftp.socks4.proxyHost
  • ftp.socks4.proxyPort

Linux example if setting java options within a shell session.

export _JAVA_OPTIONS='-Dftp.socks4.proxyHost=theproxyhost -Dftp.socks4.proxyPort=123'

ProxySOCKS5

The expected java options for ProxySOCKS5 are:

  • ftp.socks5.proxyHost
  • ftp.socks5.proxyPort

Linux example if setting java options within a shell session.

export _JAVA_OPTIONS='-Dftp.socks5.proxyHost=theproxyhost -Dftp.socks5.proxyPort=123'

Encoding of translated files

We are expecting the .properties to be returned in UTF-8 (no BOM) and so they should not have unicode escaped characters.

GlobalLink

GlobalLink Configuration

To choose GlobalLink as the vendor, uncomment the l10n.vendor=globallink in the config_l10n_vendor.properties file.

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

#GLOBALLINK
#globallink.url=

#globallink.password.for.upload=
#globallink.username.for.upload=

#globallink.password.for.download=
#globallink.username.for.download=

#globallink.project.name=A dedicated LRM project is required
#globallink.project.shortcode=

#Owner is not required
#globallink.owner=

#When to download files - 1 is on completed status (default), 2 is for preliminary targets based on workflow steps
#globallink.download.option=1

GlobalLink Locale Mapping

GlobalLink does not allow language only locales. If there are LRM target locales that are language-only, then a mapping between the LRM locale and the GlobalLink locale should be entered into config_gl_locale_mapping.properties file if it doesn't already exist.

Though the default location for the configuration file is at the global level (<HOME>/Lingoport_Data/L10nStreamlining/config), the file may also reside at the group or project level. The configuration file also exists in the LRM install directory's <HOME>/lingoport/lrm-server-x.y/deploy/templates/dir_structure/global/config folder.

GlobalLink File Format Mapping

The config_gl_file_format.properties file contains the mapping between LRM supported extensions and their corresponding GlobalLink file formats

Though the default location for the configuration file is at the global level (<HOME>/Lingoport_Data/L10nStreamlining/config), the file may also reside at the group or project level. The configuration file also exists in the LRM install directory's <HOME>/lingoport/lrm-server-x.y/deploy/templates/dir_structure/global/config folder.

Lingotek

To choose Lingotek as the vendor, uncomment the l10n.vendor=lingotek in the config_l10n_vendor.properties file.

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

#Lingotek Attributes
#Contains the host URL and api request formats
lingotek.api.hosturl=https://cms.lingotek.com

#Contains the ids for community, workflow and access token
lingotek.api.id.access.token=
lingotek.api.id.community=
lingotek.api.id.workflow=

#Example callbackURL - replace job name (lingotek) with actual Jenkins job name
lingotek.api.callbackurl=http://jenkins.company.com:8080/buildByToken/buildWithParameters?job=LingotekCallback&token=LINGOSQUARE&

#{0} is the access.token
lingotek.api.bearer=Bearer {0}

Lingotek Locale Mapping

Lingotek does not allow language only locales. If there are LRM target locales that are language-only, then a mapping between the LRM locale and the Lingotek locale should be entered into config_lingotek_locale_mapping.properties file if it doesn't already exist.

The default location for the configuration file is at the group level (<HOME>/Lingoport_Data/L10nStreamlining/<group name>/config). The configuration file also exists in the LRM install directory's <HOME>/lingoport/lrm-server-x.y/deploy/templates/dir_structure/group/config folder.

Local Vendor

The Local vendor is used for storing the prep/translated files on the local machine (the same machine where LRM is running). This type of vendor is useful when testing out LRM.

Local Vendor Configuration

To choose a Local vendor for the prep/translated files, uncomment (or add) the l10n.vendor=local in the appropriate config_l10n_vendor.properties file.

The information that is required when configuring a local vendor is:

##LOCAL VENDOR
##Absolute path for zip files to translation (outgoing)
local.out.absolute.path=
##Absolute path for zip files from translation (incoming)
local.in.absolute.path=

Worldserver

To choose Worldserver as the vendor, uncomment the l10n.vendor=worldserver in the config_l10n_vendor.properties file.

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 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.

Example if target locales are de and fr_FR

de=008_German
fr_fr=002_French_France

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. 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.

Example if target locales are de and fr_FR

de=1221
fr_fr=1221