Previous Topic: Create a New Custom Adapter Using the SDK interfaceNext Topic: Call the CAFedSearch Servlet Using REST


Adding the Cross-Origin Resource Sharing Filter

The Federated Search feature is configured on the web client interface when Cross-Origin Resource Sharing (CORS) filter is added to the web interface and the Federated Search (FS) Tomcat. This filter allows you to add a list of cross-origin requests. By default, the web interface setting is defaulted to a "*", indicating that any origin requests, either cross or same-origin are allowed. It is recommended that you restrict this setting further with a list of CA SDM Web Interface Servers configured for your environment.

To edit the web interface client setting and allow cross-origin requests, complete the following steps:

  1. Navigate to the following CA SDM directory for editing the web interface settings:
    $NX_ROOT\bopcfg\www\CATALINA_BASE_FS\webapps\cafedsearch\WEB-INF\web.xml
    
  2. Open the web.xml file and check for:
    <web-app><filter><init-param><param-name>cors.allowOrigin</param-name>
    
  3. Update the <param-value> tag with a space-separated list of domains. For example, the base URL address for the web interface:
    <param-value>http://web01:8080 http://web02:8080 http://web03:8080</param-value>
    
  4. Save the web.xml file. Tomcat is restarted automatically.
  5. Test and verify the Federated Search configuration on the web client interface. Ensure it is functional.
  6. For the web interface updates to persist after running the CA SDM Configuration, repeat the same updates to the web.xml.tpl file.