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

feat: allow to update activations via the patch API #1174

Open
wants to merge 1 commit into
base: feature/edit-activation
Choose a base branch
from

Conversation

bzwei
Copy link
Collaborator

@bzwei bzwei commented Jan 6, 2025

Activations must be in disabled mode. Most fields are editable.

AAP-37295: Edit an existing activation

@bzwei bzwei requested a review from a team as a code owner January 6, 2025 16:55
@bzwei bzwei force-pushed the activation-api branch 2 times, most recently from a20f967 to 6a441e4 Compare January 6, 2025 20:33
@bzwei bzwei added the run-e2e label Jan 6, 2025
@bzwei
Copy link
Collaborator Author

bzwei commented Jan 7, 2025

e2e test failure is fixed by https://github.com/ansible/eda-qa/pull/447

@mkanoor
Copy link
Contributor

mkanoor commented Jan 7, 2025

@bzwei Since we might be updating and restarting an Activation should we log a line here to indicate that the Activation has been updated, since if the user picks up different rulebook during an update the old Rule Audit wont make any sense. Having a log line that indicates that the Activaiton has been updated since creation will give some context to the old Rule Audits. The old Rule Audits point to an Activation Instance log and this message will tell us that the user has updated this Activation.

Activations must be in disabled mode. Most fields are editable.

AAP-37295: Edit an existing activation
Copy link

sonarqubecloud bot commented Jan 7, 2025

Quality Gate Failed Quality Gate failed

Failed conditions
11.8% Duplication on New Code (required ≤ 3%)

See analysis details on SonarQube Cloud

@bzwei
Copy link
Collaborator Author

bzwei commented Jan 7, 2025

@bzwei Since we might be updating and restarting an Activation should we log a line here to indicate that the Activation has been updated, since if the user picks up different rulebook during an update the old Rule Audit wont make any sense. Having a log line that indicates that the Activaiton has been updated since creation will give some context to the old Rule Audits. The old Rule Audits point to an Activation Instance log and this message will tell us that the user has updated this Activation.

@mkanoor Here I have the log https://github.com/ansible/eda-server/pull/1174/files#diff-3aa1d8dc47ee0af34b544249cc19758b5919dbddf7057e84dc032f49f6235f33R176. Is it sufficient?

@mkanoor
Copy link
Contributor

mkanoor commented Jan 7, 2025

@bzwei That is an audit log that doesn't come out to the activation_instance log. That audit log was added by @zkayyali812 for audit trail. We need a one liner in the rulebook process log that is visible in the UI that shows it is an updated Activation. When you look at the the "Rule Audit" in out UI and click on the Activation it opens up our Rulebook process log thats where we would like to see it has been updated.

@bzwei
Copy link
Collaborator Author

bzwei commented Jan 8, 2025

@bzwei That is an audit log that doesn't come out to the activation_instance log. That audit log was added by @zkayyali812 for audit trail. We need a one liner in the rulebook process log that is visible in the UI that shows it is an updated Activation. When you look at the the "Rule Audit" in out UI and click on the Activation it opens up our Rulebook process log thats where we would like to see it has been updated.

We do not know whether the activation has been updated unless we introduce a new field to its model. This new line in the rulebook process log will be printed in every restart.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants