Hello,
One point not made so far, even today developers have to code twice against GET '*/data/' because of different possible outputs. First is GET '*/data/' with some parameters to get raw data and then another instance with identical URL but different parameters to get bucketed results. The split in API will formalize the differences and will no longer burden the developer with reading the documentation to make sure the right parameters are passed.
The typical CRUD REST API design principles cannot be applied in some cases to the Hawkular Metrics interface because of the project's nature. There is little CRUD in ingesting metrics once and making that data available in a few different ways (raw, bucketed, by tags, and eventually pre-computed aggregates). And that makes it somewhat challenging to design and find good articles and examples. But here a few resources that I think are good in this context:
1)
https://www.thoughtworks.com/insights/blog/rest-api-design-resource-modeling - section 'An example from the public GitHub API'
2)
http://www.vinaysahni.com/best-practices-for-a-pragmatic-restful-api - section 'What about actions that don't fit into the world of CRUD operations?'
3)
https://developer.github.com/v3/repos/statistics/ - documentation
page to get statistical data for a repo, the rest of the documentation
is also interesting
4)
https://developers.facebook.com/docs/marketing-api/reference/ad-keyword-stats - documentation for getting ad keyword statistics
I see two common themes in the links above. First, the public APIs are really complex and the number of end-points is really not the concern; more important are ease of use, single purpose, and good documentation. And second, outside of CRUD there is little material (blogs, books, articles) about what to do.With this in mind here is the plan of action based on the feedback in this thread and many discussions we had in the community and amongst Hawkular Metrics contributors. Hawkular Metrics will proceed with merging the first PR to split and restructure '/data', the old code is deprecated but intact. We will work with the community and current users to find the best path to fully remove '*/data'. We will publish more details about the deprecation and plans for removal as soon as we have more details; also except this change to be documented in detail in the release notes until fully removed. Just to be clear, this is not a single release transition to fully remove '*/data/', so far we identified a minimum of 3 releases, but it could extend beyond that based on feedback.