com.atlassian.confluence.content.render.xhtml.migration.exceptions.UnknownMacroMigrationException: The macro 'next_previous_links' is unknown.

Handler Configuration Details

The WSO2 Governance Registry can be extended in several ways. Handlers are pluggable components, that contain custom processing logic for handling resources. All handlers extend an abstract class named Handler, which provides default implementations for resource handling methods as well as a few utilities useful for concrete handler implementations. Each handler is associated with a filter. Filters provide criteria for engaging handlers. Registry always evaluates the associated filter before invoking a handler. If the filter evaluates to true, it will invoke its associated handler.

Handlers can be engaged to the WSO2 Governance Registry either programmatically, or by defining them in the registry.xml. Most built-in handlers are engaged by default, whereas optional and user-defined handlers should be configured by defining them in the registry.xml file. The registry.xml file includes several optional handlers that can be enabled or disabled according to your requirement.



Service Metadata Handlers

The WSO2 Governance Registry is optimized to support Design-time and Run-time governance for Web Services. There exists handlers that can process WSDL files, schemas and policies. These handlers are even capable of managing related resources such as imported WSDLs and schemas. The service metadata handlers accept several configuration options which allows you to define the associated media type and storage location. For an instance given below is the configuration for WSDLMediaTypeHandler.

<handler class="org.wso2.carbon.registry.extensions.handlers.WSDLMediaTypeHandler">
        <property name="disableSymlinkCreation">true</property>
        <property name="schemaLocationConfiguration" type="xml">
            <location>/trunk/schemas/</location>
        </property>
        <property name="wsdlLocationConfiguration" type="xml">
            <location>/trunk/wsdls/</location>
        </property>
        <property name="policyLocationConfiguration" type="xml">
            <location>/trunk/policies/</location>
        </property>
        <filter class="org.wso2.carbon.registry.core.jdbc.handlers.filters.MediaTypeMatcher">
            <property name="mediaType">application/wsdl+xml</property>
        </filter>
    </handler>

Apart from the WSDLMediaTypeHandler which processes uploaded WSDLs, there are other handlers as well which are configured in the registry.xml to support governance of web services. Given below are the other handlers.

  1. ZipWSDLMediaTypeHandler - WSDLs and associated schemas can also be uploaded as .zip files or as .gar files. This handler is used to process such WSDL s and schemas.

  2. ServiceMediaTypeHandler - Handler to process the services being added to the registry.

  3. DeleteServiceHandler - This handler provides the ability to remove the entire heirarchy for a given service while deleting the service.

  4. PolicyMediaTypeHandler - This handler processes the policy files being added to the registry.

  5. XSDMediaTypeHandler - This handler processes the schema types being added to the registry.

  6. EndpointMediaTypeHandler - This handler processes service end-points defined in the WSDL files being uploaded to the registry.

All these handlers other than PolicyMediaTypeHandler and EndpointMediaTypeHandler contains a property called disableSymlinkCreation which holds true by default. This would avoid creating Symbolic Links for resources by default.

External Link Handler

The WSO2 Governance Registry allows you to store external links as a part of the repository tree structure. Clicking on such a resource would take you to the external link. This makes it easy for an organization to manage physically separated resources as a part of a single hierarchical tree structure. Given below is the configuration for ExternalLinkHandler.

    <handler class="org.wso2.carbon.registry.extensions.handlers.ExternalLinkHandler">
        <filter class="org.wso2.carbon.registry.core.jdbc.handlers.filters.MediaTypeMatcher">
            <property name="mediaType">application/vnd.wso2-hyperlink</property>
        </filter>
    </handler>

You can similarly include your own handlers on the registry.xml. The handler sample included with the WSO2 Governance Registry distribution explains to how you could create your own handler and include it in the registry.xml file.

URI Media Type Handler

The WSO2 Governance Registry allows you to add resources to the registry as URL references. In such case the resource would exist on a different file system and the registry would only hold a URL reference to that resource. To process and find dependencies like Services, WSDLs, Endpoints, Schemas and Policy files of URL referenced resources we use the UriMediaTypeHandler.Given below is the configuration for UriMediaTypeHandler.

    <handler class="org.wso2.carbon.governance.registry.extensions.handlers.UriMediaTypeHandler">
        <filter class="org.wso2.carbon.registry.core.jdbc.handlers.filters.MediaTypeMatcher">
            <property name="mediaType">application/vnd.wso2-uri+xml</property>
        </filter>
    </handler>

Extensions Symbolic Link Handler

The main purpose of this handler is to properly remove a symbolic link added to a resource. Given below is the configuration for ExtensionsSymLinkHandler. 

    <handler class="org.wso2.carbon.registry.extensions.handlers.ExtensionsSymLinkHandler">
        <filter class="org.wso2.carbon.registry.core.jdbc.handlers.filters.URLMatcher">
            <property name="pattern">.*</property>
        </filter>
    </handler>

Retention Handler

This handler implements Resource Retention Locking. It checks retention lock conditions before performing the operation. If resource is locked by another user and operation cannot be performed, RegistryException will be thrown with an appropriate message. Given below is the configuration for RetentionHandler. 

    <handler class="org.wso2.carbon.registry.extensions.handlers.RetentionHandler" 
            methods="PUT,DELETE,MOVE,RENAME,IMPORT,COPY,ADD_ASSOCIATION,REMOVE_ASSOCIATION,RESTORE,RESTORE_VERSION">
        <filter class="org.wso2.carbon.registry.core.jdbc.handlers.filters.URLMatcher">
            <property name="pattern">.*</property>
        </filter>
    </handler>

See also Handlers.

com.atlassian.confluence.content.render.xhtml.migration.exceptions.UnknownMacroMigrationException: The macro 'next_previous_links2' is unknown.