The variable "recordQuery.queryresult.count" could not be found
search cancel

The variable "recordQuery.queryresult.count" could not be found

book

Article ID: 72239

calendar_today

Updated On:

Products

CA API Gateway

Issue/Introduction

After changing the audit policies on the Gateway or when adding external audit sinks, the following warning can be found in the API Gateway SSG logs:

 

WARNING 37 com.l7tech.server.audit.AuditLookupPolicyEvaluator: Error creating audit records, some fields not present: The variable "recordQuery.queryresult.count" could not be found.

Environment

This applies to all API Gateway versions.

Cause

This message indicates the audit writer is trying to write audits to the database but can't find some fields. Typically this comes from changes in the audit policy on the Gateway in Policy Manager but may be caused by other situations such as version upgrades.

Resolution

Add a "Set Context Variable" assertion that sets "${recordQuery.queryresult.count} with a Data Type Integer value of 0 to the Internal Audit Lookup Policy.

This should prevent the warning and audits should continue to be created again.