Skip to main content

Enabling authentication for a Service Locator client

To enable authentication for a client, define user names and passwords (corresponding to the ones on the server) by adding authentication properties in the Service Locator configuration file <container>/etc/org.talend.esb.locator.cfg.

From Talend Runtime 8.0 onwards, usernames and passwords in OSGi configurations are resolved as references to environment variables. For example:
  • in a container, where a consumer is looking up services from the Service Locator server, add:
    authentication.name=${env:TESB_LOCATOR_AUTHENTICATION_USERNAME:-${TESB_LOCATOR_AUTHENTICATION_USERNAME:-sluser}}                    
    authentication.password=${env:TESB_LOCATOR_AUTHENTICATION_PASSWORD:-${TESB_LOCATOR_AUTHENTICATION_PASSWORD}}
  • in a container, where a Web Service is adding or deleting services from the Service Locator server, add:
    authentication.name=${env:TESB_LOCATOR_AUTHENTICATION_USERNAME:-${TESB_LOCATOR_AUTHENTICATION_USERNAME:-slservice}}
    authentication.password=${env:TESB_LOCATOR_AUTHENTICATION_PASSWORD:-${TESB_LOCATOR_AUTHENTICATION_PASSWORD}}
For the username and password, first the OS environment is queried. If the parameter is not set as an OS environment variable, the Java system variables set in etc/custom.properties are queried. For the username, but not for the password, there is finally a literal default value.

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – please let us know!