Pattern matching in the router configuration
Pattern matching can minimize overhead in the router service. The default router configuration includes instances of the pattern
filter object, that limit script requests to specified methods and endpoints.
Based on the following code snippet, the router service would trigger a
script for CREATE
and UPDATE
calls to managed and internal objects:
{
"pattern" : "^(managed|internal)($|(/.+))",
"onRequest" : {
"type" : "text/javascript",
"source" : "require('policyFilter').runFilter()"
},
"methods" : [
"create",
"update"
]
}
Without this pattern
, IDM would apply the policy filter to additional objects, such as the audit service, which could affect performance.