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

Issue #6137: add an API for compliance by node or rule #868

Conversation

fanf
Copy link
Member

@fanf fanf commented May 28, 2015

See http://www.rudder-project.org/redmine/issues/6137 for details about what is added

@fanf fanf force-pushed the ust_6137/create_compliance_api branch from 7569e2e to 8537894 Compare May 29, 2015 07:39
object JsonCompliance {


implicit class JsonbyRuleCompliance(rule: ByRuleRuleCompliance) {
Copy link
Member

Choose a reason for hiding this comment

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

Interesting, I compared with how we display compliance for a Rule in the webui

In the web ui, We do:

  • Directives
    • Components
      • Values

And here, in the API, we do

  • Directives
    • Components
      • Nodes
        • Values

Do you think we should add the "Node" level also in the webui, in a near future ? (3.2 ?)

Copy link
Member Author

Choose a reason for hiding this comment

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

I'm not sur, because in the UI, you have the two view availables, so having nodes and value merge may not be a limitation.
On the other hand, we could have a way to see which nodes are in error for a given value (and only errors), what could be nice

Copy link
Member

Choose a reason for hiding this comment

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

To me it's clearly missing on the webapp, you can't know which nodes is wrong on a component, until you go to the last level of each nodes

The other way that could be done is:

  • Directives
    • Components
      • Values
        • Nodes

Copy link
Member Author

Choose a reason for hiding this comment

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

This other way feels less logical, because a value may be node dependant (ex: file path depending of the hostname), and the error are by value and by node (node foo reported error bla on value val).

@fanf fanf force-pushed the ust_6137/create_compliance_api branch 2 times, most recently from 8a2a893 to c5ae078 Compare June 10, 2015 11:44
@fanf fanf force-pushed the ust_6137/create_compliance_api branch from c5ae078 to c5087b4 Compare June 10, 2015 11:46
@VinceMacBuche
Copy link
Member

Great feature for the web api ! Don't forget to add the API documentation !!

@VinceMacBuche VinceMacBuche reopened this Jun 10, 2015
VinceMacBuche added a commit that referenced this pull request Jun 10, 2015
Issue #6137: add an API for compliance by node or rule
@VinceMacBuche VinceMacBuche merged commit dcf9972 into Normation:branches/rudder/3.1 Jun 10, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants