TermWeb configuration (termweb.properties)

Most of the settings are applied via termweb.properties file which is located in TermWeb home folder.

Key

Values

Comment

Key

Values

Comment

Minimal required settings

termweb.home

Absolute path to TermWeb home folder

Command-line argument. Must be specified in Java options of running process (Tomcat) via key -Dtermweb.home=/opt/twhome. See TermWeb 4 install on Windows

base.url

https://example.termweb.eu

In case of scheduled jobs, like sending mail digest server need to know which URL to use for current installation

spring.datasource.driverClassName

com.mysql.jdbc.Driver

Database driver. Right now supported only MySQL

spring.datasource.username

DB user name, empty by default

Database user for connection

spring.datasource.password

DB user password, empty by default

Database user’s password for connection

spring.datasource.url

jdbc:mysql://<server_ip_or_name>[:<port>]/<scheme>?autoReconnect=true&useUnicode=true&character_set_server=utf8mb4&connectionCollation=utf8mb4_general_ci&useSSL=false&serverTimezone=UTC

JDBC URL for DB connection, don’t delete any of additional connection parameters

termweb.elasticsearch.index-prefix

termweb default.

Elasticsearch index name prefix used for indices created by TermWeb, see limitations on name: ES Create index API

termweb.elasticsearch.address

127.0.0.1 default

IP address or host name of Elasticsearch server

termweb.elasticsearch.port

9200 default

Elasticsearch server port for connection

email.smtp.server

localhost default

 

email.smtp.port

25 default

email.smtp.user

SMTP user name, empty by default

 

email.smtp.password

SMTP user password, empty by default

 

System settings

session.timeout

1800 (30 minutes) default

The session timeout in seconds. This value determines how long a user can be logged on to TermWeb before she is logged out due to inactivity. A negative value indicates that the sessions should never expire. A value of 0 (zero) uses the servlet engine's default value, or the value specified in web.xml for TermWeb, e.g.

<session-config> <session-timeout>30</session-timeout> </session-config>

Note that the web.xml timeout value is specified in minutes.

reset.password.lifetime

1800 (30 minutes) default

since 4.0.7 Time in seconds for how long recovery password token will be valid.

guest.autologin.disabled

false default

Disables the auto-login functionality of the guest account.
Administrators can still enable guest account for the client but they will not be able to select Automatic as login method.
If there already is a guest account with automatic login it will be changed to normal login.

double.byte.search

true default

Applies normalisation of text values in filter criteria and term sorting in term list, in order to support double-byte search.

hide.inaccessible.links

false default

NOT implemented in tw4 Removes the link (and corresponding text) for links that point to content which the user can not access. If false, a message will be displayed when the user clicks a non-accessible link.

API settings

api.concurrent.session

false default

Specifies if TermWeb and XML-RPC sessions can work simultaneously for the same user.

api.use.iso2

false default

Set the language code to ISO2 (639-1) for the API
This affects the return type of all language codes in the API
When reading a language code from the API into the system both language types ISO2 (639-1) and ISO3 (639-2/T) are handled

api.new.user.is.admin

false default

Indication whether automatically created users will be client admins or single users

api.autocreate.users

true default

since 4.0.8-3 Automatically create user record in the system after successful SSO | API login.
(by default applied to SAML, OpenId, OpenId Connect or TermWeb API login)

api.login.as.guest.when.usermissing

false default

since 4.0.8-3 Try to login as guest user after successful SSO | API authentication. If guest user is disabled login won’t work.
(by default applied to SAML, OpenId, OpenId Connect or TermWeb API login)

api.default.user.group

Empty by default

The name of the default group where automatically created single users will belong.
This property does not apply in case created users are client admins.
If group not exists it will be created automatically.

api.update.existing.concept

false default

Option to update an existing concept instead of creating a new one when create concept method is called via the API.

Specifically, when calling createFromJSON in concept endpoint, a check is being made if at least one of the concept's terms already exist in the database, in the section the concept is supposed to be added.

If it exists, then the concept gets updated instead of creating a new one. Used to avoid concept/term duplicates when adding new terms via the API.

api.search.limit

200 default

When using web services to get a decoration for a segment, there is a limit to how many terms are included in each term search.
First these terms are being acquired in the order that they appear in the term list and from these terms, the ones matching the segment part are being kept to be included in the decoration.

A quick test would be to write the first word of the term you wish to see in the decoration in TermWeb search and see in the term list if the term you wish to see appears in the first page of the list. If not you need to increase this limit to make it appear.

api.minimum.stem.length API Template

1 default

The limit of characters where a word should be considered as a stem during decoration.

api.stem.comparison.margin API Template

0 default

The margin of characters allowed to be different at the end of a stem during stem comparison in decoration.
The default value is 0 and it means that the stems need to be 100% identical.

api.stem.german.filter.factory.class

org.apache.lucene.analysis.de.GermanLightStemFilterFactory default

Default stemmer for German language. Default value is: "org.apache.lucene.analysis.de.GermanLightStemFilterFactory"
This stemmer treats next characters as same letter:
'ä','à','á','â' = 'a';
'ö','ò','ó','ô' = 'o';
'ï','ì','í','î' = 'i';
'ü','ù','ú','û' = 'u';
You can specify old stemmer from TermWeb 3: org.apache.lucene.analysis.de.GermanMinimalStemFilterFactory
which supported only next characters 'ä', 'ö', 'ü'
For more complex rules you can pick org.apache.lucene.analysis.de.GermanStemFilterFactory it uses algorithm based on the report "A Fast and Simple Stemming Algorithm for German Words" by Jörg Caumanns (it adds extra substitutions likes "ß" is substituted by "ss") or you may use Snowball German stemmer by specifying next value
org.apache.lucene.analysis.snowball.SnowballPorterFilterFactory

api.return.terms.with.punctuation API Template

false default

since 4.0.8 By default TermWeb term decoration function skips from results terms containing next punctuation symbols: . , ! ? : ; . You may include this terms by changing this value to true.

api.term.hashtag.enable API Template

true default

Handles hashtag terms as normal terms. Includes them in decoration for segments that contain or not, the hashtag.

api.handle.space.tags API Template

false default

Handles some tags as spaces. (ph, t). This is an unstable feature. Not recommended for use

File operations settings

file.max.import.size

 

The maximum size for import file uploads in Kb. Limited by server value for file upload.

file.max.attachment.size

 

The maximum size for attachment uploads in Kb. Limited by server value for file upload.

use.caret.symbol

false default

Escape caret symbol in import/export (it will remove circumflex char ^ from values).

Mailing settings

email.charset

UTF-8 default

The character set to be used for all mail.
Leave empty to use mail server's system character set.

email.from.name

TermWeb default

 

email.from.address

noreply@termweb.se default

The address of the sender

email.max.attachment.size

Size in Kilobytes 2048 (2 Mb) default. 0 means no limit.

The maximum size for email attachments in Kb. Note that the SMTP server may be configured to use a lower max size, and emails may bounce if attachments
larger than the server's limit is sent.
Because of the email encoding, the actual size of the email is about 33% larger than the attachment. The maximum recommended value for email attachments should
therefore be 75% of the mail server's maximum message size.

email.techsupport.recipient

empty by default

The address of technical support to which application errors should be mailed. If omitted no mails will be sent.

email.max.retry

10 default

Number of tries to send mail

email.starttls.enabled

false default

since 4.0.6-3 If true, enables the use of the STARTTLS command (if supported by the server) to switch the connection to a TLS-protected connection before issuing any login commands. If the server does not support STARTTLS, the connection continues without the use of TLS; see the email.starttls.required property to fail if STARTTLS isn't supported. Note that an appropriate trust store must configured so that the client will trust the server's certificate.

email.starttls.required

false default

since 4.0.6-3 If true, requires the use of the STARTTLS command. If the server doesn't support the STARTTLS command, or the command fails, the connect method will fail.

Security settings

allow.inside.iframe

false default

Specifies if TermWeb is allowed to run in an iframe on another page. Required by XTM integration to be enabled.

allow.inside.iframe.frameancestors

'self' https://*.xtm-intl.com https://*.xtm-cloud.com default

List of allowed frame ancestors to use TermWeb in iframe.
This value will be included to response for OpenId authentication callback as CSP: frame-ancestors header (check docs on MDN).

termweb.security.bcrypt.strength

10

since 4.0.7 Default cost factor for password hashing with bcrypt. Be careful changing this value after installation invalidate all existing user passwords.

termweb.security.antivirus.scan

false default

since 4.0.7 Enables scanning for viruses of files uploaded to File repository

termweb.security.antivirus.vendor

clamav

since 4.0.7 Name of anit-virus settings to use.

termweb.security.antivirus.clamav.host

localhost

since 4.0.7 Server ip address or host name where clamd is running.

termweb.security.antivirus.clamav.port

3310

since 4.0.7 Port number on which clamd listening.

termweb.security.antivirus.clamav.timeout

5000 milliseconds

since 4.0.7 Read timeout value in milliseconds for clamd connection. In case of often “Read timeout” errors you may increase this value. Usually it depends on uploaded file sizes, connection speed between servers and amount of files to scan.

termweb.security.max_failed_login_attempts

5

since 4.0.7 Maximum failed login attempts before locking user account.

termweb.security.minutes_to_reset_failed_login_attempt

5 minutes

since 4.0.7 Time in minutes for how long user account will be locked after reaching number of failed login attempts.

termweb.security.max_failed_attempts_from_same_ip

25

since 4.0.7 Maximum failed login attempts to different users before blocking ip address.

termweb.security.minutes_to_reset_blocked_ip

60

since 4.0.7 Time in minutes for how long ip address will be blocked after multiple unsuccessful login attempts.

termweb.login.normal.disabled_for_external_users

true by default

since 4.0.9 Enable or disable normal login (by password) for external users (created via SSO login, LDAP)

termweb.logout.header.clear_site_data

empty by default

since 4.0.9 When value is set TermWeb will include Clear-Site-Data header for /api/v4/logout endpoint.
At time of writing supported values are: "*", "storage", "cookies", "cache", "clientHints", "executionContexts".

You may specify multiple values like this: "storage", "cookies"

See Clear-Site-Data - HTTP | MDN for actual information.

OpenId Connect SSO login settings

oidc.enabled

false default

true to enable OIDC login. OIDC won’t work in case if your license doesn’t include it. For more information see OpenId Connect Login .

oidc.origin

empty by default

Identity Provider (IdP) URL (e.g. https://login.microsoftonline.com/<tenant-id>)

oidc.client.id

empty by default

Client identifier for TermWeb installation used by IdP (this value usually provided from IdP, it can be anything: name, TermWeb url, some generated id)

oidc.client.secret

empty by default

Client secret for connection with IdP.

oidc.client.secret.basic

false default

true to use Basic authentication with IdP, otherwise POST will be used.

oidc.basic.auth.preemptive

false default

true when send Basic authentication header with first request

oidc.auth.url

empty by default

<authentication endpoint> added to the end of oidc.origin url. Like /oauth2/v2.0/authorize.
So TermWeb will use https://login.microsoftonline.com/<tenant-id>/oauth2/v2.0/authorize.

oidc.token.url

empty by default

<token endpoint> subpath added to the end of oidc.origin url. Like /oauth2/v2.0/token.

oidc.userdetails.url

empty by default

<user details endpoint> full URL or subpath added to the end of oidc.origin url. Like /idp/userinfo.openid or https://graph.microsoft.com/oidc/userinfo.

oidc.scopes.requested

openid profile email

List of all data requested by TermWeb from IdP about user.

oidc.userdetails.field.client

empty by default

Field from user data to identify TermWeb’s Client for logging user. Can be skipped when default client is configured. For example: termweb_client_name.

oidc.userdetails.field.default.client

empty by default

Specify Client login name when it can't be retrieved from user details.

oidc.userdetails.field.user

empty by default

Field to identify user, stored as username in TermWeb. E.g. preferred_username.

oidc.autocreate.users

true default
default value is set in api.autocreate.users

true when we need to auto create user when it not exists.
since 4.0.8-3 When value is not set TermWeb is loading value of api.autocreate.users .

oidc.login.as.guest.when.usermissing

true default
default value is set in api.login.as.guest.when.usermissing

Authenticate user as guest when there is no TermWeb’s user related to OpenId profile.
since 4.0.8-3 When value is not set TermWeb is loading value of api.login.as.guest.when.usermissing .

oidc.userdetails.field.groupmapping

{} json string

since 4.0.9-0 Add user to TermWeb’s group based on user details property.

{\ "employeeType": {\ "Independent": "TermWeb External",\ "Supplier": "TermWeb External",\ "Consultant": "TermWeb External"\ },\ "userGroup": {\ "Translators": "TermWeb Translators",\ "Users": "Termweb Regular user"\ }\ }

employeeType and userGroup are properties from user details provided by IdP. Independent, Supplier, Consultant, Translators and Users values from properties which will be mapped to specified TermWeb's group.

\ is used new line delimiter in java properties file, if you’re making one line configuration don’t forget to remove this slash: { "employeeType": {"Independent": "TermWeb External", "Supplier": "TermWeb External"} }

Other settings

termweb.rest.max-page-size

Integer number, 500 default

Maximum page size allowed by REST API which can be requested by user. Bigger values will be changed automatically to this value.

termweb.elasticsearch.client.connection.timeout

Integer number, 2000 default

since 4.0.8-15 Timeout in milliseconds until a connection is established for ElasticSearch client. A timeout value of zero is interpreted as an infinite timeout.

A timeout value of zero is interpreted as an infinite timeout. A negative value is interpreted as undefined (system default).

termweb.elasticsearch.client.socket.timeout

Integer number, 90000 default

since 4.0.8-15 Socket timeout in milliseconds for ElasticSearch client, which is the timeout for waiting for data or, put differently, a maximum period inactivity between two consecutive data packets).

A timeout value of zero is interpreted as an infinite timeout. A negative value is interpreted as undefined (system default).

termweb.elasticsearch.client.reindex.timeout

Integer number, 300 default

since 4.0.8-15 Timeout in seconds of reindex request for search service.

Period each indexing waits for the following operations:

  • Automatic index creation

  • Dynamic mapping updates

  • Waiting for active shards

Defaults to 5m (five minutes). This guarantees Elasticsearch waits for at least the timeout before failing.

The actual wait time could be longer, particularly when multiple waits occur.

termweb.hide.version

false by default

Stops TermWeb from printing full version string and build date. When true version is printed as TermWeb 4, and build date as current year.

termweb.elasticsearch.autostart

false

deprecated When is set to true TermWeb will try to start Elasticsearch locally (will be deleted in 4.1.0).

termweb.elasticsearch.home

/opt/elasticsearch-7.3.2

deprecated Used with ES autostart, path to ES installation folder (will be deleted in 4.1.0).

termweb.elasticsearch.allow-root

false

deprecated Used with ES autostart, passes argument -Des.insecure.allow.root=true to Elasticsearch (will be deleted in 4.1.0).

termweb.elasticsearch.time-to-wait

30 default, integer number

deprecated Used with ES autostart, Time to wait for ES instance to start and stop in seconds (will be deleted in 4.1.0).

termweb.elasticsearch.cluster.name

TW4-cluster default

obsolete used in previous versions when ES client required it