Show TOC

Maintain Annotation ModelsLocate this document in the navigation structure


You can register vocabulary-based annotation models. This entails the registration of the annotation provider class (stand-alone annotation files are defined in an annotation provider class) with one or more services.

Figure 1: Example

You can create, change and delete annotation models. Then you add an assignment, remove an existing assignment and, if you assign more than one service to an annotation provider class, you can classify the most important service as main service: If more than once service per stand-alone annotation file needs to be supported, the annotation registration will allow to flag one service as "leading" service for the annotation file. This service will be used to inherit the SAP Gateway to backend routing.

Annotation provider classes can be registered on the backend via the annotation maintenance, thus creating an annotation repository object. For registering an annotation provider class with one or more services an IMG activity is available in the backend system: In transaction SPRO open the SAP Reference IMG and navigate to Start of the navigation path SAP NetWeaver Next navigation step SAP Gateway Service Enablement Next navigation step Backend OData Channel Next navigation step Service Development for Backend OData Channel Next navigation step Maintain Annotation Models End of the navigation path.

An annotation provider class is transported and shipped together with the annotation repository object.

After having registered the vocabulary-based annotation file and having linked it to a service you need to do the following:

  • Clear the cache in the backend system of that service. See Metadata Cache.

  • Re-load the metadata of the service to which you have assigned your annotation file. This is needed to make the changes available. For this you switch to the Activate and Maintain Service transaction and choose Load Metadata. See Activate and Maintain Services. The annotation files are availabe in the catalog service once the service the annotation file references has been activated on the SAP Gateway system.

  • Call the catalog service’s annotation feed to see the new annotation file.

Then the annotation runtime is visible via the corresponding catalog service URLs.


Stand-alone annotation files can be discovered via the annotation file collection of the catalog service (.../sap/opu/odata/IWFND/CATALOGSERVICE/AnnotationFileCollection). This collection contains all annotation files where the service they reference is active on the SAP Gateway hub system. An annotation file entity of this collection will have properties, such as:

  • Annotation file name

  • Annotation file description

  • Annotation file media link (which returns the actual annotation file XML)

Support of In-Place Vocabulary Annotations

In-place annotations are defined in a model provider class (MPC) via a method like /IWBEP/IF_MGW_ODATA_MODEL->CREATE_ANNOTATION.

  • Model provider classes are registered on the backend with the service registration, creating a service repository object

  • The model provider class is transported and shipped together with the service repository object

  • The model provider classes are available in the metadata document of a service once the service has been activated in the SAP Gateway hub system.


You need a valid transport request to transport your settings, unless you are working with local objects.