This chapter provides an introduction to metrics configuration and how metrics can be used.
If your organization is creating asset types, then you may want to add metrics fields. This chapter contains the following sections that provides the instructions to do so:
This section addresses metrics enhancements available in Oracle Enterprise Repository. Information in this guide will assist those who wish to add metrics fields to asset types, which do not already have them. The metrics fields provided by this guide are, Total Development Hours (TDH), Production Investment (Pinv), Consumption Factor (Cfac), Predicted Number of Annual Reuse Opportunities (n), and Hourly Burden Rate (B). These fields most commonly appear on the Metrics tab in the Asset Editor.
The upgrade process described in this document requires the participation of your site's DBA, system administrator, and a registrar.
This section describes an overview to metrics elements and various operations using metrics. This section contains the following topics:
This document explains how to add metrics elements to a Type. These metrics are used to estimate the value of each asset and to determine the ROI of the asset portfolio.
A total of five metrics elements must be added, and the Development Hours element must already exist in the Type. If it does not, or if it has been deleted, it, too, must be added. The necessary changes are made in the Type Manager and the database; instructions for both are included here. The new metrics elements are listed below:
Total Development Hours (TDH) - the total development effort expended to create this asset.
Production Investment (Pinv) - the extra time or effort involved in building or harvesting the asset, and in packaging and documenting the asset to make it reusable. This value is represented as a percentage over the time initially required to build the asset for one-time use.
Consumption Factor (Cfac) - the time an asset consumer spends locating, evaluating, and using an asset, represented as a percentage of the time necessary to build the asset from scratch.
Predicted Number of Annual Reuse Opportunities (n) - indicates the number of times the asset is expected to be used over the course of a year
Hourly Burden Rate (B) - the hourly overhead cost of the individual that produced the asset.
The metrics should be included in the ten base Asset Types, in addition to the other asset types that have been added to your system:
Application
Business Process
Communication Adapter
Component
Environment
Framework
Pattern
Process
Service
XML Schema
This procedure is performed in the Asset Editor.
Use this text to cut and paste element names:
Total development hours (TDH)
Production investment (Pinv)
Consumption Factor (Cfac)
Predicted number of annual reuse opportunities (n)
Hourly burden rate (B)
Note:
The ValidateMetrics.sql file must be run against the database.Select Manage Types in the Actions menu. The Type Manager launches.
Select the Type to which the metrics are to be added from the Type Manager sidebar.
Select the Editor view.
Add a tab called Metrics. It should appear above the Miscellaneous tab.
Click Add in the Elements section.
Select Numeric Text Field from the list.
Click OK.
In the Edit Numeric Text Field dialog, copy and paste the element name in the Display Name text box.
Change the Decimal Places value to 0. Only the Consumption Factor element has two decimal places, as shown in Figure 6-1.
Figure 6-1 Edit Numeric Text Field Dialog
Click OK.
Repeat steps 4 - 9 for each metric.
When all metrics have been added to the Type, click Save.
Do not add the elements to the Viewer tab at this time.
Repeat the process for each of the base asset types.
To validate the elements on the asset type, perform the following steps:
Select an asset belonging to one of asset types just modified. The easiest way to find such an asset is to right-click the Registered folder in the Asset Editor and sort by asset type.
Add a unique value to each metric element on the asset. Recommended values are 1, 2, 3, 4, and 5, as shown in Figure 6-2.
Determine the asset name, version and asset type name from the status bar on the edited asset.
Save the asset.
The following database queries can be used to validate that the metrics fields were properly added.
You can run the following metrics queries against the database by performing the instructions provided below:
-- Metrics SQL (for Oracle, UDB and MsSQL Server) -- Total Development Hours select a.name as AssetName, a.version as Version, at.name as AssetTypeName, axi.stringvalue as tdh from assetxmlindex axi, assets a, assettypes at where axi.assetid = a.id and axi.assettypeid = at.id and axi.fieldid in (select id from assetxmlindexmappings where fieldname = '/custom-data/total-development-hours--tdh-') order by a.name, a.version; -- Production Investment select a.name as AssetName, a.version as Version, at.name as AssetTypeName, axi.stringvalue as Pinv from assetxmlindex axi, assets a, assettypes at where axi.assetid = a.id and axi.assettypeid = at.id and axi.fieldid in (select id from assetxmlindexmappings where fieldname = '/custom-data/production-investment--pinv-') order by a.name, a.version; -- Consumption Factor select a.name as AssetName, a.version as Version, at.name as AssetTypeName, axi.stringvalue as Cfac from assetxmlindex axi, assets a, assettypes at where axi.assetid = a.id and axi.assettypeid = at.id and axi.fieldid in (select id from assetxmlindexmappings where fieldname = '/custom-data/consumption-factor--cfac-') order by a.name, a.version; -- Predicted Number of Annual Reuse Opportunities select a.name as AssetName, a.version as Version, at.name as AssetTypeName, axi.stringvalue as n from assetxmlindex axi, assets a, assettypes at where axi.assetid = a.id and axi.assettypeid = at.id and axi.fieldid in (select id from assetxmlindexmappings where fieldname = '/custom-data/predicted-number-of-annual-reuse-opportunities--n-') order by a.name, a.version; -- Hourly Burden Rate select a.name as AssetName, a.version as Version, at.name as AssetTypeName, axi.stringvalue as B from assetxmlindex axi, assets a, assettypes at where axi.assetid = a.id and axi.assettypeid = at.id and axi.fieldid in (select id from assetxmlindexmappings where fieldname = '/custom-data/hourly-burden-rate--b-') order by a.name, a.version; -- Predicted Net Hours Saved select a.name as AssetName, a.version as Version, at.name as AssetTypeName, axi.stringvalue as PNHS from assetxmlindex axi, assets a, assettypes at where axi.assetid = a.id and axi.assettypeid = at.id and axi.fieldid in (select id from assetxmlindexmappings where fieldname = '/custom-data/development-hours') order by a.name, a.version; -- End Metrics SQL
This section describes the instructions to run the metrics queries:
Open a connection to the database and run the six queries listed above. The asset name, version, asset type, and metric should be returned as the result. If a metric is not returned, it is likely that the metric name was not copied and pasted accurately. Each metric has its own query; it is recommended that these queries be run separately. Any metric that returns the expected results is validated.
If any metric query fails, remove the element and follow the steps to create the metric element, validate it, and run it against the database. If the PNHS element is missing from the selected asset type, it must be added, as described below:
Add the string Development Hours.
Click OK.
Edit the Development Hours element and change the name to Predicted Net Hours Saved (PNHS). (The element name in the metrics is based on the Development Hours programmatic name.) The Predicted Net Hours Saved label must appear in the Asset Editor.
After all metrics are validated, open the asset type in the Oracle Enterprise Repository Type Manager.
Select the Viewer tab.
Note:
All added elements should appear in the Hidden Elements area.
Only the Predicted Net Hours Saved (PNHS) metric will be meaningful to asset consumers.
It is recommended that Predicted Net Hours Saved (PNHS) is displayed in the first column in the Overview group.
Save the asset type.
Repeat steps 1 - 5 to add metrics elements to other asset types.
Remove any sample data that may have been added to test the queries, and save your data.