IBM Support

Invalid RDF is returned from an OSLC request if the name of a ClearQuest field starts with a number.

Technote (troubleshooting)


Problem(Abstract)

If RDF/XML data is returned from an OSLC request and one or more IBM Rational ClearQuest fields do not conform to XML naming conventions, the response body will return invalid RDF/XML.

Symptom

When you run the response value through an RDF validator such as  http://www.w3.org/RDF/Validator/, the validation fails.


Cause

If RDF/XML data is returned from an OSLC request and , one or more ClearQuest fields do not conform to XML naming conventions the response body will return invalid RDF/XML . For example, XML conventions specify that field names cannot begin with a number (8.0.1_textField). If one of the ClearQuest field names returned from an OSLC request is 8.0.1_textField, the response body includes invalid RDF/XML syntax which causes the OSLC request to fail.

Environment

You encounter this problem in any environment in which you submit an OSLC request to a ClearQuest database that returns an RDF response body that contains at least one field that starts with a number or follows some other pattern that does not conform to XML naming conventions.

Diagnosing the problem

Complete the following steps to determine if the response body returned by an OSLC request is invalid RDF/XML

  1. Issue an OSLC request that returns RDF/XML

    You can issue the request from the RESTClient plugin for Mozilla Firefox.

    Example:
    Request:  Get  
    URL: https://hostname/cqweb/oslc/repo/myRepo/db/SAMPL/record/16777224-33554438


    Headers:

    Accept:  application/rdf+xml
    OSLC-Core-Version: 2.0

  2. After the request comes back, validate the response body to identify any XML errors in the content.
      1. Copy the contents of the response body.
        On the RESTClient, you can find the response body in the Response Body tab.
      2. Paste the response body into an RDF validator. Then, validate the content.

        For example, if you use the validator at http://www.w3.org/RDF/Validator/, paste the response body into the Check by direct Input field. Then, click Parse RDF.

If invalid RDF/XML has been returned, the RDF validation will fail.

Resolving the problem

To resolve the problem, update the ClearQuest schema so that all field names conform to the XML document naming conventions for elements and attributes. To review the naming conventions, see XML 1.0 specification for Common Syntactic Constructs.

After you update the schema, complete the following steps to apply the change and verify the OSLC request operation.

  1. Check in the schema revision, update the database to use the revised schema.  See the Applying schema changes to user databases topic in the Rational ClearQuest Knowledge Center.
  2. Clear the browser cache.
  3. Resubmit the OSLC request to see if the schema update was successful.

Related information

RDF Validator

Document information

More support for: Rational ClearQuest
Web Java Client

Software version: 8.0, 8.0.0.1, 8.0.0.2, 8.0.0.3, 8.0.0.4, 8.0.0.5, 8.0.0.6, 8.0.0.7, 8.0.0.8, 8.0.0.9, 8.0.1, 8.0.1.1, 8.0.1.2

Operating system(s): Linux, Windows

Reference #: 1657109

Modified date: 29 April 2014