Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Reconcile between service config versions in REST and Web UI

Reconcile between service config versions in REST and Web UI

New Contributor

REST list of configurations ( /api/v1/clusters/dev15/configurations?type=hive-site ) returns 13 version, numbered 1-13. But the web UI shows 17 versions. A REST query for v17 returns nothing.

Why do REST and web UI service config versions not match? How can versions be reconciled?

4 REPLIES 4

Re: Reconcile between service config versions in REST and Web UI

@Neil Watson

You are not fetching the versions at service level -rather sub configuration types level.

In Ambari UI, it shows the versions at service level.

For example to fetch all the versions of HDFS - following REST API can be used.

http://apappu.hdp.com:8080/api/v1/clusters/test/configurations/service_config_versions?sortBy=create...

Re: Reconcile between service config versions in REST and Web UI

New Contributor

What are sub configuration types?

Re: Reconcile between service config versions in REST and Web UI

@Neil Watson

It is part of configuration service configuration. For example: HDFS service contains many "type configuration",

hadoop-policy

core-site

hdfs-site

ranger-hdfs-plugin-properties

hadoop-env

ranger-hdfs-policymgr-ssl

ranger-hdfs-security

hdfs-log4j

ranger-hdfs-audit

ssl-client ssl-server

...like that. each type configuration has its own version information but finally tied to service config version.

If you pull the configurations from below URL, you will have type configurations in the output with those versions.

http://HOST:8080/api/v1/clusters/test/configurations/service_config_versions?service_name=HDFS&servi...

Basically this is how it is mapped/groupped to the service at Ambari DB level.

Re: Reconcile between service config versions in REST and Web UI

Expert Contributor

@Neil Watson

API /api/v1/clusters/dev15/configurations?type=hive-site will give you all versions of hive-site. ambari-web UI does not show versions of particular config type (Example hive-site, core-site) in any of its user interface.

ambari-web shows config versions for a service (Example: hive, hdfs, etc) on service config page and dashboard config history page. config versions for a service gets incremented everytime when a config related to service is changed. Thus if hive-site has 13 versions and service config versions for hive has 17 versions, it means that there were 4 times hive service config changes that did not involved any changes in hive-site. changes could have been in other sites related to hive like hive-env, webhcat-site, hive-log4j, etc if you want to see from REST API v17 config version for hive service, you can use following API that ambari-web uses:

http://c6401.ambari.apache.org:8080/api/v1/clusters/c1/configurations/service_config_versions?servic...