Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This feature allows you to further filter (narrow down) the results of a particular search, by selecting a specific value or a set of values for a given attribute in WSO2 G-Reg Store. You can provide the filtering criteria for multiple attributes.

You can configure this in the RXT of the asset type. For an example, you can enable categorization by adding new fields to a new Categorization table of SOAP Services as explained below. 

...

Add the following configuration to add option fields to a new Categorization table of the SOAP service RXT using the provided Editor as shown below. 

Code Block
languagexml
<table name="Categorization">
<field type="options" categorization="true">
<name label="Business">Business</name>
<values>
<value>Customer Care</value>
<value>Corporate</value>
<value>Gas Technology</value>
<value>Energy Supply</value>
<value>Information Technology</value>
</values>
</field>
<field type="options" categorization="true">
<name label="Availability">Availability</name>
<values>
<value>Tier 1</value>
<value>Tier 2</value>
<value>Tier 3</value>
<value>Tier 4</value>
</values>
</field>
<field type="options" categorization="true">
<name label="Environment">Environment</name>
<values>
<value>Dev</value>
<value>Test</value>
<value>QA</value>
<value>Disaster Recovery</value>
<value>Production</value>
</values>
</field>
<field type="options" categorization="true">
<name label="Platform">Platform</name>
<values>
<value>J­EE</value>
<value>ETL</value>
<value>File Transfer</value>
<value>EDI</value>
<value>ESB</value>
</values>
</field>
<field type="options" categorization="true">
<name label="Service Type">Service Type</name>
<values>
<value>HTTP­SOAP</value>
<value>HTTP­REST</value>
<value>JMS­XML</value>
<value>JMS­JSON</value>
<value>JMS­BINARY</value>
</values>
</field>
</table>
Info

You can enable categorization by adding an option field to any of the existing tables in the RXT of a particular type (e.g. Overview).

...

Click Save, and then click Ok in the message which pops-up as shown below.

Image Removed

Add a new categoryField within the categories element under the asset.configure function for each field, in the <G-REG_HOME>/repository/deployment/server/jaggeryapps/store/extensions/assets/default/asset.js file as follows.

 

Info

Add the value of the categoryField property in the following format: <TABLE_NAME>_<FIELD-NAME>. You can pick the <TABLE_NAME> from the RXT of the particular asset type, and the <FIELD-NAME> from the configuration you added to the RXT.

 

Code Block
languagejs
categories: {
categoryField: 'Categorization_Business',
categoryField: 'Categorization_Availability',
categoryField: 'Categorization_Environment',
categoryField: 'Categorization_Platform',
categoryField: 'Categorization_Service Type',
},

...

Once you configure the RXT to enable categorization and define categories as search refinements, you can select the categorization values for a particular asset in the WSO2 G-Reg Publisher when creating an asset using the G-Reg Publisher or updating an asset as shown below.

adding categories for an asset typeImage Added

Panel

After adding categories to an asset, to search for an asset using the added categories, see Searching for an asset using categories.