API Entry Point Cost Report - HxGN SDx - Update 64 - Administration & Configuration

Administration and Configuration of HxGN SDx

Language
English
Product
HxGN SDx
Search by Category
Administration & Configuration
SmartPlant Foundation / SDx Version
10

The API Entry Point Cost Report quantifies the efficiency of the entry points in the system.

For more information about entry points, see Configure API Entry Points.

When you run the report, it looks at every entry point in your system and calculates the cost for each of the following in the entry point:

  • Type definitions

    • A query using an interface definition is considered more expensive than one using a class definition as it can potentially return more types of data.

  • Property comparisons

    • A comparison using property definitions is cheaper than one using relationship definitions, and both are cheaper than one using edge definitions.

  • Whether or not the Is Equal To operator is used

    • It is cheaper to use Is Equal To, therefore not using it adds a higher cost.

  • Peek searches

    • Using a peek search adds a higher cost than having it disabled.

    • In addition, the cost is reduced if the number of characters required to invoke peek is increased.

  • Redirects to search bar

    • If the entry point does not redirect to the search bar, this adds a higher cost.

    • If no default search criteria is specified, this also adds a higher cost.

  • Column sets

    • The cost of the column set is calculated in the same way as in the Column Set Cost Report. For more information, see Column Set Cost Report.

  • The number of results that would be returned by executing the entry point query.

    • This is optional and can be requested in the report if required. By default, it is not included as it can slow the performance of the report.

    • The configuration of an entry point that would return a large number of results should be carefully considered as it can have a higher impact on performance than entry points which return very little data.

The total cost assigned to each entry point is then calculated as the sum of these individual costs.

How do I run the report?

  • Run the report using a GET request in Postman. The command to run the report is:

    http://<server>/<site>/api/v2/SDA/GetSPFAPIEntryPointCostReport

SHARED Tip Add the following to the Body of the request to include the number of results in the report:

{
    GetDBCount:true
}

The report is displayed in JSON format, and is ordered in descending order by overall cost. This means that you can easily see the entry points in which optimizations might be made at the top of the report.

Postman is an API platform for building and using APIs. For more information on Postman, see www.postman.com.

What does the API Entry Point Cost Report look like?

The following is an extract from an API Entry Point Cost Report:

{

"@odata.context": "https://swi-vppmsdxacc4.ingrnet.com/PMCost3Server/api/v2/SDA/$metadata#Collection(Intergraph.SPF.Server.API.ClientSupport.Types.SPFEntryPointReportDetails)",

"value": [

{

"Name": "FDWContractorDocumentEntryPoint",

"Description": "Exposes the FDWDocument classdef to SPF API services shared for or created by Contractor side",

"DisplayAs": "All Documents",

"TotalCost": 124.0,

"EntryPointQueryTypeDefinitionDetails": {

"QueryClassDefinition": null,

"QueryInterfaceDefinition": "IFDWDocumentRevision",

"Cost": 5.0,

"UnitCost": 5.0

},

"EntryPointPropertyCompDetails": {

"PropertyComp": "ISPFDocumentRevision~SPFRevState~=~e1WORKING|e1CURRENT|e1CANCELLED|e1RESERVED~+SPFRevisionVersions~ISPFDocumentVersion~SPFIsDocVersionSuperseded~=~False",

"Cost": 6.0,

"PropertyComparisonPropertyDefsCost": 1.0,

"PropertyComparisonRelationDefinitionsCost": 5.0,

"PropertyComparisonEdgeDefinitionsCost": 0.0,

"CostDetails": "SPFAPIEPPropertyComp's cost - (PropertyDefsCount * 1) + (RelDefsCount * 5) + (EdgeDefsCount*10) = 6"

},

"EntryPointEqualToOperatorDetails": {

"IsEqualToOperatorEnabled": false,

"Cost": 10.0,

"UnitCost": 10.0

},

"EntryPointPeekSearchDetails": {

"IsPeekSearchDisabled": false,

"PeekSearchCharacterCount": 0,

"Cost": 19.0,

"UnitCost": 9.0,

"CostDetails": "Peek search enable cost : 10 + Peek search character cost: 9"

},

"EntryPointDefaultSearchCriteria": {

"RedirectToSearchBar": false,

"ApplyDefaultSearchCriteria": false,

"Cost": 20.0,

"CostDetails": "SPFAPIEPRedirectToSearch' cost : 10 + SPFAPIEPApplyDefaultSearchCriteria' cost : 10"

},

"EntryPointColumnSetDetails": {

"ColumnSetUID": "CS_FDWDocumentVersion",

"ColumnSetName": "FDWDocumentVersion",

"ColumnSetDescription": "Document version list view",

"ColumnSetCost": 54,

"ColumnSetPropertyCount": 9,

"ColumnSetRelCount": 9,

"ColumnSetEdgeCount": 9

},

"EntryPointDatabaseResultSetDetails": {

"TotalResultSetCount": 286889,

"EntryPointResultSetCount": 0,

"Cost": 10.0

}

},

...

}