-
Notifications
You must be signed in to change notification settings - Fork 104
Open
Labels
Milestone
Description
Polycube Extension Proposals
Abstract
Current approach to API generation and management is complex. In particular, it is complex to:
- Have discoverable APIs (i.e. HATEOS)
- Introduce endpoints to scrape metrics (e.g. /metrics) by querying existing cubes on specific methods (e.g. metrics scraping)
The objective of this PEP is to make API generation mechanism, flexible enough to support those scenarios.
Current Solution
The Polycube Daemon does not keep track of information about cubes endpoints and cubes methods references. This prevents the possibility to use the these informations in future operations.
Limitations
The Polycube Daemon does not keep track of information about cubes and endpoints. This prevents the possibility to use the discovered endpoints in future operations.
Proposal
First step:
- Generate a API tree, with nodes defined with the following information:
- Node Name
- Node Type
- Pointers to implemented methods
- Metadata
This API Tree should be kept update upon update-removal of existing services
This will enable the following features:
- Instrumentation-Metrics Exposition
- Hateoas API Support
Second step:
- Split the discovery of APIs and their binding. This will have the following benefit:
- Simplify the API Server code
- Decouple the logic of endpoint binding from the YANG parser