Documentation Center

Configuring the location of the Discovery Service in the Session-enabled Java/JSP Web site

To enable the Discovery Service (and the Capabilities it exposes) to be found, configure the location of the Discovery Service in the client configuration file, cd_client_conf.xml.

Procedure

  1. In the configuration directory of the Server Role, open cd_client_conf.xml for editing.
  2. Ensure that the file contains a root-level element called ServiceConfig that looks as follows:
    <ServiceConfig
      ConnectionTimeout="TIMEOUT"
      CacheEnabled="false"
      CacheExpirationDuration="0"
      ServiceAvailabilityCheck="SERVICE_CHECK">
      <DiscoveryService ServiceUri="URI" />
      <TokenService ClientId="USERNAME" ClientSecret="PASSWORD" />
    </ServiceConfig>
    where:
    • TIMEOUT is the amount of time in milliseconds after which a connection to the Discovery Endpoint times out. A good default value would be 10000 (that is, 10 seconds).
    • SERVICE_CHECK is true if the client should check if the service is available.
    • URI is the URL of the Discovery Endpoint.
    • USERNAME and PASSWORD are valid Token Service credentials that grant the client access to the Discovery Endpoint. You can find valid credentials in the Ambient Data Framework configuration file, cd_ambient_conf.xml, of the Discovery Service. Note that the value of ClientSecret must be an encrypted value.