KB Article #188082
Handling KPS ObjectExists Error
Problem
When deploying configuration from PolicyStudio in API Gateway, you may encounter the following error
ERROR 14/Feb/2024:10:02:33.953 [f0c19:7b81cc65de09bd08aff08b10] java exception:com.vordel.kps.ObjectExists: KPS: API Portal_PortalOrganizationStore: Object: {development=false, organizationDn=o=ORG1,ou=organizations,ou=APIPortal, restricted=false, id=efeddedd-9acc-432b-9c6b-81b1d03a6227, enabled=false}, with primary id: efeddedd-9acc-432b-9c6b-81b1d03a6227, already exists.
Resolution
This issue arises when you copy a KPS backup from one environment (e.g., production) to another (e.g., development) and the target environment already has a duplicate organization with the same name or ID.
To resolve the issue, follow these steps:
- Create a Backup in the Working Environment:
Use the
KPSADMIN
tool in the working environment to create a KPS backup. - Copy Backup Files:
Transfer the generated backup files to the problematic environment (e.g., DEV). Place these files in the following directory:
apigateway/groups/topologylinks/{group_name}-{instance_name}/conf/kps/backup
- Restore the Backup:
In the problematic environment, use
KPSADMIN
to clear the existing tables. Then restore the KPS backup from the files you copied into the backup directory. - Restart the Instance:
After restoring the backup, restart the API Gateway instance to apply the changes.
For more detailed instructions on using KPSADMIN
, please refer to the following documentation: Manage KPS using kpsadmin.