This CentraSite release provides a Release Preview of the API Virtualization Feature. The feature described in this section is for evaluation purposes only. It is not yet an official feature of the product and should not be used for production work.
CentraSite provides a wizard for virtualizing and publishing APIs.
Within CentraSite Business UI, the endpoints for an API are shown in the Provider Overview profile of the API.
In this profile, a native endpoint is represented by the Binding; while a virtual endpoint is represented as an Alias that identifies a specific Access URI (i.e., address where the virtual API is published).
The following example shows the Provider Overview profile for an API with the native and virtual endpoints. Note that the Access URI provides the exact address of each endpoint.
The content is organized in the following topics:
When virtualizing an API, keep the following points in mind:
You must be a registered user (i.e., Provider) in the CentraSite.
You must belong to either one of the following roles:
CentraSite Administrator
API Publisher
Runtime API Provider
However, an administrator can grant these permissions to other roles.
For more information about roles and permissions, see the section About Roles and Permissions in the document Users, Groups, Roles and Permissions.
The Virtualize action is visible only for the APIs (Service, REST, XML Service).
Ensure that the service to virtualize has a WSDL or schema file associated with it.
Ensure that the interface for the native API is completely implemented and that interface is reflected in the WSDL or schema file that is registered for the API in the CentraSite registry.
The metadata for the native API is valid and up-to-date. If the metadata for the native API has not been completely specified or is out-of-date, you should update it before you virtualize API so that you do not carry inaccurate/incomplete data into the virtual API.
Make sure that the Mediator is configured and running on the Integration Server.
To virtualize an API in CentraSite, you perform the following high-level steps:
Use the following procedure to create a new virtual alias (API) for the native API.
To create a virtual alias
In CentraSite Business UI, display the details page for the API that you want to create a virtual copy. For procedures, see the section Viewing Details of an API.
On the API details page, click ) to open
the Virtualize < > wizard.
In panel 1 of the Virtualize < > wizard, complete the following fields:
In this field... | Do the following... |
---|---|
Create a new virtual alias |
Enter a name for the virtual alias. The name you assign to the virtual alias can contain any character, including spaces. By default, CentraSite derives the virtual alias name from the display name that you specify for the native API. If an alias with the same name already exists, CentraSite issues a warning message. |
Reconfigure an existing virtual alias |
Alternatively, you use this option to redefine an existing virtual API and adapt it to your requirements. |
Endpoint of < > to be virtualized |
For a SOAP-based API. You will see a list of available endpoints for the native API. Select the native endpoint that you want to virtualize by choosing its radio button. |
Resource of < > to be virtualized |
For an XML/REST-based API. You will see a list of available resources for the native API. Select the native resource that you want to virtualize by choosing its radio button. |
When the
button is enabled, click it.Note:
If you have not specified the virtual alias, the
button remains disabled.
In panel 2, define policy enforcement for the virtual API. If you need procedures for this step, see Defining Policy Enforcement Rules for a Virtual API.
In panel 3, specify in which of the targets you want to publish the virtual API. If you need procedures for this step, see Publishing a Virtual Alias.
Click
to create the new virtual copy of native API.Use the following steps to complete panel 2 in the Virtualize < > wizard. You use this panel to define the set of policy actions and processing steps for the virtual API.
To define policy enforcement rules for a virtual alias
Go to panel 2 in the Virtualize < > wizard. If you need procedures for this step, see Creating a New Virtual Alias.
To define the policy enforcement rules for the virtual API, you have one of the following options:
Create a new definition of policy enforcement rule within the message flow. For procedures, see step 3.
Reuse any existing definition of policy enforcement rule within the message flow. For procedures, see the section Editing the Policy Enforcement Rules of a Virtual API.
If you choose to create a new definition of the policy enforcement rule, do the following:
Inspect the accordions in the Policy Actions area.
You can view a tooltip text for any accordion by moving the cursor to the accordion name. The tooltip text gives a summary of the accordion’s purpose.
The following table identifies the accordions and the runtime actions that each accordion supports.
Accordion | Runtime Action |
---|---|
Request Handling |
|
Policy Enforcement |
|
Response Handling |
|
Error Handling |
|
For more details on the actions that CentraSite provides for runtime governance of an API, see Run-Time Actions Reference for Virtualized APIs in the document Built-In Run-Time Actions Reference for Virtualized APIs.
Expand an accordion node whose action you want to add for the enforcement.
From the accordion, drag and drop an action onto the Message Flow area.
The Message Flow area has the following policy enforcement workflow components:
Receive - This component enables you to specify the actions used for request processing. For example, the Require HTTP Protocol action to configure the format of requests that the virtual API will accept.
Enforce - This component enables you to specify the actions used for enforcement. For example, these include actions to monitor the API usage, log the usage per consumer, and validate the request and response messages.
Routing - This component enables you to specify the actions used for enforcement. For example, these include actions to configure the endpoints and route the requests to native APIs.
Response - This component enables you to specify the actions used for response processing. For example, an action to remove sensitive attributes that may have been added to a request by a consumer as a result of security operations against request elements.
When you drag and drop an action in to the Message Flow area, CentraSite automatically places the action in the corresponding workflow component. Not all components support the full set of actions. Some actions happen only with certain components. For example, an Evaluate action occurs only on the Enforce component; while a Routing action occurs only on the Routing component.
You can view a tooltip text for any action by moving the cursor to the action name. The tooltip text gives a summary of the action’s purpose. The tooltip text shown is the content of the action’s Description field, as defined for the action in the CentraSite registry.
Repeat steps a to d until you obtain a list that contains the actions that you want to add to Message Flow area.
CentraSite executes the actions in a predefined order. For details, see Action Evaluation Order and Dependencies for Virtual APIs in the document Built-In Run-Time Actions Reference for Virtual APIs.
Specify parameter values for each of the actions by clicking
on the right side of the action name.
Remove an action from the Message Flow area by
clicking .
If you want to save the new policy enforcement rule, so that you can
reuse the same enforcement rule again at a later stage, in the Save
as Blueprint text box specify a name for the new policy enforcement
rule and click Save ().
When the
button is enabled, click it.Note:
If you have not specified all of the mandatory parameters for the
actions, the button remains disabled.
In panel 3, specify in which of the targets you want to publish the virtual API. If you need procedures for this step, see Publishing the Virtual Alias.
Or:
Else, click to create the new
virtual copy of native API.
Use the following steps to complete panel 3 in the Virtualize < > wizard. You use this panel to simply virtualize the API or to define the targets and publish the virtual API.
To publish a virtual alias
Go to panel 3 in the Virtualize < > wizard. If you need procedures for this step, see Creating a New Virtual Alias.
You can choose to perform one of the following operations on the API:
If you choose to publish your virtual API, do the following:
From the Available Targets list, choose the targets in which you want CentraSite to publish the virtual API. Keep the following points in mind when you select the targets for publishing the virtual API:
The Available Targets shows a list of targets that are available for you.
You can select multiple targets for publishing the virtual API.
If necessary, you can click Virtualize < > wizard and change your definition.
to return to the panel 2 in theIn the Expose to Consumers checkbox. Doing this will allow unauthorized consumers (guests) to search and access the API.
node, select theThe Expose to Consumers checkbox is visible only to those users who have "Full" permission on the particular API.
When the
button is enabled, click it.Note:
If you have not specified a target, the
button remains disabled.
If you choose to simply virtualize the API, do the following:
In the Expose to Consumers checkbox to allow unauthorized consumers (guests) search and access the API.
node, select theClick the
button.