Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

REST API for scenario execution #131

Merged
merged 7 commits into from
Aug 4, 2020
Merged

REST API for scenario execution #131

merged 7 commits into from
Aug 4, 2020

Conversation

chrzaszcz
Copy link
Member

@chrzaszcz chrzaszcz commented Aug 4, 2020

Follows the API definition: https://github.com/esl/amoc_rest/blob/1d615924/openapi.yaml

  • Added and tested the new REST API endpoints
  • Added support for update_settings in amoc_dist
  • Fixed some minor issues with type specs

There is an increasing need to add tests for amoc_dist - this module is untested. This should be done in a separate issue.

See the commit messages below for more details.

This functionality allows modifying scenario parameters
  while it is running.

- The whole 'amoc_dist' module is untested.
  This needs to be solved. It is not possible to test it easily
    as the whole cluster needs to be running.
  There is an integration test, but it has a significant overhead
    and does not generate coverage reports.
- Fixed some broken specs
- Removed tests for the obsolete 'scenario' endpoints
- Add tests for the new 'execution' endpoints
- 'amoc_dist' requires mocking as otherwise several nodes
    would need to be started
- Test layout simplified for more brevity and readability
- Intentionally not checking for invoked mocked functions
  - test effects, not calls
@@ -6,7 +6,7 @@
{exometer_core, {git, "https://github.com/esl/exometer_core.git", {branch, "master"}}},
{exometer_report_graphite, {git, "https://github.com/esl/exometer_report_graphite.git", {branch, "master"}}},
%% when updating amoc_rest version, don't forget to update it at ./doc/http-api.md as well.
{amoc_rest, {git, "https://github.com/esl/amoc_rest.git", {ref, "7a46d9f"}}},
{amoc_rest, {git, "https://github.com/esl/amoc_rest.git", {ref, "1d615924"}}},
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please update the link in ./doc/http-api.md
it should be https://esl.github.io/amoc_rest/?v=1d615924

Copy link
Collaborator

@NelsonVides NelsonVides left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It honestly looks perfect, so readable, thank you very much for this effort! 😄

@NelsonVides NelsonVides merged commit d75d57f into master Aug 4, 2020
@NelsonVides NelsonVides deleted the amoc-dist-api branch August 4, 2020 12:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants