Graphman dependencies not included in service export - CA API Gateway
search cancel

Graphman dependencies not included in service export - CA API Gateway

book

Article ID: 448585

calendar_today

Updated On:

Products

CA API Gateway

Issue/Introduction

When exporting a service using the Graphman client, dependencies such as policy fragments and Cluster-Wide Properties (CWP) are not included in the output bundle. This occurs even when the --options.excludeDependencies false flag is applied during the export process.

Environment

  • Product: CA API Gateway
  • Component: Graphman Client v2.0.19 and higher
  • Schema: v11.x

Cause

The serviceByName query in the Graphman client does not support recursive dependency resolution. This query type retrieves only the service entity itself and does not traverse the policy tree to identify or include associated fragments or properties.

Resolution

Use the service:full query combined with a resolutionPath to ensure all dependencies are resolved and included in the export bundle.

Follow these steps to export a service with its dependencies:

  1. Identify the Resolution Path of the service in the Policy Manager (e.g., /testService).
  2. Execute the export using the service:full query:
    graphman export --using service:full --variables.resolutionPath "/testService" --output GraphmanOutput/service_bundle.json --options.excludeDependencies false --options.policyCodeFormat xml
  3. Verify the generated JSON file contains clusterProperties and policies sections for the fragments.