Manual configuration of the rendering service

The import of metadata and the installation procedure described in the previous chapter is used to generate configuration files. These are stored as XML files in the directory "[installation directory of rendering services] / conf / esmain".
It may be necessary to edit these files manually (e.g. when a domain changes) or a Web server configuration requires special adaptations.
For each application, even for the rendering service itself, a configuration file must exist. Furthermore, there is a file "ccapp-registry.properties.xml" where configuration files are referenced. Here is an example of a file:

<?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
 <properties>
 <comment>campuscontent application registry</comment>
 <entry key="applicationfiles">homeApplication.properties.xml,app-repository.properties.xml</entry>
 </properties> 



The values of "application files" are the configuration files "homeApplication.properties.xml" for the rendering service and "app-repository.properties.xml" for a repository as comma separated values.
Configuration of the rendering services
The configuration file "homeApplication.properties.xml" consists primarily of values for the authentication of a rendering service with an edu-sharing repository. An example might look like this:

<?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
 <properties>
 <comment>edu-sharing render service</comment>
 <entry key="appid">esrender</entry>
 <entry key="appcaption">my Renderingservice</entry>
 <entry key="trustedclient">true</entry>
 <entry key="type">SERVICE</entry>
 <entry key="host">127.0.0.1</entry>
 <entry key="port">80</entry>
 <entry key="public_key">public key</entry>
 <entry key="private_key">private key</entry>
 <entry key="homerepid">homerepository-app-id</entry>
 </properties> 



Explanation of keys / values:
appid: must match the value in the configuration file of the rendering service in the repository
appcaption: freely selectable
trustedclient: "true"
host: IP of the server on which the rendering service has been installed
port: port via which the service rendering can be reached
public_key: Public SSL key
private_key: SSL Private Key
homerepid: application ID of the home repository


General Configuration
In the file "/config/system.conf.php" important system constants are defined. Under certain circumstances, these must be edited if changes have been made on the server or if the rendering service is run behind a proxy.

  •  $MC_URL : URL of the Rendering Service

$MC_DOCROOT: Path of the document root, e.g. "/ var / www".
$CC_RENDER_PATH. Directory in which the objects are cached, e.g. "/ var / cache / esrender /"
Database connection
Should changes in the database configuration be necessary, for example, because the database is moved to another server or another user is to be used, the necessary adjustments can be made in "/conf/db.conf.php".
Proxy Configuration
If the rendering service is operated behind a proxy server, some constants must be defined in "/conf/proxy.conf.php". This is necessary in order to enable the reachability of the Web services:
USE_HTTP_PROXY: "true" or "false"
HTTP_PROXY_HOST: Domain name of the proxy
HTTP_PROXY_PORT: Proxy Port
HTTP_PROXY_USER: username (optional)
HTTP_PROXY_PASS: password (optional)
HTTP_PROXY_SNI: Sets SOAP Parameters "SNI_enabled" to "TRUE"
Configuration of the repository
In addition to the configuration file for the rendering service itself at least one configuration file for the repository housing the content to be rendered must be present. In this example it is the file "app-repository.properties.xml". The name of this file must be composed as follows: "app- [appid] .properties.xml". The appid is defined within the configuration file itself and must be the same appid as the one of the repository the rendering service was registered with. A sample configuration for a repository might look like this:

 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
 <properties>
 <comment>My edu-sharing.net repository</comment>
 <entry key="appid">repository</entry>
 <entry key="appcaption">my repository manages learn-objects</entry>
 <entry key="trustedclient">true</entry>
 <entry key="type">REPOSITORY</entry>
 <entry key="host">127.0.0.1</entry>
 <entry key="port">8080</entry>
 <entry key="authenticationwebservice">http://repositorydomainname /edu- sharing/services/authbyapp</entry>

 <entry key="authenticationwebservice_wsdl">http:// 
repositorydomainname:8080/edu-sharing/services/authbyapp?wsdl</entry>
 <entry key="usagewebservice">http://repositorydomainname:8080/edu- sharing/services/usage2</entry>
 <entry key="usagewebservice_wsdl">http://repositorydomainname:8080/edu- sharing/services/usage2?wsdl</entry>
 <entry key="alfresco_webservice_url">http://repositorydomainname /alfresco/api</entry>
 <entry key="renderinfoservice_wsdl">https://repositorydomainname/edu- sharing/services/RenderInfo?wsdl</entry>
 <entry key="domain">repositorydomainname</entry>
 <entry key="message_offset_ms">5000</entry>
 <entry key="message_send_offset_ms">2000</entry>
 </properties> 


Explination of keys / values:

  • appid: must match appid of the repository in its own homeApplication.properties.xml. Is crucial for the naming of this configuration file (see above).
  • appcaption: freely selectable
  •  trusted client: "true"
  • type: "REPOSITORY"
  • host: IP of the server on which the repository is installed
  • port: port through which the repository can be reached
  • authenticationwebservice: address where the authentication service of the repository can be found
  • authenticationwebservice_wsdl: address where the WSDL of the authentication service can be found
  • usagewebservice: address where the web service of the usage service of the repository can be reached
  • usagewebservice_wsdl: address of the WSDL file of the usage service
  • alfresco_webservice_url: Address of the Alfresco Web Services
  • renderinfoservice_wsdl: address of the WSDL file of the rendering service
  • domain: domain name of the repository
  • message_offset_ms: optional
  • message_send_offset_ms: optional