Bug 704184

Summary: [RFE] Add version info to the status API call
Product: [Retired] Pulp Reporter: Lukas Zapletal <lzap>
Component: API/integrationAssignee: Chris Duryee <cduryee>
Status: CLOSED UPSTREAM QA Contact: Preethi Thomas <pthomas>
Severity: medium Docs Contact:
Priority: medium    
Version: MasterCC: abutcher, cduryee, dgregor, jason.dobies, jluza, rbarlow, skarmark, smilner
Target Milestone: ---Keywords: FutureFeature, Triaged
Target Release: 2.6.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-02-19 00:45:09 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Lukas Zapletal 2011-05-12 11:32:00 UTC
Hello,

we would like to know the version number of Pulp server, because we often run into issues when using incompatible API.

Is there any way to get the version number from the API call? If not the status call would be nice place to add it.

Thanks

Comment 1 Sayli Karmarkar 2011-05-18 16:44:28 UTC
This is a great suggestion, however we do not support backward compatibility of Pulp API yet. Marking this as RFE.

Comment 2 Andrew Butcher 2013-11-17 20:42:24 UTC
This feature would be great for our pulp tooling. We'd like to check if our client will work with the major and minor version of the server so we can ask our  users in operations to update before attempting any API calls.

Example REST call:

GET /pulp/api/v2/status/

Sample 200 Response Body:

{"api_version": "2.3.0"}

An alternative would be to return more keys - possibly {api_version_major: "2"}, {"api_version_minor": "3"}.

Comment 3 Steve Milner 2014-01-13 15:53:48 UTC
I'm also hitting up against some tooling issues trying to find the right version (2.1,2.2,2.3) of REST API calls to make. Versioning the API and/or returning the version supported by the server would be very helpful.

Comment 4 Chris Duryee 2014-12-08 14:38:02 UTC
I am working on this as part of a different story.

Comment 5 Chris Duryee 2014-12-08 22:50:56 UTC
https://github.com/pulp/pulp/pull/1404

Comment 6 Chris Duryee 2015-01-15 00:35:31 UTC
fixed in 2.6.0-0.4.beta

Comment 7 Preethi Thomas 2015-01-29 14:02:24 UTC
verified

[root@gizmo ~]# curl -k -u admin:admin  https://localhost/pulp/api/v2/status/{"known_workers": [{"last_heartbeat": "2015-01-29T13:58:18Z", "name": "scheduler.lab.eng.bos.redhat.com"}, {"last_heartbeat": "2015-01-29T13:59:02Z", "name": "reserved_resource_worker-1.lab.eng.bos.redhat.com"}, {"last_heartbeat": "2015-01-29T13:59:03Z", "name": "reserved_resource_worker-0.lab.eng.bos.redhat.com"}, {"last_heartbeat": "2015-01-29T13:59:03Z", "name": "resource_manager.lab.eng.bos.redhat.com"}], "messaging_connection": {"connected": true}, "database_connection": {"connected": true}, "api_version": "2", "versions": {"platform_version": "2.6.0"}}[root@gizmo ~]# 
[root@gizmo ~]# 
[root@gizmo ~]#

Comment 8 Brian Bouterse 2015-02-19 00:45:09 UTC
Moved to https://pulp.plan.io/issues/161