Documentation Center

Replacing the UGC Community Web service Web application with a standalone UGC Community Service microservice

This is the recommended way to upgrade the UGC Community service.

Procedure

  1. From the WEB-INF/classes/ subdirectory of your Java/JSP Web application, copy all files to a backup location.
  2. On the SDL Web installation media, access Content Delivery\roles\ugc\service-community\.
  3. Copy the standalone\ folder in this location, including its files and subfolders, to a location of your choice, and rename it to communityservice.
  4. Only if you modified your logback.xml file, merge the contents of your backed-up logback.xml file with the file by the same name in the config\ subfolder of the communityservice\ folder.
  5. Restore your remaining backed-up configuration files to the config\ folder
  6. Access the configuration location and do one of the following:
    • If you have modified the file logback.xml, merge its contents with that of the file Content Delivery\roles\ugc\service-community\standalone\config\logback.xml.
    • Otherwise, copy Content Delivery\roles\ugc\service-community\standalone\config\logback.xml over your current logback.xml.
  7. In the configuration location, open the following files for editing:
    • cd_webservice_conf.xml
    • cd_storage_conf.xml
    • cd_ambient_conf.xml
  8. From cd_webservice_conf.xml, copy the section called <OData>, with all of its contents, to your clipboard.
  9. In cd_storage_conf.xml, place your cursor before the <License> section and paste the copied code.
  10. Save and close cd_storage_conf.xml.
  11. From cd_webservice_conf.xml, copy the sections called <AuthenticationServer> and <Accounts>, with all of their contents, to your clipboard.
  12. In cd_ambient_conf.xml, place your cursor inside the <Security> section, before the <Rules> subsection or, if there is no <Rules> subsection, just before the closing tag </Security>, and then paste the copied code.
  13. If you use OAuth authentication, add an OAuthEnabled attribute to the Security element and set it to true.
  14. If you use OAuth authentication, add the following subelement inside the Security element:
    <RequestValidator>com.sdl.web.oauth.validator.OAuth2RequestValidator</RequestValidator>
  15. If you use OAuth authentication, cut the <SharedSecret> element out of your Security section and paste it inside the <AuthenticationServer> section you just pasted from cd_webservice_conf.xml, replacing any <SharedSecret> element that is already there.
  16. Add the following Claim elements to your <GloballyAcceptedClaims> section:
    <Claim Uri="taf:tracking:id"/>
    <Claim Uri="taf:claim:contentdelivery:webservice:user"/>
    <Claim Uri="taf:claim:contentdelivery:webservice:post:allowed"/>
  17. Remove all Path elements inside the <ExcludedPaths> section, and add the following Path element:
    <Path>/token.svc</Path>
  18. In your Cartridge element for the UGC Cartridge, add a new attribute called Category and set it to system, so that the element looks like this:
    <Cartridge Category="system" File="ugc_ambient_cartridge_conf.xml" />
  19. Inside the <Cookies> section, add the following subelement:
    <Cookie Type="ADF" Name="TAFContext" />
  20. Save and close cd_ambient_conf.xml.
  21. Close cd_webservice_conf.xml. You can now delete this file.
  22. Proceed by installing the UGC Community Service standalone microservice.