We like to use external tools for our Policy Migration and storing in version control system (Git). The way to go is using the GMU and a basic sample is in docops: Version Control Example - CA API Gateway - 9.2 - CA Technologies Documentation
What we are facing now is how to deal with dependency objects. The most clear example is for XML schema's from the Global Resources. The GMU is only facilitating on exporting folder, service or policy. The schema's must be migrated within a bundle including a dependency on a specific XML schema.
What I see here is:
1. Exporting a service build from a WSDL importing several schemas creates a bundle including all resources referred withing this WSDL (this is ok, we have all references)
2. Exporting a service with an Validate XML assertion referring a XML schema from Global resources does include this resources. However it does not include the imported schema's within this referred XML schema resource (this is not ok).
3. Theoretically the XML schemas could be reused and the current version on a system should be deployed in a controlled manner depending on the Git branch.
Above will result in a problem migrating these kind of dependency objects. Some times we are missing deeper nested referenced schema's (runtime issues!). This can only be found analyzing and validating the schema on missing dependencies. Also we would like to migrate the schema's separatly independent from the services. Migrating a service only needs to fail if the referred objects are missing on the target gateway. It seems we need a mix of GMU and Restman calls here?
Does any of you have tips and best practices how to deal with this specific issue and other dependencies in general?
Have you found a solution for that? I recently came accross the same issue. It's still the same for API Gateway 9.3. I would like to see GMU be able to recognize Includes/Imports in XML/XSD Files as a depency and including them to the Export bundle.
No, not really.
We had to setup all schemas and dependent schemas to be unique so all referalls from wsdl were independant. The includes are still not migrated as part of a bundle for a specific service (or folder as we do this). For this we migrate the schemas with restman and group them based on import location (which is our github). We need to take care of this in advance before migrating services and have this as a dependency in our build tooling. In our service bundle we map the schema dependency to Existing to be sure the schema is at least imported once before deploying the service.
I've walked through the scenario that you outlined and found that as you mention if a schema file has an import statement it will only include the first level without the additional XSD files. The resources are available through Restman (https://gw.support.local:8443/restman/1.0/resources) and can be pulled and push between gateways. Each item will need to be extracted at the l7:ResourceDocument element to be insert individually to the destination Gateway cluster.
I've also create an Idea to allow for more granular export controls through the GMU tool. Enable Gateway Migration Utility (GMU) export function to be more granular