Different versions of same API Proxy deployed on same environment?

Hi Apigee experts,

So we have a requirement where the client would like to have on the same env of apigee 2 different versions of the same API Proxy. The requirement is that any given time both APIs can be invoked by a client.

What might differ between the 2 versions is:

1- The Target URL is different in the 2 versions

2- Something in the logic of the API changes (e.g. a new policy is attached)

For both 1 and 2, the only way that I’m aware of to support this is to have a different basepath for the 2 versions of the APIs. Am I missing some other alternative?

Thanks!

VP

Hi

On my side, we addressed this with multiple proxies deployed, with (as you suggested) different basepaths :

1. Proxy 1 basePath: /functionalDomain/v1

2. Proxy 2 basePath: /functionalDomain/v2

This allows us to have different API lifecycles, by keeping in mind to quickly “kill” the first version (to not have 2 versions to maintain during years…)

I’ve also seen another way to manage, but I really do not like it: introducing a version information in header and then manage version by policies conditions:

curl -XGET -H "x-version: 1.0" [http://httpbin.org/anything](http://httpbin.org/anything)
curl -XGET -H "x-version: 2.0" [http://httpbin.org/anything](http://httpbin.org/anything)

… but again, I do not like it, not easy to operate and maintain…

Arnaud

1 Like

You are not missing anything.

There is nothing in the Apigee configuration validation that stipulates that “only one revision of a proxy can be deployed to an environment.”

The validation is: The basepath must be unique for the environment-group.

Therefore if you change your basepath from revision 1 to revision 2, then you can deploy both r1 and r2 to the same environment.

1 Like