WSO2 API Manager - APIs missing after recreating a pod

5/16/2019

We have a setup of WSO2 API Management in a distributed pattern (pattern-3) in Kubernetes. We are using a PostgreSQL DB which is running outside the Kubernetes cluster for all the databases.

I have published some APIs in the publisher and am able to invoke them from the store.

I had to make a change in api-manager.xml for the API Publisher and API Store configmap files and recreated the pod. When the pods were available, I observed that the APIs that I had published and working earlier are not visible anymore.

I tried to add the same APIs again and it is complaining that the APIs by that name already exists.

Following is the log from the plubisher pod:

[2019-05-16 08:19:38,266] ERROR - APIProviderHostObject Error occurred while adding the document. PizzaShack API Documentation already exists for API PizzaShackAPI-1.0.0
[2019-05-16 08:19:38,273] ERROR - docs:jag org.wso2.carbon.apimgt.api.APIManagementException: Error occurred while adding the document. PizzaShack API Documentation already exists for API PizzaShackAPI-1.0.0

While creating the API again on the Publisher, following error is displayed: "Duplicate API Name"

It clearly seems to be some synchronization issue. How can this issue be fixed?

-- AKB
kubernetes
wso2-am

1 Answer

7/11/2019

I had shared the instance of Carbon DB across the components. This was causingthe issue. Using separate instance for each component in disbuted mode solved it

-- AKB
Source: StackOverflow