You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Creating a command object or template with PUT and pushing the same object or template with POST should return in status code 304 (unmodified) as documented.
Current Behavior
API returns 200 upon object / template creation (PUT) but also 200 on update (POST) with the same object data and creates a modified activity in the web ui.
Possible Solution
Sorry, don't know.
Steps to Reproduce (for bugs)
Create new command object providing arguments parameter:
Status code 200 is returned and in the web UI a new activity is created showing that command testcmd was modified but without a diff. The exact same happens, when using template as object type.
Note that, when omitting arguments parameter completely in both API requests, POST request correctly returns 304.
This effectively breaks the usage of Ansible Collection for Icinga Director.
Your Environment
Director version (System - About): 1.10.2
Icinga Web 2 version and modules (System - About): 2.11.2
Icinga 2 version (icinga2 --version): 2.13.6
Operating System and version: Debian 11 (Bullseye)
The text was updated successfully, but these errors were encountered:
jensrudolf
changed the title
Director API incorrectly returns modified for command objects and templates with arguments
API incorrectly returns modified for command objects and templates with arguments
Nov 15, 2022
This also happens over the Director GUI, if you just store a command object, without changing something, you will see changes in the activity log, but without a Diff.
If you deploy the changes, the Deployment ID will remain the same.
Expected Behavior
Creating a command object or template with PUT and pushing the same object or template with POST should return in status code 304 (unmodified) as documented.
Current Behavior
API returns 200 upon object / template creation (PUT) but also 200 on update (POST) with the same object data and creates a
modified
activity in the web ui.Possible Solution
Sorry, don't know.
Steps to Reproduce (for bugs)
Create new command object providing
arguments
parameter:Now update the object using the same data:
Status code 200 is returned and in the web UI a new activity is created showing that command
testcmd
was modified but without a diff. The exact same happens, when usingtemplate
as object type.Note that, when omitting
arguments
parameter completely in both API requests, POST request correctly returns 304.This effectively breaks the usage of Ansible Collection for Icinga Director.
Your Environment
icinga2 --version
): 2.13.6The text was updated successfully, but these errors were encountered: